Bug#460869: doesn't shutdown properly / creates wrong pid file
Package: cron Version: 3.0pl1-102 Severity: normal Hello. localhost:~# ps aux | grep cron root 14394 0.0 0.0 2400 688 pts/0R+ 12:54 0:00 grep cron localhost:~# /etc/init.d/cron start Starting periodic command scheduler: crond. localhost:~# ps aux | grep cron root 14478 0.0 0.0 2972 972 ?Ss 12:54 0:00 /usr/sbin/cron root 14502 0.0 0.0 2400 696 pts/0S+ 12:54 0:00 grep cron localhost:~# /etc/init.d/cron stop Stopping periodic command scheduler: crond failed! localhost:~#ps aux | grep cron root 14478 0.0 0.0 2972 972 ?Ss 12:54 0:00 /usr/sbin/cron root 17036 0.0 0.0 2400 696 pts/0S+ 12:58 0:00 grep cron localhost:~#cat /var/run/crond.pid 14478 localhost:~# The problem is that cron has probably hardcoded pidfile as /var/run/crond.pid and ignores --pidfile argument that start-stop-daemon tries to pass it. Thus whenever cron is started it creates /var/run/crond.pid, but during shutdown it searches for /var/run/cron.pid. The solution is either change PIDFILE variable in /etc/init.d/cron or make cron able to use some variable passed to it instead of hardcoded value. regards fEnIo -- ,''`. Bartosz Fenski | mailto:[EMAIL PROTECTED] | pgp:0x13fefc40 | irc:fEnIo : :' : 32-050 Skawina - Glowackiego 3/15 - malopolskie v. - Poland `. `' phone:+48602383548 | proud Debian maintainer and user `-http://fenski.pl | xmpp:[EMAIL PROTECTED] | rlu:172001 signature.asc Description: Digital signature
Bug#460869: doesn't shutdown properly / creates wrong pid file
2008/1/15, Bartosz Fenski aka fEnIo [EMAIL PROTECTED]: Package: cron Version: 3.0pl1-102 Severity: normal What system are you running on. Is it a GNU/KfreeBSD by chance? If so, please check if you have a /etc/cron.pid file in your system. thanks Javier -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#460869: doesn't shutdown properly / creates wrong pid file
On Tue, Jan 15, 2008 at 02:50:12PM +0100, Javier Fernandez-Sanguino wrote: Package: cron Version: 3.0pl1-102 Severity: normal What system are you running on. Is it a GNU/KfreeBSD by chance? If so, please check if you have a /etc/cron.pid file in your system. No it's not KfreeBSD. That's fresh install of lenny snapshot upgraded to sid. I asked on #debian-devel, and I'm not the only one with that bug. I don't have any *.pid in /etc/. Just simply try to run /usr/sbin/cron and you'll end up with /var/run/crond.pid instead of /var/run/cron.pid. regards fEnIo -- ,''`. Bartosz Fenski | mailto:[EMAIL PROTECTED] | pgp:0x13fefc40 | irc:fEnIo : :' : 32-050 Skawina - Glowackiego 3/15 - malopolskie v. - Poland `. `' phone:+48602383548 | proud Debian maintainer and user `-http://fenski.pl | xmpp:[EMAIL PROTECTED] | rlu:172001 signature.asc Description: Digital signature