Better handling of pid locking
Frontend stop now actually checks that the process has stopped
Apply better checks to factory startup script as well