1751834 Members
5517 Online
108782 Solutions
New Discussion

SG question

 
SOLVED
Go to solution
meekrob
Super Advisor

SG question

Hello,

 

im new to serviceguard and I have 1 question in mind and i thought that you can help:

supposing that i need to configure a SG Failover  package using LVM (on a 2-nodes cluster with cluster lock LUN).

Is there a way to setup this package as dependent of 2 shared VGs with 5 or 6 lvols each (let's say vg02 and vg03) same as we proceeded for the vg01 which constitutes the cluster Lock LUN? (create the vg 1st on the 1st node then vgexport/vgimport and configure it within the package config and control file?)

In this case it is just a standard package ensuring availability of shared filesystems, so, how to also configure SG to monitor this package? What would be the SERVICE_CMD parameter value within the package's control script in that case?

 

Thanks in advance

2 REPLIES 2
Matti_Kurkela
Honored Contributor
Solution

Re: SG question

> (create the vg 1st on the 1st node then vgexport/vgimport and configure it within the package config and control file?)

 

Yes, exactly like this. Also remember to switch the VG to cluster mode (vgchange -c y) after it's vgimported to the other node but before adding it to the package configuration.

 


In general, a single Serviceguard package may contain any combination of:

  • zero or more package IP addresses
  • zero or more package VGs
  • zero or more filesystems

Of course, trying to add a filesystem to package configuration without having a package VG may be a silly configuration... but perhaps there is some special case where it is actually useful.

 

The SERVICE_CMD can refer to a script you write yourself.

 

In general, a SERVICE_CMD script for monitoring purposes only has a few requirements:

  • When everything is OK, the script should run in an infinite loop, doing any necessary tests and then sleeping for a while. Running the tests repeatedly without no pause between them would usually use excessive amounts of CPU power compared to the minor benefit of slightly faster fault detection.
  • If something is wrong, the script only needs to exit. Serviceguard will detect when a SERVICE_CMD script/command exits and treats it as an indication that something is wrong.
  • The SERVICE_CMD script will be killed by Serviceguard if the administrator uses cmhaltpkg or a package failover is triggered for some other reason, so killing the script at any point of its execution must not jeopardize the ability to restart it (e.g. if the script uses temporary files and they already exist because a previous instance of the script was killed in mid-operation, the script needs to be able to deal with it automatically in some appropriate way)

 

You can certainly monitor filesystems with SERVICE_CMD scripts if necessary; however, the EMS HA Monitors product includes more convenient functions for that. It is a separate HP product that ties in nicely with Serviceguard. If you use EMS HA Monitors, you can add the targets to be monitored as "resources" in your package. This document should explain the use of HA monitors with Serviceguard in more detail.

MK
meekrob
Super Advisor

Re: SG question

Crystal Clear :) and it is the best answer that i would have

 

Many Thanks for your efforts

Regards