<?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 from UPS in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168590#M160909</link>
    <description>Kevin,&lt;BR /&gt;&lt;BR /&gt;Exactly.  I should have mentioned it.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
    <pubDate>Tue, 20 Jan 2004 11:05:17 GMT</pubDate>
    <dc:creator>Pete Randall</dc:creator>
    <dc:date>2004-01-20T11:05:17Z</dc:date>
    <item>
      <title>Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168582#M160901</link>
      <description>Does anyone know of a way to run a script when HPUX shuts down after a power failure, i.e. when power fails and the ups-conf kicks in, can i tell it to run a script to shutdown my databases cleanly!</description>
      <pubDate>Tue, 20 Jan 2004 09:52:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168582#M160901</guid>
      <dc:creator>Kevin Daines</dc:creator>
      <dc:date>2004-01-20T09:52:44Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168583#M160902</link>
      <description>This is simply a matter of correct rc configuration.&lt;BR /&gt;&lt;BR /&gt;Database start/stop script is in /sbin/init.d/&lt;BR /&gt;&lt;BR /&gt;directory, I'm attching my oracle script as a template&lt;BR /&gt;&lt;BR /&gt;then a soft link in /sbin/rc3.d K200oracle that points to the /sbin/init.d/oracle script&lt;BR /&gt;&lt;BR /&gt;When ups_mond shuts down the machine, the database will come down normally.&lt;BR /&gt;&lt;BR /&gt;If its oracle, make sure you use shutdown immediate.&lt;BR /&gt;&lt;BR /&gt;LEt me know if you need more details&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Tue, 20 Jan 2004 09:55:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168583#M160902</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2004-01-20T09:55:36Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168584#M160903</link>
      <description>Kevin,&lt;BR /&gt;&lt;BR /&gt;The database should be handled by the normal shutdown processes (i.e. /sbin/init.d/database and the /sbin/rc(runlevel).d links).&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Tue, 20 Jan 2004 09:56:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168584#M160903</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2004-01-20T09:56:16Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168585#M160904</link>
      <description>I have made it a practical exercize to modify /etc/shutdown.&lt;BR /&gt;&lt;BR /&gt;I added "su - oracle -c $ORACLE_HOME/bin/dbshut"&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 20 Jan 2004 10:20:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168585#M160904</guid>
      <dc:creator>Tim Sanko</dc:creator>
      <dc:date>2004-01-20T10:20:44Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168586#M160905</link>
      <description>I'd recommend against using dbshut.&lt;BR /&gt;&lt;BR /&gt;It hangs.&lt;BR /&gt;&lt;BR /&gt;I've written a better one.&lt;BR /&gt;&lt;BR /&gt;Attaching&lt;BR /&gt;&lt;BR /&gt;as tar file</description>
      <pubDate>Tue, 20 Jan 2004 10:25:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168586#M160905</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2004-01-20T10:25:39Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168587#M160906</link>
      <description>Steve,&lt;BR /&gt;&lt;BR /&gt;Would i get away with a link in rc3.d, that links to a file in init.d called dbasestart:&lt;BR /&gt;&lt;BR /&gt;case "$1" in&lt;BR /&gt;&lt;BR /&gt;start)&lt;BR /&gt;  /qad/scripts/start.All&lt;BR /&gt;  ;;&lt;BR /&gt;&lt;BR /&gt;stop)&lt;BR /&gt;  /qad/scripts/stop.All&lt;BR /&gt;   ;;&lt;BR /&gt;&lt;BR /&gt;esac&lt;BR /&gt;&lt;BR /&gt;Would this use the start script on entering run level 3 and the stop script on exiting run level 3?</description>
      <pubDate>Tue, 20 Jan 2004 10:26:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168587#M160906</guid>
      <dc:creator>Kevin Daines</dc:creator>
      <dc:date>2004-01-20T10:26:46Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168588#M160907</link>
      <description>Kevin,&lt;BR /&gt;&lt;BR /&gt;The start script would be invoked when entering run level 3, but the stop script should be the first thing done when entering run level 2, like this: &lt;BR /&gt;&lt;BR /&gt;ll /sbin/rc?.d/*informix&lt;BR /&gt;lrwxrwxrwx   1 root       sys             21 Jun  2  2000 /sbin/rc2.d/K100inform&lt;BR /&gt;ix -&amp;gt; /sbin/init.d/informix&lt;BR /&gt;lrwxrwxrwx   1 root       sys             21 Jun  2  2000 /sbin/rc3.d/S998inform&lt;BR /&gt;ix -&amp;gt; /sbin/init.d/informix&lt;BR /&gt;&lt;BR /&gt;Obviously you would not be using informix!!&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Tue, 20 Jan 2004 10:31:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168588#M160907</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2004-01-20T10:31:08Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168589#M160908</link>
      <description>Pete,&lt;BR /&gt;&lt;BR /&gt;Just to confirm, the 'S???' and the 'K???' at the beginning of the link in the relevent rc?.d directory is the method by which the run level being invoked 'knows' to run the  Start(S???) or Stop(K???) part of the script in init.d&lt;BR /&gt;&lt;BR /&gt;I hope that makes sense!</description>
      <pubDate>Tue, 20 Jan 2004 10:57:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168589#M160908</guid>
      <dc:creator>Kevin Daines</dc:creator>
      <dc:date>2004-01-20T10:57:35Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168590#M160909</link>
      <description>Kevin,&lt;BR /&gt;&lt;BR /&gt;Exactly.  I should have mentioned it.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Tue, 20 Jan 2004 11:05:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168590#M160909</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2004-01-20T11:05:17Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168591#M160910</link>
      <description>And the number which follows the S and K need to be unique? As in I assign a unique number to each in the range 1 to 999?</description>
      <pubDate>Tue, 20 Jan 2004 11:09:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168591#M160910</guid>
      <dc:creator>Kevin Daines</dc:creator>
      <dc:date>2004-01-20T11:09:33Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168592#M160911</link>
      <description>Kevin,&lt;BR /&gt;&lt;BR /&gt;The number determines the order with the Start or Kill scripts.  I like to do the database last so I use the S998 and the K100, so that it's started late on entering run-level 3 and early on entering run-level2.  They actually don't have to be unique but if they're not, it's a crap shoot what order the non-unique scripts get executed.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete</description>
      <pubDate>Tue, 20 Jan 2004 11:34:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168592#M160911</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2004-01-20T11:34:03Z</dc:date>
    </item>
    <item>
      <title>Re: Shutdown from UPS</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168593#M160912</link>
      <description>It's not really a crapshoot as to which scripts get run even if you have duplicate K100xxx scripts. The scripts are evaluated in lexical order so that K100aaa will run before K100aab. Having said that why make it hard on yourself.&lt;BR /&gt;&lt;BR /&gt;A good convention (and it is nothing more than that) is to have your Snnn and KNNN values sum to 1000. For example if you have an S900 startup script, you should have a K100 kill script. The other convention is that if a process/service is started at run level N, it should be killed at run level N-1 and both of these should be a softlink to the "real" script in init.d.</description>
      <pubDate>Tue, 20 Jan 2004 11:42:59 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shutdown-from-ups/m-p/3168593#M160912</guid>
      <dc:creator>A. Clay Stephenson</dc:creator>
      <dc:date>2004-01-20T11:42:59Z</dc:date>
    </item>
  </channel>
</rss>

