<?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: Shutdown script in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869728#M98129</link>
    <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Starting with 10.0 the startup/shutdown paradigm changed.  The document link below offers a pdf file which applies to HP-UX starting with 10.0 and continuing through current 11i releases.  It should easily answer all your questions.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://docs.hp.com/hpux/onlinedocs/os/startup.pdf" target="_blank"&gt;http://docs.hp.com/hpux/onlinedocs/os/startup.pdf&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
    <pubDate>Tue, 24 Dec 2002 16:31:17 GMT</pubDate>
    <dc:creator>James R. Ferguson</dc:creator>
    <dc:date>2002-12-24T16:31:17Z</dc:date>
    <item>
      <title>Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869721#M98122</link>
      <description>Hi,&lt;BR /&gt;I would like to know whether any place/script used when the system being shutdown gracefully.&lt;BR /&gt;E.g. I want add some additional commands in shutdown script. If I am correct in hp-ux 9.x /etc/shutdown was the place you put any script will executed when system being shutdown. in 11.x how to do the same thing. it may be possible by adding the lines to any of the K??? scripts in /sbin/rc0.d&lt;BR /&gt;Or may be I need to edit /sbin/rc&lt;BR /&gt;Is there any other easy way?&lt;BR /&gt;&lt;BR /&gt;Thanks in advance&lt;BR /&gt;&lt;BR /&gt;TT&lt;BR /&gt;</description>
      <pubDate>Tue, 24 Dec 2002 05:41:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869721#M98122</guid>
      <dc:creator>Thayanidhi</dc:creator>
      <dc:date>2002-12-24T05:41:26Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869722#M98123</link>
      <description>Hi,&lt;BR /&gt;It may be that I misunderstand your question, but the best way is to "balance" your stop/start scripts.&lt;BR /&gt;Example : Let's say you start Oracle somewhere at the beginning of runlevel 3 :&lt;BR /&gt;wroot/sv00239#ll /sbin/rc3.d&lt;BR /&gt;total 0&lt;BR /&gt;lrwxr-xr-x   1 root       sys             19 Sep 26  2001 S009oracle -&amp;gt; /sbin/init.d/oracle&lt;BR /&gt;&lt;BR /&gt;Then logic would dictate you stop Oracle at the end of runlevel 2 :&lt;BR /&gt;wroot/sv00239#ll /sbin/rc2.d&lt;BR /&gt;total 0&lt;BR /&gt;lrwxr-xr-x   1 root       sys             19 Sep 26  2001 K991oracle -&amp;gt; /sbin/init.d/oracle&lt;BR /&gt;&lt;BR /&gt;I try to "complement" the links (S009 versus K991). This avoids confusion ...&lt;BR /&gt;&lt;BR /&gt;Was this what you are looking for ?&lt;BR /&gt;Regards,&lt;BR /&gt;Tom</description>
      <pubDate>Tue, 24 Dec 2002 05:51:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869722#M98123</guid>
      <dc:creator>Tom Geudens</dc:creator>
      <dc:date>2002-12-24T05:51:12Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869723#M98124</link>
      <description>Not exactly,&lt;BR /&gt;&lt;BR /&gt;The system is triggering a shutdown due to shutdown command executed, or hardware failure such as over temp/chasis fan ..etc.&lt;BR /&gt;It is as simple as that, when system being shutdown, the system should send a e-mail.&lt;BR /&gt;I think in /etc/rc0.d editing any K??? script will do, but is there any other place?&lt;BR /&gt;&lt;BR /&gt;TT</description>
      <pubDate>Tue, 24 Dec 2002 06:01:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869723#M98124</guid>
      <dc:creator>Thayanidhi</dc:creator>
      <dc:date>2002-12-24T06:01:07Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869724#M98125</link>
      <description>There was a typo. It is "/sbin/rc0.d" not /etc/rc0.d&lt;BR /&gt;</description>
      <pubDate>Tue, 24 Dec 2002 06:06:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869724#M98125</guid>
      <dc:creator>Thayanidhi</dc:creator>
      <dc:date>2002-12-24T06:06:33Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869725#M98126</link>
      <description>Hi,&lt;BR /&gt;Sorry for not understanding the question in the first place. I'm afraid there is no easy way. You might be able to "catch" some cases with the envd-daemon (check "man envd" for more information). Using EMS will give you an indication of why the system went down.&lt;BR /&gt;&lt;BR /&gt;Note that the mailservices are probably no longer running when you get to /sbin/rc0.d in an ordinary shutdown !&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Tom</description>
      <pubDate>Tue, 24 Dec 2002 06:55:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869725#M98126</guid>
      <dc:creator>Tom Geudens</dc:creator>
      <dc:date>2002-12-24T06:55:27Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869726#M98127</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I think you are correct! &lt;BR /&gt;I could edit /etc/envd.conf to send mails in case of over temp or fan failure. But when some one gracefully shutting down the system, how to generate mail? Should I do it in run level 3 to 2 transition(/sbin/rc2.d/K???), because runlevel 1 will not be running networking/sendmail deamons. Correct me If I am wrong.&lt;BR /&gt;&lt;BR /&gt;TT</description>
      <pubDate>Tue, 24 Dec 2002 07:02:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869726#M98127</guid>
      <dc:creator>Thayanidhi</dc:creator>
      <dc:date>2002-12-24T07:02:24Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869727#M98128</link>
      <description>Hi,&lt;BR /&gt;No correction needed, if you want the mail, do it before the daemons (not to mention the network) are down. &lt;BR /&gt;An alternative might be to have your systems monitored (by HP Openview as an - very expensive - example).&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Tom</description>
      <pubDate>Tue, 24 Dec 2002 08:00:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869727#M98128</guid>
      <dc:creator>Tom Geudens</dc:creator>
      <dc:date>2002-12-24T08:00:18Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869728#M98129</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Starting with 10.0 the startup/shutdown paradigm changed.  The document link below offers a pdf file which applies to HP-UX starting with 10.0 and continuing through current 11i releases.  It should easily answer all your questions.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://docs.hp.com/hpux/onlinedocs/os/startup.pdf" target="_blank"&gt;http://docs.hp.com/hpux/onlinedocs/os/startup.pdf&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Tue, 24 Dec 2002 16:31:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869728#M98129</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2002-12-24T16:31:17Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869729#M98130</link>
      <description>The easiest way is to simply create a start/stop script in /sbin/init.d and call it startstopnotify. It would look at two variables, something like NOTIFYSTOP and NOTIFYSTART. Set these two variables in /etc/rc.config.d/startstopnotify (zero = no message, non-zero = do whatever you need as a notification).&lt;BR /&gt;&lt;BR /&gt;Now create 2 symlinks to /sbin/init.d script in /etc/rc2.d and call it K090startstopnotify and S992startstopnotify as an example. The script might just use mailx to send a mail or pager message.&lt;BR /&gt;&lt;BR /&gt;The concept behind the start/stop scripts is to break up independent features so they can be selectively enabled at bootup (and shutdown in a formal manner). The S992 link name ensures that the startstopnotify script is one of the last scripts run at startup. This is because you'll likely need networking and sendmail functional before you send the notification. Conversely, K099 means that the notification will go out before sendmail and networking are terminated. By keeping all the notification functions in this script, you won't have to worry about HP-UX standard scripts getting patched and losing custom code.&lt;BR /&gt;&lt;BR /&gt;See attached example.</description>
      <pubDate>Tue, 24 Dec 2002 21:39:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-script/m-p/2869729#M98130</guid>
      <dc:creator>Bill Hassell</dc:creator>
      <dc:date>2002-12-24T21:39:09Z</dc:date>
    </item>
  </channel>
</rss>

