1834150 Members
2448 Online
110064 Solutions
New Discussion

Oracle restart

 
SOLVED
Go to solution
James M. Dunn
Frequent Advisor

Oracle restart

All,

I searched the Forum for this question, to no avail nothing.

Anyhow.. I have an oracle database running in a two node cluster, this database is configured to be monitored by MCSG.

My question is....

When I kill one of the proccess the database is shutdown and restarted on the second node. Cool yes it restarts on the second node.

Id like to configure MCSG to "try" restarting the database on the primary node before first then if it cant start i want to to give up and try to start it on the secondary node.

Do the these lines in the control.sh file tell MCSG to restart the database 3 times when the package is started for the first time or does it tell MCSG to restart the package on the node it is residing on and if the "restart fails after 3 tries then try to start it on the second node? If not is there a way to accomplish the latter?

SERVICE_NAME[0]=orapkg
SERVICE_CMD[0]="/etc/cmcluster/orapkg/ora.sh monitor"
SERVICE_RESTART[0]="-r 3"

Thanks,

Jim D



5 REPLIES 5
Sanjay_6
Honored Contributor

Re: Oracle restart

Hi Jim,

This is supposed to be a service that MCSG is to monitor. If the service fails , it would try to start the service 3 times and if it unable to do that, it would fail the package to the alternate node.

You need to look at the script /etc/cmcluster/orapkg/ora.sh to understand what it is going to do if passed a "monitor" option in the command line.

You can try and see if you configure the package to be put the monitoring in maintainance mode, so that it will not fail the package in case you kill a process manually so you can do your maintainance.

Hope this helps.

regds
James M. Dunn
Frequent Advisor

Re: Oracle restart

here it is


JD
Frank de Vries
Respected Contributor
Solution

Re: Oracle restart

It is a vanilla std package script.
You run it with the monitor option
So,
The main line is
nohup ${0} fault & # The script calls itself with the fault option.
(This means halt package)

If any of the processes monitored fail
it will try to halt the package.

that is the situation at the moment.
If you want the script to first attempt
a restart action it will need to be programmed as such.

Then you need to fine tune the script
and test it so it does exactly what you want.

Look before you leap
James M. Dunn
Frequent Advisor

Re: Oracle restart

Frank,

Funny; when I looked at the script with the DBA yesterday this line jumped out. --->

nohup ${0} fault &

Thanks for pointing me in the correct direction!

By the way I own 2 VOLKSWAGENS!

Thanks again,

Jim D



James M. Dunn
Frequent Advisor

Re: Oracle restart

closed

thanks