- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Make sure that two packages cant start on the ...
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
Discussions
Discussions
Forums
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
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
тАО09-04-2008 12:56 AM
тАО09-04-2008 12:56 AM
Re: Make sure that two packages cant start on the same machine
>You have a 'customer_defined_run_cmds' - >you could grep a 'ps -ef' at the beginning >to check if the other package is already >running.
Well as I wrote in the question I do it there but thats the problem
>>as it is now I do the checks in >customer_defined_run_cmds and make it fail >from there
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-04-2008 01:15 AM
тАО09-04-2008 01:15 AM
Re: Make sure that two packages cant start on the same machine
Its more like confusing on your part. Kindly put your question and requirement in the form of some example A B C.
This will reduce the time for your query resolution.
Can you provide the package control script's problematic section here for make it faster.
Also provide...
cmviewcl -vp package1_name
cmviewcl -vp package2_name
outputs...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-04-2008 01:41 AM
тАО09-04-2008 01:41 AM
Re: Make sure that two packages cant start on the same machine
I have two packages that are not allowed to run on the same machine.
Lets say we start like this
pkg1 runs on server1
pkg2 runs on server2
nothing runs on server3
server1 fails and pkg1 has server2 next in the node list and server3 last ,
so it now fails over to server2.
But I check for pkg2 in the customer_defined_run_cmds
and if it is there fail the package. BUT heres the thing I would like it to now fail over to server3
but it will not for reasons I said before.
What I would like is some way of telling the package in its configuration that it cant run pkg1 and pkg2 on the same machine, something like
DEPENDENCY_CONDITION = down
But as it is now serviceguard only supports
DEPENDENCY_CONDITION = up
function customer_defined_run_cmds
{
result=/opt/wallwrapper/checkforotherpkg.sh
if [ $result -eq 1 ]
then
false
else
/opt/wallwrapper/wallwrapper start
fi
test_return 51
}
PACKAGE STATUS STATE AUTO_RUN NODE
wallwrapper1 up running enabled osll002ps
Policy_Parameters:
POLICY_NAME CONFIGURED_VALUE
Failover configured_node
Failback manual
Script_Parameters:
ITEM STATUS MAX_RESTARTS RESTARTS NAME
Service up 0 0 Probe_wallwrapper1
Subnet up 10.72.100.0
Node_Switching_Parameters:
NODE_TYPE STATUS SWITCHING NAME
Primary up enabled osll002ps (current)
Alternate up enabled osll003ps
Alternate up enabled osll001ps
PACKAGE STATUS STATE AUTO_RUN NODE
wallwrapper2 up running enabled osll001ps
Policy_Parameters:
POLICY_NAME CONFIGURED_VALUE
Failover configured_node
Failback manual
Script_Parameters:
ITEM STATUS MAX_RESTARTS RESTARTS NAME
Service up 0 0 Probe_wallwrapper2
Subnet up 10.72.100.0
Node_Switching_Parameters:
NODE_TYPE STATUS SWITCHING NAME
Primary up enabled osll001ps (current)
Alternate up enabled osll003ps
Alternate up enabled osll002ps
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-04-2008 11:53 PM
тАО09-04-2008 11:53 PM
Re: Make sure that two packages cant start on the same machine
Thanks for trying to put everything in details!!
What I understand from the details is your requirement!! is following:
1. You dont want to avoid any chance of starting these two packages on same node at any point of time.
2. You want to avoid use customer_defined_cmd function to set it up!!
correct me if I am wrong!!
One thing you can do here is to change failover order of package under configured nodes in package configuration file.
Like for pkg1 you can set (node 1, node 3 and node 2)
same way for pkg2 you can set (node 2, node 3 and node 1)
provided that node is standby for running these two package in case something goes wrong with any of packages.
But this will be good when one node goes down for some reason. But if you take both nodes down for say maintenance then it will not work as per your requirement.
You can put a monitoring script here but again configured nodes will be used to failover.
Another way is to disable global switching for packages so you manually start when something goes wrong.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-05-2008 12:01 AM
тАО09-05-2008 12:01 AM
Re: Make sure that two packages cant start on the same machine
{
result=/opt/wallwrapper/checkforotherpkg.sh
if [ $result -eq 1 ]
then
true
else
/opt/wallwrapper/wallwrapper start
fi
test_return 51
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-09-2008 11:08 AM
тАО09-09-2008 11:08 AM
Re: Make sure that two packages cant start on the same machine
Then don't set them up to fail to the same boxes ! You have 5 boxes - give them their primary server and at least one fail over. Maybe the more essential pkg could have two failovers. That's simple enough - and that is plenty of coverage.
Face it....if your boxes are set up well - just how often do they actually failover. I have an 8 node cluster and haven't had so much as one failover in years.
For pkgs where I want pkgA to have priority over pkgB if they are on the same box, I just put this at the top of pkgA.cntl script:
/usr/sbin/cmhaltpkg -n $(/usr/bin/uname -n) pkgB
That says...stop pkgB first thing, then it will continue with the cntl script and kick off pkgA.
Just a thought,
Rta
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-10-2008 03:52 AM
тАО09-10-2008 03:52 AM
Re: Make sure that two packages cant start on the same machine
You better create a package monitoring script and enco-operate this check into that.
As Rita said....you need to stop another package that you dont want to run and then start the required one.
monitoring script can check the package status and take decision as per your requirement.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-10-2008 03:59 AM
тАО09-10-2008 03:59 AM
Re: Make sure that two packages cant start on the same machine
I start the program from the SERVICE_SCRIPT monitor script instead of from the customer_defined_run_cmds.
- « Previous
-
- 1
- 2
- Next »