On 2015-01-28 05:47, Seth wrote:
On Tue, 27 Jan 2015 20:18:04 -0800, Edgar Pettijohn
<[email protected]> wrote:
Still need to solve the problem of scheduling that big morning dump.
Of email.
cron
That's not really going to work because the power-up time could vary
between 2-4 hours. The mail needs to flow as soon as possible after
powering on the local server. What would be ideal is for the relaying
server to probe the local server every five minutes. As soon as an
active SMTP port is discovered on the local server, the relay sends
all queued emails.
Just an idea ... via cron:
#!/bin/sh
echo "quit" | nc -w 3 your.local.server 25
if [ $? -eq 0 ]; then
smtpctl show status | grep -q "MTA paused" && smtpctl resume mta
else
smtpctl show status | grep -q "MTA running" && smtpctl pause mta
fi
Stefan
--
You received this mail because you are subscribed to [email protected]
To unsubscribe, send a mail to: [email protected]