Operating System - HP-UX
1839964 Members
4431 Online
110157 Solutions
New Discussion

shut down script when ups is down

 
vali anghel
Occasional Contributor

shut down script when ups is down

i need a script for HP-UX11i to run and shut down the db and oracle aplication cleanely when the ups is down.
Can somebody help me ??

Thank you !!
3 REPLIES 3
Indira Aramandla
Honored Contributor

Re: shut down script when ups is down

Hi Vali,

You can configure your system to automatically start Oracle databases when your system starts up and to shut down Oracle databases when your system shuts down.

The dbshut and dbstart scripts are located in the $ORACLE_HOME/bin directory and can be used to automate database startup and shutdown. On bootup, the /etc/init.d/dbora script is executed by a link in the rc2.d directory. The dbora script checks to make sure the dbstart script file exists and, if it does, switches to the ORA_OWNER, and executes dbstart.

The dbstart and dbshut scripts reference the same entries in the oratab file, so the scripts must apply to the same set of databases.

For example, you cannot have dbstart automatically start up databases sid1, sid2, and sid3, and dbshut shut down only databases sid1 and sid2. You can, however, specify that dbshut shut down a set of databases while dbstart is not used at all. To do this, include the dbshut entry in the shutdown file but omit the dbstart entry from the system startup files.

You can modify the $ORACLE_HOME/bin/dbstart and dbshut to also stop and start the listener. Likewise you can add the lined to bring the start and stop the application.

Attached document provides the steps.


Indira A
Never give up, Keep Trying
Yogeeraj_1
Honored Contributor

Re: shut down script when ups is down

hi,

also refer to metalink note: 1019790.6 AUTOMATIC STARTUP/SHUTDOWN OF ORACLE INSTANCES ON HP-UX UNIX

regards
Yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
vali anghel
Occasional Contributor

Re: shut down script when ups is down

I have Oracle 11i version. The script you gived me is for 9i right ? can i use it for 11i ??

Thank you !