PRIMECLUSTER Global Link Services Configuration and Administration Guide: Redundant Line Control Function 4.2 (for Linux)
Contents Index PreviousNext

Chapter 7 Command references

7.7 hanetpoll Command

[Name]

hanetpoll - Setting, modifying, deleting, and displaying the monitoring destination information for the HUB monitoring function

[Synopsis]

/opt/FJSVhanet/usr/sbin/hanetpoll command [args]

[Feature description]

The hanetpoll command sets the monitoring destination information required for the HUB monitoring function. This command also modifies, deletes, displays, enables, or disables the settings.

command

Process outline

Authority

create

Creates monitoring destination information

Super user

copy

Copies monitoring destination information

Super user

print

Displays monitoring destination information

General user

modify

Modifies monitoring destination information

Super user

delete

Deletes monitoring destination information

Super user

on

Enabling the HUB monitoring function

Super user

off

Disabling the HUB monitoring function

Super user

(1) create command

The operation of the HUB monitoring function requires the definition of monitoring destination information. Use the create command to define monitoring destination information.

/opt/FJSVhanet/usr/sbin/hanetpoll create -n devicename -p polladdress1[,polladdress2] [-b {on | off}]

-n devicename:

Specify the name of a virtual interface to be monitored. Specify a virtual interface created using the hanetconfig create command or the hanetconfig copy command. No logical virtual interface name can be specified.

-p polladdress1[,polladdress2]:

Specify a monitor-to host name or IP address. Specify a monitor-to host name or IP address to "polladdress1" when activating a Primary interface. Specify a monitor-to host name or IP address to "polladdress2" when activating a Secondary interface. When Primary and Secondary interfaces monitor the same thing, or when a Secondary interface is not defined (a single case), omit "polladdress2". In NIC switching mode, specify a host name or an IP address of the connected HUB. It is also possible to set IPv4 or IPv6 addresses as an address form. When setting an IPv6 address, do not specify a prefix value. When specifying a host name, do not use the same name that exists in IPv4 and IPv6. If the same name exists, it is dealt with as an IPv6 host.

-b on | off:

If two HUBs are specified as monitoring destinations in NIC switching mode, communication between the primary and secondary HUBs can be monitored.

on: Monitors communication between two HUBs.
off: Does not monitor communication between two HUBs.

(2) copy command

Use the copy command to create copy monitoring destination information on a virtual interface in NIC switching mode. This command thus allows monitoring destination information to be automatically created by using the copy source information and without requiring you to specify monitoring destination information and HUB-to-HUB monitoring mode. This command realizes simpler operation than directly executing the hanetpoll create command. The following is the command format for the copy command:

/opt/FJSVhanet/usr/sbin/hanetpoll copy -n devicename1,devicename2

When the tagged VLAN interface is used, the "copy" command is used to set a synchronous switching in the virtual interface.

-n devicename1,devicename2:

Specify the names of virtual interfaces from and to which monitoring destination information should be copied.

devicename1:

Specify the name of a virtual interface that is set in monitoring information in the copy source.

devicename2:

Specify the name of a new virtual interface to be monitored. Specify a virtual interface created using the hanetconfig create command or the hanetconfig copy command. No logical virtual interface name can be specified.

(3) print command

Use the print command to display the current monitoring destination information. Use this command to view the current monitoring destination information. The following is the format of the print command.

/opt/FJSVhanet/usr/sbin/hanetpoll print [-n devicename1[,devicename2,...]]

-n devicename1[,devicename2,...]:

Specify the names of virtual interfaces whose monitoring destination information should be displayed. If this option is not specified, the print command displays all the monitoring destination information currently specified.

The following shows an example of displaying information without any option specified.

Display

Contents

Polling Status

The current status of the monitoring function.

Polling Status

ON

The monitoring function is enabled.

OFF

The monitoring function is disabled.

interval(idle)

interval

The monitoring interval in the stationary status.

idle

In seconds the wait time that elapses after monitoring starts and before the HUB links up.

times

The monitoring count.

repair_time

The recovery monitoring interval in seconds.

FAILOVER Status

With or without cluster switching when an error occurred in all transfer routes.

FAILOVER Status

YES

Node switching is performed when the virtual interface is registered in the cluster resource.

NO

No node switching is performed.

Name

The name of a virtual interface to be monitored.

HUB Poll

The HUB-to-HUB monitoring status.

HUB Poll

ON

The monitoring function is enabled.

OFF

The monitoring function is disabled.

---

The monitoring function is not used.

Hostname

The host name or IP address to be monitored, in the order of the primary and secondary monitoring destinations. In the example, "hostA" is the primary monitoring destination and "192.168.10.10" is the secondary monitoring destination.

(4) modify command

Use the modify command to modify the monitoring destination information.

/opt/FJSVhanet/usr/sbin/hanetpoll modify -n devicename {[-p polladdress1[,polladdress2]] [-b {on | off}]}

-n devicename:

Specify the name of a virtual interface whose monitoring destination information should be modified. Specify a virtual interface whose monitoring destination information is currently defined.

-p polladdress1[,polladdress2]

Specify the host names or IP addresses of the monitoring destinations to be modified. In RIP mode, specify the host names or IP addresses of neighboring routers as the monitoring destinations. In NIC switching mode, specify the host names or IP addresses of the primary and secondary HUBs.

-b on | off:

If two HUBs are specified as monitoring destinations in NIC switching mode, communication between the primary and secondary HUBs can be monitored. This parameter cannot be specified for the monitoring destination information in RIP mode.

on: Monitors communication between two HUBs.
off: Does not monitor communication between two HUBs.

Changing the number of monitoring targets from two targets to one target, verify that HUB-to-HUB monitoring exists, and if the value is set "on", then change it back to "off".

(5) delete command

Use the delete command to delete the monitoring destination information. The following is the format of the delete command:

/opt/FJSVhanet/usr/sbin/hanetpoll delete -n {devicename1[,devicename2,...] | all}

-n devicename1[,devicename2,...]:

Specify the names of virtual interfaces (such as sha0 and sha1) whose monitoring destination information should be deleted.

all:

Specify this parameter to delete all the defined monitoring destination information.

(6) on command

To make the created HUB monitoring function valid, and to change an interval to monitor a HUB monitoring function, use the on command:

/opt/FJSVhanet/usr/sbin/hanetpoll on [-s sec] [-c times] [-b sec] [-f {yes | no}] [-p sec]

-s sec:

Specify the monitoring time in seconds. A value from 1 to 300 can be specified (note that the product of sec and time must be 300 or less). If this option is not specified, the previous setting is enabled. Initially, 5 (seconds) is specified.

-c times:

Specify the monitoring count. A value from 1 to 300 can be specified (note that the product of sec and time must be 300 or less). If this option is not specified, the previous setting is enabled. Initially, 5 (times) is specified.

-b sec:

When detected an error in HUB-to-HUB monitoring of NIC switching mode, specify an interval to monitor recovery. The range possible to set is zero to 300. If not specified this option, the values set the last time become valid. 5 (seconds) is set as the initial set value.

-f yes | no:

Specify the operation used when node switching occurs due to a line failure during cluster operation. If this option is not specified, the previous setting is enabled. Initially, "yes" is specified. (This parameter is enabled only during cluster operation.)

yes: Node switching is performed if a line monitoring failure occurs.
no: No node switching is performed if a line monitoring failure occurs.

-p sec:

Specify in seconds the wait time that should elapse after monitoring starts and before the HUB links up in NIC switching mode. A value from 1 to 300 can be specified. If this option is not specified, the previous setting is enabled. Initially, 60 (seconds) is specified. If the specified value is less than the monitoring interval multiplied by the monitoring count, the system ignores the specified link-up time and adopts the time obtained by multiplying the monitoring interval by the monitoring count.

(7) off command

Use the off command to disable the HUB monitoring function. The following is the format of the off command:

/opt/FJSVhanet/usr/sbin/hanetpoll off

[Notes]

[Examples]

(1) create command

The following shows an example of creating configuration information for monitoring two routers routerA and routerB on virtual interface sha2. The host name is assumed to be associated with the IP address in the /etc/hosts file.

# /opt/FJSVhanet/usr/sbin/hanetpoll create -n sha2 -p routerA,routerB


(2) copy command

The following is an example of copying monitoring target data defined in virtual interface sha0 for NIC switching mode into sha1. (By copying the configuration data of sha0 onto sha1, when sha0 performs failover operation, sha1 also fails back along with sha0).

# /opt/FJSVhanet/usr/sbin/hanetpoll copy -n sha0,sha1

(3) print command

The following shows an example of displaying the configuration information list of a virtual interface.

# /opt/FJSVhanet/usr/sbin/hanetpoll print

(4) modify command

The following shows an example of changing configuration information for monitoring two hubs hubA and hubB to hubA and hubC on virtual interface sha2. The host name is assumed to be associated with the virtual IP address in the /etc/hosts file.

# /opt/FJSVhanet/usr/sbin/hanetpoll modify -n sha2 -p hubA,hubC

(5) delete command

The following shows an example of deleting the monitoring destination information on virtual interface sha2 from the definition.

# /opt/FJSVhanet/usr/sbin/hanetpoll delete -n sha2

(6) on command

The following shows an example of starting the HUB monitoring function.

# /opt/FJSVhanet/usr/sbin/hanetpoll on

(7) off command

The following shows an example of stopping the HUB monitoring function.

# /opt/FJSVhanet/usr/sbin/hanetpoll off



Contents Index PreviousNext

All Rights Reserved, Copyright (C) FUJITSU LIMITED 2006