The Artima Developer Community
Sponsored Link

Perl Buzz Forum
Flush specific messages from sendmail queue

0 replies.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a flat view of this topic  Flat View
Previous Topic   Next Topic
Threaded View: This topic has 0 replies on 1 page
Chris Winters

Posts: 931
Nickname: cwinters
Registered: Jul, 2003

Daytime: Java hacker; nighttime: Perl hacker; sleeptime: some of both.
Flush specific messages from sendmail queue Posted: Aug 20, 2003 1:03 PM
Reply to this message Reply

This post originated from an RSS feed registered with Perl Buzz by Chris Winters.
Original Post: Flush specific messages from sendmail queue
Feed Title: cwinters.com
Feed URL: http://www.cwinters.com/raw/cwinters_perl.rdf
Feed Description: Chris Winters on Perl, programming and technology
Latest Perl Buzz Posts
Latest Perl Buzz Posts by Chris Winters
Latest Posts From cwinters.com

I just found out about this feature for flushing the sendmail queue. This is useful if, say, your mail server was down all weekend and you JUST CAN'T WAIT for the normal queue flush to occur because you've gone through email withdrawl by not being connected for a couple days. In the event that you, say, just rebuilt your mail server and wanted to make sure everything was working correctly you'd also want to watch the queue as it's processing. Normally you'd just run the following to flush the queue and see the results:
# /usr/sbin/sendmail -q -v

This is fine, but you wind up hanging on those other lame entries in the queue there because the mail server is offline, doesn't exist, didn't have its coffee, etc. The timeouts on these things will kill you and you never know where they'll appear during your flush. This means no immediate gratification, which was the whole point of the exercise. Instead you can tell sendmail to only flush certain items from the queue with an additional argument to -q. So you can do:

# /usr/sbin/sendmail -qR cwinters.com -v

To only process entries in the queue with a recipient having 'cwinters.com' in it. Sweet! You can also use -qS to match on the sender and -qI to match on the queue ID.

Read: Flush specific messages from sendmail queue


Topic: Flush specific messages from sendmail queue Previous Topic   Next Topic Topic: Copying Array Versus Array Reference

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use