1832120 Members
3196 Online
110038 Solutions
New Discussion

Cluster shutdown

 
podichin
Advisor

Cluster shutdown

Hi All,
In out enviorment we are using mc service gurad., and we are shutting down th cluster and rebooting all the servers once in a month,

My problem now is in a single cluster itself 12 to 15 Packages runiing, and we have only limited downtime ..,

My all cluster control scripts are able to shutdown the databases. Unmount filesystem ..,

Now my requirement is.., Anybody can help me to create a script that can shutdown all the packages and shutdown the cluster..,

I need to have a log file also to check whether every thing went well or not..,

So that i can run this script on multiple clusters at a time..,and hope can finish the activities within the scheduled time..,

Waiting for experts replay..,
Thanks and regards,

Siju
8 REPLIES 8
Nemer_1
Regular Advisor

Re: Cluster shutdown

Hi,

simply use:

cmhaltcl -f > logfile

in your script

Regards,
Luk Vandenbussche
Honored Contributor

Re: Cluster shutdown

You can also put this in your script

cmhaltpkg pkg1
...
cmhaltpkg pkg2
cmhaltnode node1
cmhaltnode node2


But the easiest way is

cmhaltcl -f
Steven E. Protter
Exalted Contributor

Re: Cluster shutdown

I would just halt the cluster

cmhaltcl > log

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
melvyn burnard
Honored Contributor

Re: Cluster shutdown

Why use a script?
Just use cmhaltcl -vf
Check the syslog.log for correct shutdown, or even verify each package log file. (tedious as you woukd need to know which package was running on which node)

Failing that, why not use Serviceguard Manager
to manage and halt all of the clusters.
My house is the bank's, my money the wife's, But my opinions belong to me, not HP!
Geoff Wild
Honored Contributor

Re: Cluster shutdown

cmhaltcl -f is the easiest way...

or

for i in `cmviewcl -l package |grep up |awk '{print $1}'`
do
chmhaltpkg $i
done

or, if they need to be shutdown in a certain order, harcode the cmhaltpkg as lines in a script...

Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
baiju_3
Esteemed Contributor

Re: Cluster shutdown

Hi Siju ,

cmhaltcl -f
will run successfully if all the packages are shutdown ,if the any package halt failes due to the failure in customer defined run commands it will not work.

have you enabled the debug flag check in your control file ? if yes the best fasteset way is , let the DBAs shutdown their application manually and you touch the debug flag and shutdown all the pcakges .



thx,
bl.











Good things Just Got better (Plz,not stolen from advertisement -:) )
podichin
Advisor

Re: Cluster shutdown

Hi All,

Thanks for immediate responses..,

I was also thougt to use cmhaltcl -vf command first.,

But after some times some doubts comes to mind.,

If i am giving cmhaltcl -vf commnad, I hope it will start shutting down all the 12 to 15 packages at a time.., And i doubt it could freez my systems..,

Any body can say me, How cmhaltcl -vf commands workings., Is it shutting down all the packages at a time..,

If a need to shutdown only 4 packages at a time., Is it possible.,

Thansks in advance,

Siju
Patrick Wallek
Honored Contributor

Re: Cluster shutdown

If you only need to shut down 4 packages, use the cmhaltpkg command.

# cmhaltpkg -v pkg1
# cmhaltpkg -v pkg2
# cmhaltpkg -v pkg3
# cmhaltpkg -v pkg4