Home | History | Annotate | Line # | Download | only in html
postsuper.1.html revision 1.1
      1  1.1  tron <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"
      2  1.1  tron         "http://www.w3.org/TR/html4/loose.dtd">
      3  1.1  tron <html> <head>
      4  1.1  tron <meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
      5  1.1  tron <title> Postfix manual - postsuper(1) </title>
      6  1.1  tron </head> <body> <pre>
      7  1.1  tron POSTSUPER(1)                                                      POSTSUPER(1)
      8  1.1  tron 
      9  1.1  tron <b>NAME</b>
     10  1.1  tron        postsuper - Postfix superintendent
     11  1.1  tron 
     12  1.1  tron <b>SYNOPSIS</b>
     13  1.1  tron        <b>postsuper</b> [<b>-psv</b>] [<b>-c</b> <i>config</i><b>_</b><i>dir</i>] [<b>-d</b> <i>queue</i><b>_</b><i>id</i>]
     14  1.1  tron                [<b>-h</b> <i>queue</i><b>_</b><i>id</i>] [<b>-H</b> <i>queue</i><b>_</b><i>id</i>]
     15  1.1  tron                [<b>-r</b> <i>queue</i><b>_</b><i>id</i>] [<i>directory ...</i>]
     16  1.1  tron 
     17  1.1  tron <b>DESCRIPTION</b>
     18  1.1  tron        The  <a href="postsuper.1.html"><b>postsuper</b>(1)</a>  command  does  maintenance  jobs on the
     19  1.1  tron        Postfix queue. Use of the command  is  restricted  to  the
     20  1.1  tron        superuser.   See the <a href="postqueue.1.html"><b>postqueue</b>(1)</a> command for unprivileged
     21  1.1  tron        queue operations such as  listing  or  flushing  the  mail
     22  1.1  tron        queue.
     23  1.1  tron 
     24  1.1  tron        By default, <a href="postsuper.1.html"><b>postsuper</b>(1)</a> performs the operations requested
     25  1.1  tron        with the <b>-s</b> and <b>-p</b> command-line  options  on  all  Postfix
     26  1.1  tron        queue directories - this includes the <b>incoming</b>, <b>active</b> and
     27  1.1  tron        <b>deferred</b> directories  with  mail  files  and  the  <b>bounce</b>,
     28  1.1  tron        <b>defer</b>, <b>trace</b> and <b>flush</b> directories with log files.
     29  1.1  tron 
     30  1.1  tron        Options:
     31  1.1  tron 
     32  1.1  tron        <b>-c</b> <i>config</i><b>_</b><i>dir</i>
     33  1.1  tron               The  <a href="postconf.5.html"><b>main.cf</b></a>  configuration  file  is  in the named
     34  1.1  tron               directory  instead  of  the  default  configuration
     35  1.1  tron               directory.  See  also  the  MAIL_CONFIG environment
     36  1.1  tron               setting below.
     37  1.1  tron 
     38  1.1  tron        <b>-d</b> <i>queue</i><b>_</b><i>id</i>
     39  1.1  tron               Delete one message with the named queue ID from the
     40  1.1  tron               named   mail  queue(s)  (default:  <b>hold</b>,  <b>incoming</b>,
     41  1.1  tron               <b>active</b> and <b>deferred</b>).
     42  1.1  tron 
     43  1.1  tron               If a <i>queue</i><b>_</b><i>id</i> of <b>-</b> is specified, the program  reads
     44  1.1  tron               queue  IDs  from  standard  input.  For example, to
     45  1.1  tron               delete  all  mail  with   exactly   one   recipient
     46  1.1  tron               <b>user (a] example.com</b>:
     47  1.1  tron 
     48  1.1  tron               mailq | tail +2 | grep -v '^ *(' | awk  'BEGIN { RS = "" }
     49  1.1  tron                   # $7=sender, $8=recipient1, $9=recipient2
     50  1.1  tron                   { if ($8 == "user (a] example.com" &amp;&amp; $9 == "")
     51  1.1  tron                         print $1 }
     52  1.1  tron               ' | tr -d '*!' | postsuper -d -
     53  1.1  tron 
     54  1.1  tron               Specify  "<b>-d ALL</b>" to remove all messages; for exam-
     55  1.1  tron               ple, specify "<b>-d ALL deferred</b>" to delete  all  mail
     56  1.1  tron               in  the  <b>deferred</b>  queue.  As a safety measure, the
     57  1.1  tron               word <b>ALL</b> must be specified in upper case.
     58  1.1  tron 
     59  1.1  tron               Warning: Postfix queue IDs are reused.  There is  a
     60  1.1  tron               very  small  possibility that postsuper deletes the
     61  1.1  tron               wrong message file when it is  executed  while  the
     62  1.1  tron               Postfix mail system is delivering mail.
     63  1.1  tron 
     64  1.1  tron               The scenario is as follows:
     65  1.1  tron 
     66  1.1  tron               1)     The  Postfix  queue manager deletes the mes-
     67  1.1  tron                      sage that <a href="postsuper.1.html"><b>postsuper</b>(1)</a> is asked  to  delete,
     68  1.1  tron                      because Postfix is finished with the message
     69  1.1  tron                      (it is delivered, or it is returned  to  the
     70  1.1  tron                      sender).
     71  1.1  tron 
     72  1.1  tron               2)     New  mail  arrives,  and  the new message is
     73  1.1  tron                      given the same queue ID as the message  that
     74  1.1  tron                      <a href="postsuper.1.html"><b>postsuper</b>(1)</a>  is  supposed  to  delete.  The
     75  1.1  tron                      probability for reusing a deleted  queue  ID
     76  1.1  tron                      is about 1 in 2**15 (the number of different
     77  1.1  tron                      microsecond values that the system clock can
     78  1.1  tron                      distinguish within a second).
     79  1.1  tron 
     80  1.1  tron               3)     <a href="postsuper.1.html"><b>postsuper</b>(1)</a>   deletes   the   new  message,
     81  1.1  tron                      instead of the old message  that  it  should
     82  1.1  tron                      have deleted.
     83  1.1  tron 
     84  1.1  tron        <b>-h</b> <i>queue</i><b>_</b><i>id</i>
     85  1.1  tron               Put  mail  "on  hold" so that no attempt is made to
     86  1.1  tron               deliver it.  Move one message with the named  queue
     87  1.1  tron               ID from the named mail queue(s) (default: <b>incoming</b>,
     88  1.1  tron               <b>active</b> and <b>deferred</b>) to the <b>hold</b> queue.
     89  1.1  tron 
     90  1.1  tron               If a <i>queue</i><b>_</b><i>id</i> of <b>-</b> is specified, the program  reads
     91  1.1  tron               queue IDs from standard input.
     92  1.1  tron 
     93  1.1  tron               Specify "<b>-h ALL</b>" to hold all messages; for example,
     94  1.1  tron               specify "<b>-h ALL deferred</b>" to hold all mail  in  the
     95  1.1  tron               <b>deferred</b>  queue.  As a safety measure, the word <b>ALL</b>
     96  1.1  tron               must be specified in upper case.
     97  1.1  tron 
     98  1.1  tron               Note: while mail is "on hold" it  will  not  expire
     99  1.1  tron               when  its  time  in  the  queue  exceeds  the <b><a href="postconf.5.html#maximal_queue_lifetime">maxi</a>-</b>
    100  1.1  tron               <b><a href="postconf.5.html#maximal_queue_lifetime">mal_queue_lifetime</a></b>  or  <b><a href="postconf.5.html#bounce_queue_lifetime">bounce_queue_lifetime</a></b>  set-
    101  1.1  tron               ting.  It becomes subject to expiration after it is
    102  1.1  tron               released from "hold".
    103  1.1  tron 
    104  1.1  tron               This feature is available in Postfix 2.0 and later.
    105  1.1  tron 
    106  1.1  tron        <b>-H</b> <i>queue</i><b>_</b><i>id</i>
    107  1.1  tron               Release mail that was put "on hold".  Move one mes-
    108  1.1  tron               sage with the named queue ID from  the  named  mail
    109  1.1  tron               queue(s) (default: <b>hold</b>) to the <b>deferred</b> queue.
    110  1.1  tron 
    111  1.1  tron               If  a <i>queue</i><b>_</b><i>id</i> of <b>-</b> is specified, the program reads
    112  1.1  tron               queue IDs from standard input.
    113  1.1  tron 
    114  1.1  tron               Note: specify "<b>postsuper -r</b>" to release  mail  that
    115  1.1  tron               was  kept  on  hold  for  a significant fraction of
    116  1.1  tron               <b>$<a href="postconf.5.html#maximal_queue_lifetime">maximal_queue_lifetime</a></b> or  <b>$<a href="postconf.5.html#bounce_queue_lifetime">bounce_queue_lifetime</a></b>,
    117  1.1  tron               or longer.
    118  1.1  tron 
    119  1.1  tron               Specify  "<b>-H  ALL</b>"  to release all mail that is "on
    120  1.1  tron               hold".  As a safety measure, the word <b>ALL</b>  must  be
    121  1.1  tron               specified in upper case.
    122  1.1  tron 
    123  1.1  tron               This feature is available in Postfix 2.0 and later.
    124  1.1  tron 
    125  1.1  tron        <b>-p</b>     Purge old temporary files that are left over  after
    126  1.1  tron               system or software crashes.
    127  1.1  tron 
    128  1.1  tron        <b>-r</b> <i>queue</i><b>_</b><i>id</i>
    129  1.1  tron               Requeue  the  message  with the named queue ID from
    130  1.1  tron               the named mail queue(s) (default:  <b>hold</b>,  <b>incoming</b>,
    131  1.1  tron               <b>active</b>  and  <b>deferred</b>).   To  requeue multiple mes-
    132  1.1  tron               sages, specify multiple <b>-r</b> command-line options.
    133  1.1  tron 
    134  1.1  tron               Alternatively, if a <i>queue</i><b>_</b><i>id</i> of <b>-</b> is specified, the
    135  1.1  tron               program reads queue IDs from standard input.
    136  1.1  tron 
    137  1.1  tron               Specify  "<b>-r  ALL</b>"  to  requeue  all messages. As a
    138  1.1  tron               safety measure, the word <b>ALL</b> must be  specified  in
    139  1.1  tron               upper case.
    140  1.1  tron 
    141  1.1  tron               A  requeued message is moved to the <b>maildrop</b> queue,
    142  1.1  tron               from where  it  is  copied  by  the  <a href="pickup.8.html"><b>pickup</b>(8)</a>  and
    143  1.1  tron               <a href="cleanup.8.html"><b>cleanup</b>(8)</a>  daemons  to  a  new queue file. In many
    144  1.1  tron               respects its handling differs from that  of  a  new
    145  1.1  tron               local submission.
    146  1.1  tron 
    147  1.1  tron               <b>o</b>      The   message   is   not  subjected  to  the
    148  1.1  tron                      <a href="postconf.5.html#smtpd_milters">smtpd_milters</a> or <a href="postconf.5.html#non_smtpd_milters">non_smtpd_milters</a> settings.
    149  1.1  tron                      When  mail  has  passed  through an external
    150  1.1  tron                      content filter, this would produce incorrect
    151  1.1  tron                      results with Milter applications that depend
    152  1.1  tron                      on original SMTP connection  state  informa-
    153  1.1  tron                      tion.
    154  1.1  tron 
    155  1.1  tron               <b>o</b>      The  message  is  subjected  again  to  mail
    156  1.1  tron                      address rewriting and substitution.  This is
    157  1.1  tron                      useful  when rewriting rules or virtual map-
    158  1.1  tron                      pings have changed.
    159  1.1  tron 
    160  1.1  tron                      The  address  rewriting  context  (local  or
    161  1.1  tron                      remote)  is the same as when the message was
    162  1.1  tron                      received.
    163  1.1  tron 
    164  1.1  tron               <b>o</b>      The message is subjected to  the  same  <a href="postconf.5.html#content_filter">con</a>-
    165  1.1  tron                      <a href="postconf.5.html#content_filter">tent_filter</a>  settings  (if  any) as used for
    166  1.1  tron                      new local mail submissions.  This is  useful
    167  1.1  tron                      when <a href="postconf.5.html#content_filter">content_filter</a> settings have changed.
    168  1.1  tron 
    169  1.1  tron               Warning:  Postfix queue IDs are reused.  There is a
    170  1.1  tron               very small possibility that  <a href="postsuper.1.html"><b>postsuper</b>(1)</a>  requeues
    171  1.1  tron               the  wrong  message  file when it is executed while
    172  1.1  tron               the Postfix mail system is  running,  but  no  harm
    173  1.1  tron               should be done.
    174  1.1  tron 
    175  1.1  tron               This feature is available in Postfix 1.1 and later.
    176  1.1  tron 
    177  1.1  tron        <b>-s</b>     Structure check and structure repair.  This  should
    178  1.1  tron               be done once before Postfix startup.
    179  1.1  tron 
    180  1.1  tron               <b>o</b>      Rename  files  whose name does not match the
    181  1.1  tron                      message file inode number. This operation is
    182  1.1  tron                      necessary  after restoring a mail queue from
    183  1.1  tron                      a different machine, or from backup media.
    184  1.1  tron 
    185  1.1  tron               <b>o</b>      Move queue files that are in the wrong place
    186  1.1  tron                      in the file system hierarchy and remove sub-
    187  1.1  tron                      directories that are no longer needed.  File
    188  1.1  tron                      position  rearrangements are necessary after
    189  1.1  tron                      a  change  in  the  <b><a href="postconf.5.html#hash_queue_names">hash_queue_names</a></b>  and/or
    190  1.1  tron                      <b><a href="postconf.5.html#hash_queue_depth">hash_queue_depth</a></b> configuration parameters.
    191  1.1  tron 
    192  1.1  tron        <b>-v</b>     Enable verbose logging for debugging purposes. Mul-
    193  1.1  tron               tiple <b>-v</b> options  make  the  software  increasingly
    194  1.1  tron               verbose.
    195  1.1  tron 
    196  1.1  tron <b>DIAGNOSTICS</b>
    197  1.1  tron        Problems  are reported to the standard error stream and to
    198  1.1  tron        <b>syslogd</b>(8).
    199  1.1  tron 
    200  1.1  tron        <a href="postsuper.1.html"><b>postsuper</b>(1)</a> reports the number of messages  deleted  with
    201  1.1  tron        <b>-d</b>,  the number of messages requeued with <b>-r</b>, and the num-
    202  1.1  tron        ber of messages whose queue file name was fixed  with  <b>-s</b>.
    203  1.1  tron        The  report is written to the standard error stream and to
    204  1.1  tron        <b>syslogd</b>(8).
    205  1.1  tron 
    206  1.1  tron <b>ENVIRONMENT</b>
    207  1.1  tron        MAIL_CONFIG
    208  1.1  tron               Directory with the <a href="postconf.5.html"><b>main.cf</b></a> file.
    209  1.1  tron 
    210  1.1  tron <b>BUGS</b>
    211  1.1  tron        Mail that is not sanitized by Postfix (i.e.  mail  in  the
    212  1.1  tron        <b>maildrop</b> queue) cannot be placed "on hold".
    213  1.1  tron 
    214  1.1  tron <b>CONFIGURATION PARAMETERS</b>
    215  1.1  tron        The  following  <a href="postconf.5.html"><b>main.cf</b></a> parameters are especially relevant
    216  1.1  tron        to this program.  The text below provides only a parameter
    217  1.1  tron        summary.  See <a href="postconf.5.html"><b>postconf</b>(5)</a> for more details including exam-
    218  1.1  tron        ples.
    219  1.1  tron 
    220  1.1  tron        <b><a href="postconf.5.html#config_directory">config_directory</a> (see 'postconf -d' output)</b>
    221  1.1  tron               The default location of  the  Postfix  <a href="postconf.5.html">main.cf</a>  and
    222  1.1  tron               <a href="master.5.html">master.cf</a> configuration files.
    223  1.1  tron 
    224  1.1  tron        <b><a href="postconf.5.html#hash_queue_depth">hash_queue_depth</a> (1)</b>
    225  1.1  tron               The  number of subdirectory levels for queue direc-
    226  1.1  tron               tories listed with the <a href="postconf.5.html#hash_queue_names">hash_queue_names</a>  parameter.
    227  1.1  tron 
    228  1.1  tron        <b><a href="postconf.5.html#hash_queue_names">hash_queue_names</a> (deferred, defer)</b>
    229  1.1  tron               The  names  of  queue  directories  that  are split
    230  1.1  tron               across multiple subdirectory levels.
    231  1.1  tron 
    232  1.1  tron        <b><a href="postconf.5.html#queue_directory">queue_directory</a> (see 'postconf -d' output)</b>
    233  1.1  tron               The location of the Postfix top-level queue  direc-
    234  1.1  tron               tory.
    235  1.1  tron 
    236  1.1  tron        <b><a href="postconf.5.html#syslog_facility">syslog_facility</a> (mail)</b>
    237  1.1  tron               The syslog facility of Postfix logging.
    238  1.1  tron 
    239  1.1  tron        <b><a href="postconf.5.html#syslog_name">syslog_name</a> (see 'postconf -d' output)</b>
    240  1.1  tron               The  mail  system  name  that  is  prepended to the
    241  1.1  tron               process name in syslog  records,  so  that  "smtpd"
    242  1.1  tron               becomes, for example, "postfix/smtpd".
    243  1.1  tron 
    244  1.1  tron <b>SEE ALSO</b>
    245  1.1  tron        <a href="sendmail.1.html">sendmail(1)</a>, Sendmail-compatible user interface
    246  1.1  tron        <a href="postqueue.1.html">postqueue(1)</a>, unprivileged queue operations
    247  1.1  tron 
    248  1.1  tron <b>LICENSE</b>
    249  1.1  tron        The  Secure  Mailer  license must be distributed with this
    250  1.1  tron        software.
    251  1.1  tron 
    252  1.1  tron <b>AUTHOR(S)</b>
    253  1.1  tron        Wietse Venema
    254  1.1  tron        IBM T.J. Watson Research
    255  1.1  tron        P.O. Box 704
    256  1.1  tron        Yorktown Heights, NY 10598, USA
    257  1.1  tron 
    258  1.1  tron                                                                   POSTSUPER(1)
    259  1.1  tron </pre> </body> </html>
    260