- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Silly Question on MCSG
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2003 06:20 AM
01-11-2003 06:20 AM
Silly Question on MCSG
I wanted to know if this scenario can be worked out in MCSG.
Two machines AA and BB are running in Active/Active mode. There are 3 packages A, B and C - are configured in such a way.
A runs in AA. (it won't failover to BB)
B runs in BB. (it won't failover to AA)
C runs in AA and can failover to BB.
Is it pssoble to configure the MCSG package such that when A fails, a script is run in BB and when B fails a script is run in AA ?
Thanks an Regards
Vishal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2003 06:53 AM
01-11-2003 06:53 AM
Re: Silly Question on MCSG
You can use EMS to monitor packages and do action based on it's state.
I am not a big fan of EMS+MCSG. I would do the following.
1. Create|Modify the monitoring script for A and B.
2. Script for A monitors the state of B and takes the action.
3. Script for B monitors the state of A and takes the action.
A simple script will be like this (Package monitoring script for A)
stamp=0
while [ true ]
Status=(cmviewcl -p pkgB|awk '/pkgB/ {print $2}'
case $Status in
'up') stamp=0
;;
'down')
if [ "$stamp" != 1 ]
then
run_your_script
fi
;;
esac
(write code to monitor your processes here. Exit if the processes won't run)
done
Create a service called "pkgA" in your package config file and keep the above script in the control file. Search for SERVICE word in both the files for more explanation.
Repeat the same for pkgB
Only problem is that it needs the other package to be running for this to work.
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2003 06:58 AM
01-11-2003 06:58 AM
Re: Silly Question on MCSG
if [ "$stamp" != 1 ]
then
run_your_script
stamp=1
fi
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2003 07:06 AM
01-11-2003 07:06 AM
Re: Silly Question on MCSG
1) Run the same script above with "nohup" option outside the serviceguard on systemA. Since this has to continuously run, make it to test for a lock file and exit if it finds it. For ex.,
while true
do
if [ -f /etc/cmcluster/pkgB.lock ]
then
exit
else
Status=(cmviewcl.....
case
..
esac
done
2. If you are using .rhosts, then put a line like this in the shutdown part of pkgB.
remsh pkgA path_to_your_script
So when pkgB comes down, it will run the script and then halt.
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-13-2003 05:00 AM
01-13-2003 05:00 AM
Re: Silly Question on MCSG
For this I have to install EMS right ?
Let me admit that I have no idea about these sysadmin tolls/utilities. The machine I have has MCSG and HP GlancePlus/UX Pak.
Do you think it is still possible ?
Thanks and Regards
Vishal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-23-2003 04:21 AM
01-23-2003 04:21 AM
Re: Silly Question on MCSG
1. I suppose you can use in pkgB's service monitoring script something like:
remsh AA "echo ... pkgB down here!!!"
This way when pkgB get down, system AA will
be informed.
2. You can run on AA script, included
"cmviewcl"-command catch the output "halted"
for pkgB using sed&awk. I thing, it is
simple, but will work. :)
Regards, Stan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-23-2003 07:02 AM
01-23-2003 07:02 AM
Re: Silly Question on MCSG
They run a simple script that greps cmviewcl and greps for uname -a and then writes out the hostname to a file. They have another simple script that says if the hostname is equal to the failover box (BB) then haltpkgs on (BB). In the custom startup scripts they check the results in the file...if it's on server A they run pkg(s) for server A.
Now if pkg fails over and hits the other box...when it checks for that status.hostname file it finds the other servers hostname and then the script takes the other option on the statement and runs that little shutdown script and shuts down pkg(s) for B and then continues on and starts up the pkg(s) for A again.
At this point getting everything back to it's own box, would be a manual stop/start of pkgs - and of course ensure that the status file is cleared and not left over on the other failover server.
Like I said it's really just a couple small shell scripts that are referenced in the custom startup/shutdown scripts in each package.
Rgrds,
Rita