PRIMECLUSTER Global Link Services Configuration and Administration Guide: Redundant Line Control Function 4.1 (for Solaris(TM) Operating System)
Contents Index PreviousNext

Chapter 3 Environment configuration> 3.6 Setting Option Function> 3.6.11 Setting User command execution function

3.6.11.2 Settings for GS/SURE linkage mode

The following shows the script file call format and the definition file sample for the operation in GS/SURE linkage mode.

[Script file call format]

/bin/sh hostIP

[Definition file sample]

#
#       All Rights Reserved, Copyright (c) FUJITSU LIMITED 2001
#
#ident  "%W% %G% %U% - FUJITSU"
#

#
#  Control interface for HA-Net
#

#
# Set Params
#

#PROC="process_name"

#
# Procedure
#

#
#kill -15 `/usr/bin/ps -e | /usr/bin/sed -n \
#       -e'/'$PROC'$/s/[^0-9 \t].*//p' \
#       ` > /dev/null 2>/dev/null
#

[Setting example]

The following shows an example of sending a signal (SIGHUP) to the DUMY process. Note that three-digit numbers placed on the left end of this example need not be placed in the actual script file because they just indicate line numbers for the purpose of explanation.

001 #
002 #       All Rights Reserved, Copyright (c) FUJITSU LIMITED 2001
003 #
004 #ident  "%W% %G% %U% - FUJITSU"
005 #
006
007 #
008 #  Control interface for HA-Net
009 #
010
011 #
012 # Set Params
013 #
014
015 PROC="DUMY"
016
017 #
018 # Procedure
019 #
020
020 #
030 kill -1 `/usr/bin/ps -e | /usr/bin/sed -n \
       -e'/'$PROC'$/s/[^0-9 \t].*//p' \
       ` > /dev/null 2>/dev/null

The following explains this setting example. In the explanation, [xxx] represents a line number in this setting example.

[015]: Specifies a process name to be stopped.

[030]: Acquires the process ID of a concerned process from the process list and send SIGTERM for the process.


Contents Index PreviousNext

All Rights Reserved, Copyright (C) FUJITSU LIMITED 2005