<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: sendmail check in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168251#M320893</link>
    <description>&lt;!--!*#--&gt;I assume you are using:&lt;BR /&gt;&lt;BR /&gt;/sbin/init.d/sendmail stop    -and-&lt;BR /&gt;/sbin/init.d/sendmail start   &lt;BR /&gt;&lt;BR /&gt;to stop/start sendmail.  If so, it shouldn't be an issue.&lt;BR /&gt;&lt;BR /&gt;You might also simply examine the return code from the start command with *?.  I believe it will return a non-zero if there are problems.&lt;BR /&gt;&lt;BR /&gt;Two other alternatives:&lt;BR /&gt;&lt;BR /&gt;UNIX95= ps -C sendmail -ocomm= | wc -l&lt;BR /&gt;&lt;BR /&gt;should be 1 if sendmail is running, &lt;BR /&gt;or you might look at the section of code in the start-up script that is used to check the status:&lt;BR /&gt;&lt;BR /&gt;   pidfile="/etc/mail/sendmail.pid"&lt;BR /&gt;   if [ -f $pidfile ]; then&lt;BR /&gt;     test "$pidfile" &amp;amp;&amp;amp; exec 0&amp;lt; $pidfile&lt;BR /&gt;     read -r PID&lt;BR /&gt;     sendserv=`ps -e | grep -E "^ [ ]*$PID .*sendmail" | wc -l`&lt;BR /&gt;      if [ $sendserv -ne 0 ]; then&lt;BR /&gt;           set_return&lt;BR /&gt;           echo "sendmail has already been started"&lt;BR /&gt;           exit $rval&lt;BR /&gt;      fi&lt;BR /&gt;    fi&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Wed, 26 Mar 2008 14:12:53 GMT</pubDate>
    <dc:creator>OldSchool</dc:creator>
    <dc:date>2008-03-26T14:12:53Z</dc:date>
    <item>
      <title>sendmail check</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168250#M320892</link>
      <description>hello,&lt;BR /&gt;&lt;BR /&gt;i want to reorganize sendmail logfile "mail.log" in a script. so i stop sendmail, copy "mail.log"  to a directory and start sendmail.&lt;BR /&gt;&lt;BR /&gt;how can i check, if sendmail runs ?&lt;BR /&gt;&lt;BR /&gt;i found some solutions, but in some cases, i have to install GNU products (which have a lot of Run-time dependencies) :&lt;BR /&gt;&lt;BR /&gt;- lsof -i :25 &lt;BR /&gt;- nmap  -v -p 25 -sT localhost&lt;BR /&gt;- netstat -an |grep &lt;PORT&gt;&lt;BR /&gt;- telnet localhost 25 &amp;lt;&amp;lt;&lt;BR /&gt;EO^]                    &lt;BR /&gt;close                 &lt;BR /&gt;EOF &lt;BR /&gt;&lt;BR /&gt;what is the best way to check   sendmail ?&lt;BR /&gt;&lt;BR /&gt;regards&lt;/PORT&gt;</description>
      <pubDate>Wed, 26 Mar 2008 13:33:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168250#M320892</guid>
      <dc:creator>Billa-User</dc:creator>
      <dc:date>2008-03-26T13:33:32Z</dc:date>
    </item>
    <item>
      <title>Re: sendmail check</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168251#M320893</link>
      <description>&lt;!--!*#--&gt;I assume you are using:&lt;BR /&gt;&lt;BR /&gt;/sbin/init.d/sendmail stop    -and-&lt;BR /&gt;/sbin/init.d/sendmail start   &lt;BR /&gt;&lt;BR /&gt;to stop/start sendmail.  If so, it shouldn't be an issue.&lt;BR /&gt;&lt;BR /&gt;You might also simply examine the return code from the start command with *?.  I believe it will return a non-zero if there are problems.&lt;BR /&gt;&lt;BR /&gt;Two other alternatives:&lt;BR /&gt;&lt;BR /&gt;UNIX95= ps -C sendmail -ocomm= | wc -l&lt;BR /&gt;&lt;BR /&gt;should be 1 if sendmail is running, &lt;BR /&gt;or you might look at the section of code in the start-up script that is used to check the status:&lt;BR /&gt;&lt;BR /&gt;   pidfile="/etc/mail/sendmail.pid"&lt;BR /&gt;   if [ -f $pidfile ]; then&lt;BR /&gt;     test "$pidfile" &amp;amp;&amp;amp; exec 0&amp;lt; $pidfile&lt;BR /&gt;     read -r PID&lt;BR /&gt;     sendserv=`ps -e | grep -E "^ [ ]*$PID .*sendmail" | wc -l`&lt;BR /&gt;      if [ $sendserv -ne 0 ]; then&lt;BR /&gt;           set_return&lt;BR /&gt;           echo "sendmail has already been started"&lt;BR /&gt;           exit $rval&lt;BR /&gt;      fi&lt;BR /&gt;    fi&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 26 Mar 2008 14:12:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168251#M320893</guid>
      <dc:creator>OldSchool</dc:creator>
      <dc:date>2008-03-26T14:12:53Z</dc:date>
    </item>
    <item>
      <title>Re: sendmail check</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168252#M320894</link>
      <description>&amp;gt; [...] and start sendmail.&lt;BR /&gt;&lt;BR /&gt;How?&lt;BR /&gt;&lt;BR /&gt;&amp;gt; how can i check, if sendmail runs ?&lt;BR /&gt;&lt;BR /&gt;Did anything go wrong when you started it?&lt;BR /&gt;&lt;BR /&gt;Trying to send and receive e-mail is a pretty&lt;BR /&gt;good test.&lt;BR /&gt;&lt;BR /&gt;You could look at that new log file, too.&lt;BR /&gt;&lt;BR /&gt;"ps" could show you if there's a program&lt;BR /&gt;named "sendmail" running.&lt;BR /&gt;&lt;BR /&gt;All those commands which mention "25" are&lt;BR /&gt;intended to tell you if anyone is listening&lt;BR /&gt;to the SMTP port (25).  Sendmail should do&lt;BR /&gt;that.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&amp;gt; what is the best way to check sendmail ?&lt;BR /&gt;&lt;BR /&gt;Best in what sense?  Easiest?  Most complete&lt;BR /&gt;and reliable?  Checking actual e-mail&lt;BR /&gt;capability is probably the most realistic&lt;BR /&gt;test.  Everything else is probably easier.</description>
      <pubDate>Wed, 26 Mar 2008 14:18:59 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168252#M320894</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2008-03-26T14:18:59Z</dc:date>
    </item>
    <item>
      <title>Re: sendmail check</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168253#M320895</link>
      <description>Laying one more beating on a dead horse, ...&lt;BR /&gt;&lt;BR /&gt;&amp;gt; UNIX95= ps -C sendmail -ocomm= | wc -l&lt;BR /&gt;&lt;BR /&gt;&amp;gt; "ps" could show you if there's a program&lt;BR /&gt;&amp;gt; named "sendmail" running.&lt;BR /&gt;&lt;BR /&gt;Note that this tells you if there's _a_&lt;BR /&gt;program named "sendmail" running.  It does&lt;BR /&gt;not tell you if _the_ "sendmail" program is&lt;BR /&gt;running.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Why do you care if sendmail is running?&lt;BR /&gt;&lt;BR /&gt;Why do you run sendmail?&lt;BR /&gt;&lt;BR /&gt;If you run sendmail to handle e-mail, then&lt;BR /&gt;the real question is, "Does e-mail work?",&lt;BR /&gt;and the best test for that is a real e-mail&lt;BR /&gt;test.  Anything else you test will give you&lt;BR /&gt;only an approximation of what you really wish&lt;BR /&gt;to know.&lt;BR /&gt;&lt;BR /&gt;Now, if, for some reason, you can't run a&lt;BR /&gt;real e-mail test, then you may need to fall&lt;BR /&gt;back to some less informative test, but it's&lt;BR /&gt;good to know why you're testing what you're&lt;BR /&gt;testing, and what your test really tells you&lt;BR /&gt;(and what it doesn't).</description>
      <pubDate>Wed, 26 Mar 2008 15:49:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168253#M320895</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2008-03-26T15:49:37Z</dc:date>
    </item>
    <item>
      <title>Re: sendmail check</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168254#M320896</link>
      <description>hello,&lt;BR /&gt;&lt;BR /&gt;i know the problematic of "sendmail" and that it isn't possible to check whether a mail arrives the receiver (i can only search mail.log?) we had some cases that sendmail hung. this it what we want to check. and when a process runs, you can't say the process work's?&lt;BR /&gt;so we want to make a check :&lt;BR /&gt;&lt;BR /&gt;- process exists&lt;BR /&gt;- process exists and works&lt;BR /&gt;&lt;BR /&gt;but we don't want to send a email.&lt;BR /&gt;&lt;BR /&gt;sendmail is our programm to send mail from unix to other destinations !&lt;BR /&gt;&lt;BR /&gt;regards</description>
      <pubDate>Thu, 27 Mar 2008 06:52:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168254#M320896</guid>
      <dc:creator>Billa-User</dc:creator>
      <dc:date>2008-03-27T06:52:51Z</dc:date>
    </item>
    <item>
      <title>Re: sendmail check</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168255#M320897</link>
      <description>&lt;!--!*#--&gt;&amp;gt; sendmail is our programm to send mail from&lt;BR /&gt;&amp;gt; unix to other destinations !&lt;BR /&gt;&lt;BR /&gt;You might try to arrange for a different&lt;BR /&gt;system to forward e-mail back to the system&lt;BR /&gt;being tested.  For example:&lt;BR /&gt;&lt;BR /&gt;On the test system, send an e-mail test&lt;BR /&gt;message to "mirror@reliable_system".&lt;BR /&gt;&lt;BR /&gt;Arrange for e-mail to "mirror" arriving at&lt;BR /&gt;reliable_system to be forwarded (back) to,&lt;BR /&gt;say, "tester@test_system".&lt;BR /&gt;&lt;BR /&gt;If the test message is not received by&lt;BR /&gt;"tester" on test_system, then there's a&lt;BR /&gt;problem somewhere.  If it is received, then&lt;BR /&gt;you can be pretty sure that sendmail is&lt;BR /&gt;working properly on test_system.&lt;BR /&gt;&lt;BR /&gt;It's been a long time since I've cared, but,&lt;BR /&gt;as I recall, you can rig an e-mail alias to&lt;BR /&gt;run a program when a message arrives for a&lt;BR /&gt;user (like "tester"), so you might not need&lt;BR /&gt;to log in manually as "tester" just to check&lt;BR /&gt;his e-mail.&lt;BR /&gt;&lt;BR /&gt;In fact, you could rig things so that if the&lt;BR /&gt;test message didn't return, an e-mail&lt;BR /&gt;message would get sent to the system manager.&lt;BR /&gt;Of course, this might not work either, so&lt;BR /&gt;you might need to be a bit more clever than&lt;BR /&gt;that.  ("Let me know if you don't receive&lt;BR /&gt;this message.")  But many things are&lt;BR /&gt;possible.</description>
      <pubDate>Thu, 27 Mar 2008 07:46:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168255#M320897</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2008-03-27T07:46:18Z</dc:date>
    </item>
    <item>
      <title>Re: sendmail check</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168256#M320898</link>
      <description>Shalom,&lt;BR /&gt;&lt;BR /&gt;Most corporate mail systems is DSrelayserver configuration in sendmail.cf to relay mail via smtp relay hosts.&lt;BR /&gt;&lt;BR /&gt;It is rare that a Unix system is permitted to simply resolve the domain name and deliver mail.&lt;BR /&gt;&lt;BR /&gt;Note that you need not run the sendmail daemon to merely send outbound mail. You need the sendmail daemon to receive mail on a system.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Thu, 27 Mar 2008 08:30:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/sendmail-check/m-p/4168256#M320898</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2008-03-27T08:30:18Z</dc:date>
    </item>
  </channel>
</rss>

