
david at thegeorges
Jul 5, 2007, 5:52 AM
Post #34 of 36
(3974 views)
Permalink
|
On 07/05/2007 08:42 AM, A JM wrote: > I've just been running from the CL using mythbackend... I thought the > running of the process itself should create a PID? strange, is that > not normal... > No, it isn't strange. It all depends on how the developer wrote the program. Daemons do not need to write a pidfile. The OS doesn't need them. They are mostly a convenience for init script writers. > So, if I run from the CL "mythbackend -p /var/run/mythbackend.pid" > then I should be good to go?? will an abandoned PID file then be > removed from /var/run after a backend crash? > That isn't how it works. Nothing will remove the pid file on crash. What you do is read the pid file if it exists and then check to see if the process is running. Probably the easiest way to see if the process is still running in linux is to see if the PID exists as a directory in /proc. -- David _______________________________________________ mythtv-users mailing list mythtv-users [at] mythtv http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
|