Sponsored Content
Full Discussion: flush the mail queue
Top Forums Shell Programming and Scripting flush the mail queue Post 302359785 by proactiveaditya on Wednesday 7th of October 2009 11:12:03 AM
Old 10-07-2009
Sendmail-sendmail -q command flushes mail queue.
Postfix-postfix flush OR postfix -f

Last edited by rbatte1; 11-17-2016 at 11:01 AM.. Reason: Added ICODE tags
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Clearing Mail Queue

Hello, I am trying to clear my mail queue with the following command: rm /var/spool/mqueue/* But when I do this I get this error: /bin/rm: Argument list too long. Can someone tell me what that error means and what I can do to correct it so I can clear my mail queue? Thanks (2 Replies)
Discussion started by: Chet
2 Replies

2. Shell Programming and Scripting

MyDoom in mail queue

Is there someone out there that has a script for cleaning up the mail queue after viruses such as MyDoom? (5 Replies)
Discussion started by: pmj1970
5 Replies

3. Shell Programming and Scripting

shell script needed for mail queue notification

Hi shell experts, I would like to have a shell script running in a redhat server for monitoring the mailqueue status. I have already installed the qmHandle and I am using it to get a status of the mail queue in daily basis. I am executing the qmhandle in the cron. Now I am planning to execute... (10 Replies)
Discussion started by: Nightman
10 Replies

4. HP-UX

lp print flush

Dear frnds, i just migrated to hp_ux11i from digital unix, from my new system some printers not printing next day, what i mean is, in lpstat it shows printer is enabled but printing not happening. for that what i do u know, i just disable the lp and enable it again. then it would print. is there... (0 Replies)
Discussion started by: jestinabel
0 Replies

5. UNIX for Advanced & Expert Users

mail is not sent, instead just coping into /var/spool/queue dir

Hi, I have some problems w/ the sendmail. I see that messages are queued in the /var/spool/mqueue and they are never sent to the recipients. This problem just suddenly started without any modifications in the current configuration. I already started and stop the sendmail and it did not help.... (3 Replies)
Discussion started by: ktanya
3 Replies

6. IP Networking

postfix - reinject mail to postfix from hold queue directory

hi all. Am using smtpd_recipient_restrictions & check_recipient_access in postfix. The hash file looks like this: emailaddress1 HOLD emailaddress2 HOLD The aim is to place email from these recipients in the hold directory,check them then reinject them back in postfix on some... (0 Replies)
Discussion started by: coolatt
0 Replies

7. Emergency UNIX and Linux Support

DNS flush is not working

I have a Linux machine and it seems DNS cache is not getting clear on it. It is still showing old values, even after changing in DNS server by Network team. I did /etc/init.d/nscd restart But still it is showing old values on this server. On my rest of servers in environment, nslookup is showing... (7 Replies)
Discussion started by: solaris_1977
7 Replies

8. UNIX for Dummies Questions & Answers

Mail Queue refilling

Hello I'm using Cent OS6 and a webmin interface I've had an issue where over 1 million emails were queued in the sendmail mail queue. I found a thread on here from 2002 explaining how to delete them all and it worked great. Thanks Perderabu unix-for-dummies-questions-and-answers /... (0 Replies)
Discussion started by: bullbreed
0 Replies

9. Shell Programming and Scripting

Check pending mail in mail queue

I know the command mailq can check the pending mail in mqueue , and also have another command to check POSIX mail queue in server , now I will regularly check the mqueue manually , it is time consuming , would advise the script that could help to check the mail queue , and then send the details to... (3 Replies)
Discussion started by: ust3
3 Replies

10. Shell Programming and Scripting

Check mail queue

We use Redhat server , we always use mailq to check any pending mail in mailq , when run the command mailq , it shows all existing pending mail would advise how to write a script to show the pending mails which are older than 24 hours , ( if possible , then send this pending mail info to... (9 Replies)
Discussion started by: ust3
9 Replies
POSTQUEUE(1)						      General Commands Manual						      POSTQUEUE(1)

NAME
postqueue - Postfix queue control SYNOPSIS
postqueue [-v] [-c config_dir] -f postqueue [-v] [-c config_dir] -i queue_id postqueue [-v] [-c config_dir] -p postqueue [-v] [-c config_dir] -s site DESCRIPTION
The postqueue(1) command implements the Postfix user interface for queue management. It implements operations that are traditionally avail- able via the sendmail(1) command. See the postsuper(1) command for queue operations that require super-user privileges such as deleting a message from the queue or changing the status of a message. The following options are recognized: -c config_dir The main.cf configuration file is in the named directory instead of the default configuration directory. See also the MAIL_CONFIG environment setting below. -f Flush the queue: attempt to deliver all queued mail. This option implements the traditional "sendmail -q" command, by contacting the Postfix qmgr(8) daemon. Warning: flushing undeliverable mail frequently will result in poor delivery performance of all other mail. -i queue_id Schedule immediate delivery of deferred mail with the specified queue ID. This option implements the traditional sendmail -qI command, by contacting the flush(8) server. This feature is available with Postfix version 2.4 and later. -p Produce a traditional sendmail-style queue listing. This option implements the traditional mailq command, by contacting the Postfix showq(8) daemon. Each queue entry shows the queue file ID, message size, arrival time, sender, and the recipients that still need to be delivered. If mail could not be delivered upon the last attempt, the reason for failure is shown. The queue ID string is followed by an optional status character: * The message is in the active queue, i.e. the message is selected for delivery. ! The message is in the hold queue, i.e. no further delivery attempt will be made until the mail is taken off hold. -s site Schedule immediate delivery of all mail that is queued for the named site. A numerical site must be specified as a valid RFC 2821 address literal enclosed in [], just like in email addresses. The site must be eligible for the "fast flush" service. See flush(8) for more information about the "fast flush" service. This option implements the traditional "sendmail -qRsite" command, by contacting the Postfix flush(8) daemon. -v Enable verbose logging for debugging purposes. Multiple -v options make the software increasingly verbose. As of Postfix 2.3, this option is available for the super-user only. SECURITY
This program is designed to run with set-group ID privileges, so that it can connect to Postfix daemon processes. DIAGNOSTICS
Problems are logged to syslogd(8) and to the standard error stream. ENVIRONMENT
MAIL_CONFIG Directory with the main.cf file. In order to avoid exploitation of set-group ID privileges, a non-standard directory is allowed only if: o The name is listed in the standard main.cf file with the alternate_config_directories configuration parameter. o The command is invoked by the super-user. CONFIGURATION PARAMETERS
The following main.cf parameters are especially relevant to this program. The text below provides only a parameter summary. See post- conf(5) for more details including examples. alternate_config_directories (empty) A list of non-default Postfix configuration directories that may be specified with "-c config_directory" on the command line, or via the MAIL_CONFIG environment parameter. config_directory (see 'postconf -d' output) The default location of the Postfix main.cf and master.cf configuration files. command_directory (see 'postconf -d' output) The location of all postfix administrative commands. fast_flush_domains ($relay_domains) Optional list of destinations that are eligible for per-destination logfiles with mail that is queued to those destinations. import_environment (see 'postconf -d' output) The list of environment parameters that a Postfix process will import from a non-Postfix parent process. queue_directory (see 'postconf -d' output) The location of the Postfix top-level queue directory. syslog_facility (mail) The syslog facility of Postfix logging. syslog_name (see 'postconf -d' output) The mail system name that is prepended to the process name in syslog records, so that "smtpd" becomes, for example, "postfix/smtpd". trigger_timeout (10s) The time limit for sending a trigger to a Postfix daemon (for example, the pickup(8) or qmgr(8) daemon). Available in Postfix version 2.2 and later: authorized_flush_users (static:anyone) List of users who are authorized to flush the queue. authorized_mailq_users (static:anyone) List of users who are authorized to view the queue. FILES
/var/spool/postfix, mail queue SEE ALSO
qmgr(8), queue manager showq(8), list mail queue flush(8), fast flush service sendmail(1), Sendmail-compatible user interface postsuper(1), privileged queue operations README FILES
Use "postconf readme_directory" or "postconf html_directory" to locate this information. ETRN_README, Postfix ETRN howto LICENSE
The Secure Mailer license must be distributed with this software. HISTORY
The postqueue command was introduced with Postfix version 1.1. AUTHOR(S) Wietse Venema IBM T.J. Watson Research P.O. Box 704 Yorktown Heights, NY 10598, USA POSTQUEUE(1)
All times are GMT -4. The time now is 04:14 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy