Loading ...
Sorry, an error occurred while loading the content.

Re: check if postfix is running

Expand Messages
  • Victor Duchovni
    ... Yes, works except for any sites foolish enough to use ${foo} in the definition of daemon_directory. So the pedantic solutio is the one via postfix(1)
    Message 1 of 15 , Mar 31, 2007
    • 0 Attachment
      On Sat, Mar 31, 2007 at 03:10:12PM -0400, Wietse Venema wrote:

      > > # daemon_directory=/...
      > > # sh -c "$daemon_directory/master -t" ||
      > > echo "postfix is running"
      >
      > This involves nothing but 100% external interfaces:
      >
      > daemon_directory="`postconf -h daemon_directory` || exit 1
      > $daemon_directory/master -t ||
      > echo "postfix is running"
      >
      > All one has to do is RTFM postconf(1) and master(8).

      Yes, works except for any sites foolish enough to use "${foo}" in the
      definition of daemon_directory. So the pedantic solutio is the one
      via postfix(1) where $daemon_directory is sure to be fully expanded,
      but adding a "status" sub-command is clearly best.

      --
      Viktor.

      Disclaimer: off-list followups get on-list replies or get ignored.
      Please do not ignore the "Reply-To" header.

      To unsubscribe from the postfix-users list, visit
      http://www.postfix.org/lists.html or click the link below:
      <mailto:majordomo@...?body=unsubscribe%20postfix-users>

      If my response solves your problem, the best way to thank me is to not
      send an "it worked, thanks" follow-up. If you must respond, please put
      "It worked, thanks" in the "Subject" so I can delete these quickly.
    Your message has been successfully submitted and would be delivered to recipients shortly.