Hitachi

For Linux(R) (x86) Systems HA Monitor Cluster Software


4.1.4 Controlling the server monitoring command

The server monitoring command is a command created by the user that is used to monitor servers in the monitor mode. This subsection explains the flow for starting and terminating the server monitoring command and for performing monitoring processing.

Organization of this subsection

(1) Starting and stopping the server monitoring command

The timing of starting the monitoring command, the timing of stopping the monitoring command, the execution privilege, and the behavior when startup fails differ depending on whether the monitoring command is specified for the ptrlcmd_ex or patrolcommand operand in the server environment definition. The following table shows the differences that arise according to the specification of the monitoring command.

Table 4‒5: Differences arising according to the specification of the monitoring command

Item

Operand for which the monitoring command is specified

The ptrlcmd_ex operand in the server environment definition

The patrolcommand operand in the server environment definition

Timing of starting the monitoring command

After the active server has been started successfully, HA Monitor executes the monitoring command at regular intervals (the interval is specified for the ptrlcmd_ex_inter operand in the server environment definition).

When the active server is started successfully, HA Monitor starts the monitoring command.

Timing of stopping the monitoring command

The monitoring command is stopped at the following times:

  • Each time the server monitoring command is executed, it returns the result (EXIT code) and terminates.

  • If the monitoring command does not terminate within the time (number of seconds) specified for the ptrlcmd_ex_tmout operand in the server environment definition, HA Monitor stops the monitoring command.

  • When the active server is terminated or switched by planned hot-standby switchover, HA Monitor stops the monitoring command.

The monitoring command is stopped at the following times:

  • The server monitoring command detects a server failure and stops.

  • When the active server is terminated or switched by planned hot-standby switchover, HA Monitor stops the monitoring command.

Monitoring command execution privilege

Superuser

Superuser

Behavior when startup of the monitoring command fails

The system behaves according to the termination result (EXIT code) of 1 to 9.

Note that in the following case, although the subsequent monitoring processing is not performed, server processing normally continues.

  • After the active server is started successfully, the monitoring command is not found when the command is executed for the first time, or the monitoring command cannot be executed because the privilege to execute it is not given.

Although the monitoring processing is not performed, server processing continues normally.

(2) Processing flow

The following figure shows the processing flow for using the server monitoring command to monitor a server in the monitor mode.

Figure 4‒4: Processing flow for monitoring a server in the monitor mode (in the case where the monitoring command is specified for the ptrlcmd_ex operand in the server environment definition)

[Figure]

Figure 4‒5: Processing flow for monitoring a server in the monitor mode (in the case where the monitoring command is specified for the patrolcommand operand in the server environment definition)

[Figure]