Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#29291 - [metalog] writing pid in init-script is broken
Attached to Project:
Arch Linux
Opened by Boris (ooTh7oru) - Thursday, 05 April 2012, 13:59 GMT
Last edited by Jürgen Hötzel (juergen) - Friday, 13 April 2012, 11:45 GMT
Opened by Boris (ooTh7oru) - Thursday, 05 April 2012, 13:59 GMT
Last edited by Jürgen Hötzel (juergen) - Friday, 13 April 2012, 11:45 GMT
|
DetailsDescription:
The writing of the PID in /etc/rc.d/metalog is broken in two ways: 1) $PID is used to write the file, but $PID is only set BEFORE starting metalog to get the pid of an instance that might already be running. After starting metalog, $PID is not set again, but just written to the pid-file. So usually this results in an 'echo "" > /var/run/metalog.pid' 2) metalog has a pid-file-handling of its own. If no other parameter is set, uses the same path as the init-script. So metalog and the init-script race for writing this file. I've restarted metalog a few times and seen both possible errors: an empty file and a broken file (empty line and a few digits of the correct pid) Additional info: * version 2.0-1 Steps to reproduce: * start metalog and check /var/run/metalog.pid and compare to the pid of the metalog-master process (because there is a race involved, it might be fine sometimes) Possible fix: As metalog writes a pid-file itself, a fix is pretty simple: stop writing the pid-file from the init script. |
This task depends upon
Closed by Jürgen Hötzel (juergen)
Friday, 13 April 2012, 11:45 GMT
Reason for closing: Fixed
Additional comments about closing: Thanks for your contribution!
Friday, 13 April 2012, 11:45 GMT
Reason for closing: Fixed
Additional comments about closing: Thanks for your contribution!
metalog-pid-race.patch