Re: [Mailman-Users] Monitor qrunner
What would happen if during the check you told mailman to stop first? Could this mess things up or would it be fine? Robert Haack Programmer Analyst North Clackamas School District #12 [EMAIL PROTECTED] Mark Sapiro wrote: Jess Mooers wrote: So here is my question: Is there a way to monitor qrunner to see if it is running? If it is running, you will find its pid in data/master-qrunner.pid and there will also be two files in locks/, one named master-qrunner and containing the line master-qrunner.host.example.com.pid And the second named master-qrunner.host.example.com.pid and having the same contents where host.example.com is the actual host name and pid is the actual pid of the master qrunner process. Thus there are three files that if present will give you the pid of the master qrunner. Of course, if it died a horrible death, the files might be left behind, so you also have to check if the pid is running and is a mailmanctl process. If the files are missing or the pid doesn't exist or is not a python process invoked with a mailmanctl command, then the master qrunner isn't running. Is there a way to start it automatically if it is not? You can test all of that in a fairly simple shell script which will run bin/mailmanctl -s -q start if the master isn't running and then execute that shell script every 5 or 10 minutes with cron. Or you can just run bin/mailmanctl start periodically with cron, but that will generate an error each time it is done with the master already running. And don't do bin/mailmanctl -s start without testing first or you'll start multiple masters and qrunners. -- Mark Sapiro [EMAIL PROTECTED] The highway is for gamblers, San Francisco Bay Area, Californiabetter use your sense - B. Dylan -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/haack%40nclack.k12.or.us Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=showamp;file=faq01.027.htp -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=showamp;file=faq01.027.htp
Re: [Mailman-Users] Monitor qrunner
Robert Haack [EMAIL PROTECTED] wrote on Wednesday, May 25, 2005: What would happen if during the check you told mailman to stop first? Could this mess things up or would it be fine? Robert Haack Robert, I actually just setup the cron job to execute with the following command. It does produce an error in the log, but that is the least of my worries, nor do I mind it. /usr/share/mailman/bin/mailmanctl -q start Thanks for the replies. Regards, Jess Mooers ~~~ Landmann InterActive 1423 S. Park St., Madison, WI 53715 W 608-257-1558 F 608-257-8705 www.landmanninteractive.com -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=showamp;file=faq01.027.htp
Re: [Mailman-Users] Monitor qrunner
Mark Sapiro wrote: If it is running, you will find its pid in data/master-qrunner.pid and there will also be two files in locks/, one named master-qrunner and containing the line master-qrunner.host.example.com.pid And the second named master-qrunner.host.example.com.pid and having the same contents where host.example.com is the actual host name and pid is the actual pid of the master qrunner process. Thus there are three files that if present will give you the pid of the master qrunner. Of course, if it died a horrible death, the files might be left behind, so you also have to check if the pid is running and is a mailmanctl process. If the files are missing or the pid doesn't exist or is not a python process invoked with a mailmanctl command, then the master qrunner isn't running. Mark's point about the presence of the file not being a definitive metric of mailman health should not be ignored. You really have to ascertain the status of the process. If mailman is abnormally aborting, which is what started this thread, then there is a high degree of probably the lock files will be left behind and testing them will give false positives. In the Red Hat mailman RPM's we've modified mailmanctl so that it can be asked the status of the mailman process as an unprivledged user and return the result as status to the shell as well as printing a message. Since mailmanctl knows how to locate the process and communicate with the process via signals it makes mailmanctl the optimal reporter of status. It was probably an oversight mailmanctl never had this facility. We have also integrated this with the mailman init.d script so that one can perform the standard service mailman status command. The init.d script depends on the exit status of mailmanctl status. These two changes probably represent a more robust and standard way to determine status. I'm attaching our patch for this in case someone finds it useful. On Wed, 2005-05-25 at 08:13 -0700, Robert Haack wrote: What would happen if during the check you told mailman to stop first? Could this mess things up or would it be fine? Yes you could do that, it is essentially the same thing as service mailman restart if you're running on an OS that supports sysV style service management. -- John Dennis [EMAIL PROTECTED] -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=showamp;file=faq01.027.htp
Re: [Mailman-Users] Monitor qrunner
At 11:44 AM -0400 2005-05-25, John Dennis wrote: I'm attaching our patch for this in case someone finds it useful. The attachment was stripped. Could you post it as a patch at the SourceForge page instead? -- Brad Knowles, [EMAIL PROTECTED] Those who would give up essential Liberty, to purchase a little temporary Safety, deserve neither Liberty nor Safety. -- Benjamin Franklin (1706-1790), reply of the Pennsylvania Assembly to the Governor, November 11, 1755 SAGE member since 1995. See http://www.sage.org/ for more info. -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=showamp;file=faq01.027.htp
Re: [Mailman-Users] Monitor qrunner
On Wed, 2005-05-25 at 19:39 +0200, Brad Knowles wrote: At 11:44 AM -0400 2005-05-25, John Dennis wrote: I'm attaching our patch for this in case someone finds it useful. The attachment was stripped. Could you post it as a patch at the SourceForge page instead? Yeah, I should have known it would have been stripped. Patch id is 1208685. -- John Dennis [EMAIL PROTECTED] -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=showamp;file=faq01.027.htp
[Mailman-Users] Monitor qrunner
Hi list, I am somewhat new to mailman, so please bear with me. I currently have 5 lists running, all configured differently, and when it is working, I love mailman. I have now encountered 3 situations where the qrunner stops or quits. We don't know that the system is not running correctly until our clients let us know (VERY BAD). I have one client in particular that I could loose if this happens again. So here is my question: Is there a way to monitor qrunner to see if it is running? Is there a way to start it automatically if it is not? I am running Mac OS 10.3 Server, on an XServe, 250GB HD, 3Gigs of ram. Any help ASAP would be so greatly appreciated. Regards, Jess Mooers ~~~ Landmann InterActive 1423 S. Park St., Madison, WI 53715 W 608-257-1558 F 608-257-8705 www.landmanninteractive.com -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=showamp;file=faq01.027.htp
Re: [Mailman-Users] Monitor qrunner
Jess Mooers wrote: So here is my question: Is there a way to monitor qrunner to see if it is running? If it is running, you will find its pid in data/master-qrunner.pid and there will also be two files in locks/, one named master-qrunner and containing the line master-qrunner.host.example.com.pid And the second named master-qrunner.host.example.com.pid and having the same contents where host.example.com is the actual host name and pid is the actual pid of the master qrunner process. Thus there are three files that if present will give you the pid of the master qrunner. Of course, if it died a horrible death, the files might be left behind, so you also have to check if the pid is running and is a mailmanctl process. If the files are missing or the pid doesn't exist or is not a python process invoked with a mailmanctl command, then the master qrunner isn't running. Is there a way to start it automatically if it is not? You can test all of that in a fairly simple shell script which will run bin/mailmanctl -s -q start if the master isn't running and then execute that shell script every 5 or 10 minutes with cron. Or you can just run bin/mailmanctl start periodically with cron, but that will generate an error each time it is done with the master already running. And don't do bin/mailmanctl -s start without testing first or you'll start multiple masters and qrunners. -- Mark Sapiro [EMAIL PROTECTED] The highway is for gamblers, San Francisco Bay Area, Californiabetter use your sense - B. Dylan -- Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=showamp;file=faq01.027.htp