Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 63673 - Stale mailman qrunner lock prevents mailman from starting
Summary: Stale mailman qrunner lock prevents mailman from starting
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Net-Mail Packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-11 07:35 UTC by Jon Howell
Modified: 2006-09-14 08:38 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jon Howell 2004-09-11 07:35:40 UTC
If at boot time mailman has a stale lock lying around, the init script will happily declare [ok] even though mailman has failed to start. If I run the main step of the start() function manually, I get:

  skagit root # su - mailman -c 'bin/mailmanctl start'
  The master qrunner lock could not be acquired.  It appears as though there is
  a stale master qrunner lock.  Try re-running mailmanctl with the -s flag.

This suggests two problems: First, it looks like mailman and mailmanctl should be passing a failure code back to the init script, so that the init script won't incorrectly assume that everything is hunky-dory. Second, perhaps 

Reproducible: Didn't try
Steps to Reproduce:
1. Start mailman if it isn't already:
    /etc/init.d/mailman start
2. Kill it abrubtly:
    ps -u mailman -opid --noheader | xargs kill -9
3. Convince init.d that it hasn't actually started:
    rm /var/lib/init.d/started/mailman
(at this point, you're at the right initial conditions for the bug: a stale lock file.)
4. Try starting mailman again:
    /etc/init.d/mailman start
5. Observe that it hasn't:
    ps auxww | grep runner
(Expect no processes in the output except maybe the grep.)
6. Manually invoke mailman as the init script does:
    su - mailman -c 'bin/mailmanctl start'
You should see the message:
  The master qrunner lock could not be acquired.  It appears as though there is
  a stale master qrunner lock.  Try re-running mailmanctl with the -s flag.
7. Recover by invoking mailman with the -s flag, as it suggests:
    su - mailman -c 'bin/mailmanctl -s start'
8. Observe that it has started:
    ps auxww | grep runner
8. Now kill mailman to get init.d back in sync:
    su - mailman -c 'bin/mailmanctl stop'
    /etc/init.d/mailman start

Actual Results:  
(described inline in "Steps to Reproduce" section above)

Expected Results:  
(described in "Details" section above)
Comment 1 Jon Howell 2004-09-11 07:38:50 UTC
This occurs with:
net-mail/mailman-2.1.4 *
Comment 2 Tuan Van (RETIRED) gentoo-dev 2004-09-13 16:21:06 UTC
Jon, would you be able come up with a patch? If not, I'll look in to this when I got a chance. Thanks.
Comment 3 Jakub Moc (RETIRED) gentoo-dev 2006-08-19 16:01:58 UTC
Is this even remotely relevant after two years?
Comment 4 Jon Howell 2006-08-21 17:44:45 UTC
> Is this even remotely relevant after two years?

No idea. I think it's a bug in the gentoo init.d script, however, so it won't automatically have been cured by changes in the upstream. If the gentoo init.d hasn't changed in two years, then the bug is still there. Mailman is one of those services you really want to start up correctly every time...

(It's no longer relevant to me personally, though, because I'm not running any mailman lists.)
Comment 5 Jakub Moc (RETIRED) gentoo-dev 2006-09-14 08:38:01 UTC
Shrug... User no longer uses this, closing.