suspending lists from the command line

Hi there. During busy times I would like to suspend almost all lists,except some emergency ones.. Is there a way to achieve this from the command line via some script?
Many thanks, -turgut

turgut kalfaoglu wrote:
Hi there. During busy times I would like to suspend almost all lists,except some emergency ones.. Is there a way to achieve this from the command line via some script?
What do you mean by suspend? What you need to do depends on the answer to this. If you mean you want it to appear as if the list doesn't exist, i.e. mail to the list is undeliverable, the list is not visible on the web, you could create a shell script to move Mailman's various lists/LISTNAME/ directories aside and, depending on how mail is delivered to Mailman, update the necessary things in the MTA. Note that in some configurations mail is routed programmatically based on the existance of the lists/LISTNAME/ directory, so simple moving it aside would be sufficient in those cases.
If on the other hand you mean just set "emergency" moderation for the lists, consider the following bash script.
#!/bin/bash
cd /to/mailmans/bin/directory
f=mktemp
echo "emergency = True" > $f
for list in ./list_lists --bare
; do
if [[ "$list" != "emergency_list1"
&& "$list" != "emergency_list2"
&& "$list" != "etc" ]]; then
./config_list -i $f $list
fi
done
rm $f
To reverse this, change "emergency = True" to "emergency = False" and run the script again.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan

Thank you very much for your feedback. I just wanted to pause mail processing on most lists during the primetime. Right now I achieve the same thing by stopping mailman for a few hours during the prime time. However, some low-traffic, and important lists also get suspended that way, and I would rather find a more elegant solution if possible. I just would like to queue the mails coming to those lists during the day, release them when the server load gets low again.
Regards, -turgut
On 04/02/2012 11:38 PM, Mark Sapiro wrote:
turgut kalfaoglu wrote:
Hi there. During busy times I would like to suspend almost all lists,except some emergency ones.. Is there a way to achieve this from the command line via some script?
What do you mean by suspend? What you need to do depends on the answer to this. If you mean you want it to appear as if the list doesn't exist, i.e. mail to the list is undeliverable, the list is not visible on the web, you could create a shell script to move Mailman's various lists/LISTNAME/ directories aside and, depending on how mail is delivered to Mailman, update the necessary things in the MTA. Note that in some configurations mail is routed programmatically based on the existance of the lists/LISTNAME/ directory, so simple moving it aside would be sufficient in those cases.
If on the other hand you mean just set "emergency" moderation for the lists, consider the following bash script.
#!/bin/bash cd /to/mailmans/bin/directory f=mktemp echo "emergency = True"> $f for list in
./list_lists --bare
; do if [[ "$list" != "emergency_list1"
&& "$list" != "emergency_list2"
&& "$list" != "etc" ]]; then ./config_list -i $f $list fi done rm $fTo reverse this, change "emergency = True" to "emergency = False" and run the script again.

Thank you very much for your feedback. I just wanted to pause mail processing on most lists during the primetime. Right now I achieve the same thing by stopping mailman for a few hours during the prime time. However, some low-traffic, and important lists also get suspended that way, and I would rather find a more elegant solution if possible. I just would like to queue the mails coming to those lists during the day, release them when the server load gets low again.
I tried the maximum recipients patch that is suppose to pause mailman after X deliveries, but it hasn't seem to have worked.
Regards, -turgut
On 04/02/2012 11:38 PM, Mark Sapiro wrote:
turgut kalfaoglu wrote:
Hi there. During busy times I would like to suspend almost all lists,except some emergency ones.. Is there a way to achieve this from the command line via some script?
What do you mean by suspend? What you need to do depends on the answer to this. If you mean you want it to appear as if the list doesn't exist, i.e. mail to the list is undeliverable, the list is not visible on the web, you could create a shell script to move Mailman's various lists/LISTNAME/ directories aside and, depending on how mail is delivered to Mailman, update the necessary things in the MTA. Note that in some configurations mail is routed programmatically based on the existance of the lists/LISTNAME/ directory, so simple moving it aside would be sufficient in those cases.
If on the other hand you mean just set "emergency" moderation for the lists, consider the following bash script.
#!/bin/bash cd /to/mailmans/bin/directory f=mktemp echo "emergency = True"> $f for list in
./list_lists --bare
; do if [[ "$list" != "emergency_list1"
&& "$list" != "emergency_list2"
&& "$list" != "etc" ]]; then ./config_list -i $f $list fi done rm $fTo reverse this, change "emergency = True" to "emergency = False" and run the script again.

On 4/2/2012 9:44 PM, turgut kalfaoğlu wrote:
Thank you very much for your feedback. I just wanted to pause mail processing on most lists during the primetime. Right now I achieve the same thing by stopping mailman for a few hours during the prime time. However, some low-traffic, and important lists also get suspended that way, and I would rather find a more elegant solution if possible. I just would like to queue the mails coming to those lists during the day, release them when the server load gets low again.
Setting emergency moderation on those lists should do what you want, although you'll have to manually approve the posts that arrived while emergency was in effect.
I tried the maximum recipients patch that is suppose to pause mailman after X deliveries, but it hasn't seem to have worked.
What patch is that? Are you referring to the throttling patch linked from the FAQ at <http://wiki.list.org/x/j4A9>? That should work to slow mail delivery during peak times, but the drawback with that is it will still deliver posts in the order they arrived, i.e., your high priority lists won't have priority, but it should be better than just stopping Mailman.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan

Hi, We are running version 2.1.12 on Redhat. We have checkdbs running at 8AM each morning as mailman, it is not in the cron of root or any other user. We have alias-mgr set as administrator for a number of lists, and no moderator has been set. checkdbs is sending out double moderator requests for just those lists that alias-mgr is the admin for. Any thoughts as to how to troubelshoot OR an explanation. NOTE: all our settings and owners and moderators are exactly the same from the previous version.
Thank you, Frank Bell Application Systems Admin ISS 785-670-2334
1 Cor 15:10 "By the grace of God I am what I am, and His grace toward me was not in vain . . .."

Frank Bell wrote:
Hi, We are running version 2.1.12 on Redhat. We have checkdbs running at 8AM each morning as mailman, it is not in the cron of root or any other user. We have alias-mgr set as administrator for a number of lists, and no moderator has been set. checkdbs is sending out double moderator requests for just those lists that alias-mgr is the admin for. Any thoughts as to how to troubelshoot OR an explanation.
First, do the duplicates have the same Message-ID:? If so, the duplication almost certainly occurs downstraeam from Mailman.
Look in the MTA logs and/or compare the Received: header chain in the two messages.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
participants (3)
-
Frank Bell
-
Mark Sapiro
-
turgut kalfaoğlu