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