Re: stopping mail

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tony.chamberlain@xxxxxxxxx wrote:
> 
> I made a monitor from my machine (CentOS 4.5) to do an http to a machine 
> retrieve some info to see if a process is running (on this remote machine I have
> a task running so it is easy to get the info from my machine).
> 
> If I cannot access the remote machine, my machine sends mail to me and a couple
> other people saying the machine is unreachable. My cronjob runs every 5 minutes.
> Juts occured to me now though that if our network goes down, my machine will be
> sending mail every 5 minutes saying the machine is unreachable. These messages
> will get stored on my machine and all get sent when it comes up.

> I am wondering whether someone knows how to cancel mail that is queued on a machine, so it 
> doesn't all get sent out. I do have root access.

which mailserver are you running?

sendmail:

a combination of sendmail -bp and rm seems to work:

http://www.cwinters.com/news/display/?news_id=1000
http://www.freebsddiary.org/mailqueue.php

postfix:
man postsuper

google++

:)


alternatively you could change the cron script to only attempt
connections to the remote machine IF your local network is up...

Stuart


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux