Re: when amavis is down mail from script does not go out

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Don Calfa
Date:  
To: plug-discuss
Subject: Re: when amavis is down mail from script does not go out
Awesome script!

Jeremy C. Reed wrote:

>On Thu, 22 Jul 2004 wrote:
>
>
>
>>I have a scirpt that will check to see how many messages are in postfix
>>que and when over 25 messages the script will then send out a message,
>>the problem is when amavis is down (usually the reason that the postfix
>>que is growing) postfix will not send out the message saying the que is
>>growing.
>>
>>
>
>Twenty-five messages seems very little, but I guess depends on the
>particular system. (I have seen queues with hundreds of thousands.)
>
>
>
>>Is it possible to send this message out with exim or some other way so
>>the que is down the help message can go out.
>>
>>
>
>So you want an alternative way to send outbound smtp mail?
>
> ( sleep 3 ; echo "HELO rainier" ; sleep 2 ; echo "MAIL FROM:
><>" ; sleep 1 ; echo "RCPT TO: <>";
>sleep 1 ; echo "DATA" ; sleep 1 ; echo "Subject: subject here" ; echo ;
>echo "." ; sleep 1 ; echo "QUIT" ) | telnet mail.host.somewhere 25
>
>All the above on one line worked for me.
>
>Alternatively, have a look at my mailout software.
> http://www.reedmedia.net/software/mailout/ source via CVS:
> http://cvs.berlios.de/cgi-bin/viewcvs.cgi/mailout/
>
>
>
>>Here is the script not sure if I have the > than 25 messages part
>>correct from when I can tell this should work.
>>if echo `/utilities/checkque` > [25]
>>
>>
>
>Greater than (>) means to the shell to create a file and redirect output
>to it.
>
>Have a look at the test man page.
>
>if [ `postqueue -p | grep ^[0-9] |wc -l` -gt 25 ] ; then
>
> Jeremy C. Reed
>
>                 BSD News, BSD tutorials, BSD links
>                http://www.bsdnewsletter.com/

>
>
>


---------------------------------------------------
PLUG-discuss mailing list -
To subscribe, unsubscribe, or to change you mail settings:
http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss