#30 Wrong pid in pidfile

open-works-for-me
None
5
2010-01-08
2010-01-06
Joni
No

Hi,
It seems that the pid in pidfile is wrong at least in my system. I noticed that real pid is number in pidfile + 1. My friend looked the source code and thought that the problem could be that the parent process is printed in pidfile and then killed and only child processes exist after that. I noticed this when I was testing init script.

Discussion

  • Justin Maggard
    Justin Maggard
    2010-01-08

    I'm not seeing that. Are you using start-stop-daemon -b or something? The pidfile isn't written until after the fork takes place, so I don't know how that would be possible. Unless you're confusing the main program with scanner process...?

     
  • Justin Maggard
    Justin Maggard
    2010-01-08

    • assigned_to: nobody --> jmaggard
    • status: open --> open-works-for-me
     
  • DerGrinch
    DerGrinch
    2010-08-30

    Just a quick note:
    I have the same issue with the latest CVS (I don't know if this matters: ffmpegthumbnailer- and mac-accesscontrol-patch applied (would be nice if you could integrate them to upstream sometime..):

    root@debian:~# ps aux | grep mini
    root 16766 0.0 0.0 10996 908 pts/0 S+ 00:27 0:00 grep mini
    root@debian:~# /etc/init.d/minidlna start
    Starting minidlna: minidlna.
    root@debian:~# cat /var/run/minidlna.pid
    16558
    root@debian:~# ps aux | grep mini
    root 16769 0.0 0.0 137608 2532 ? Ssl 00:27 0:00 /usr/bin/minidlna -f /etc/minidlna.conf
    root 16777 44.1 0.1 131096 6736 ? DN 00:27 0:04 /usr/bin/minidlna -f /etc/minidlna.conf
    root 16798 0.0 0.0 10996 908 pts/0 S+ 00:27 0:00 grep mini

    I'm using the init-script from your CVS.

    Greets...