UnixPedia : HPUX / LINUX / SOLARIS: HPUX : APA : Configuration step in LAN MONITOR MODE.

Thursday, March 6, 2014

HPUX : APA : Configuration step in LAN MONITOR MODE.



LAN Monitor Overview
The LAN Monitor mode of HP APA provides a failover capability with configuration tools similar to HP Serviceguard.
LAN Monitor does not support HP Serviceguard. In the event of link failure, LAN Monitor automatically migrates the
data flow from the primary link to one of the standby links in the failover group.
LAN Monitor Features
High availability and fast failover of network interfaces
The ability to make link aggregates part of the failover group.
• Automatic failover group discovery and configuration commands (lanqueryconf, lanapplyconf,
lancheckconf, landeleteconf).

Configuring LAN Monitor Failover Groups
1. Connect the physical devices that are to be in the failover group to the same switch, or to different switches or
hubs on the same subnet to achieve switch/hub redundancy.
2. Check that a linkloop between the devices succeeds. If it fails, resolve the physical connection between the
devices.
3. In the /etc/rc.config.d/hp_apaportconf file, assign the primary and standby physical ports to
LAN_MONITOR mode.
For example, to put lan1 and lan2 into a failover group:
HP_APAPORT_INTERFACE_NAME[0]=lan1
HP_APAPORT_CONFIG_MODE[0]=LAN_MONITOR
HP_APAPORT_INTERFACE_NAME[1]=lan2
HP_APAPORT_CONFIG_MODE[1]=LAN_MONITOR

4. Activate the configuration by entering:
# /sbin/init.d/hplm stop 1
# /sbin/init.d/hpapa stop
LAN Monitor Overview 55
# /sbin/init.d/hpapa start
# /sbin/init.d/hplm start

5. If the device to be the primary link does not have the desired IP address, add the IP address for the primary port
or primary link aggregation to /etc/rc.config.d/netconf. Editing that file or using SAM will preserve the
IP address permanently (across reboots).
You can also temporarily assign an IP address to the primary link by entering, for example, ifconfig lan1
192.5.5.138
6. Query the system for possible link failover groups by entering lanqueryconf -s.

This command queries the system and network for all possible failover groups. The results of the query are placed
in the /etc/lanmon/lanconfig.ascii configuration file. This file should contain data similar to the following:
NODE_NAME hpserver1
POLLING_INTERVAL 10000000
DEAD_COUNT 3
LM_RAPID_ARP off
LM_RAPID_ARP_INTERVAL 1000000
LM_RAPID_ARP_COUNT 10
FAILOVER_GROUP lan900
STATIONARY_IP 192.1.1.1
STANDBY lan11 3
PRIMARY lan10 5
You can edit this file and change the number of ports in the failover groups, the dead count, poll interval, rapid
ARP setting, rapid ARP interval, and rapid ARP count.

7. Verify that the configuration in /etc/lanmon/lanconfig.ascii is still valid by using the lancheckconf
command.
8. Create the failover groups specified in the configuration file by using the lanapplyconf command.
This command creates the specified failover groups and the /etc/lanmon/lanconfig binary configuration
file.
Check the failover groups by using the lanscan -q and netstat -in commands.

9. The failover group is now operational. A reboot will restart the failover group as long as the
/etc/lanmon/lanconfig.ascii file is intact.


Example: Configuring a LAN Monitor Failover Group
Suppose you want to configure a simple, two-port LAN Monitor failover group on a K-class system. You enter the netstat
and ioscan commands as follows:
# netstat -in
Name Mtu Network Address Ipkts Opkts
lan1 1500 192.1.1.0 192.1.1.153 9504123 12437048
lan0 1500 191.1.1.0 191.1.1.1 11202 257458
lo0 4136 127.0.0.0 127.0.0.1 417 417
# ioscan -fkC lan
Class I H/W Path Driver S/W State H/W Type Description
========================================================================
lan 1 8/8/1/0 btlan4 CLAIMED INTERFACE HP HSC 100Base-TX
lan 2 8/8/2/0 btlan4 CLAIMED INTERFACE HP HSC 100Base-TX
lan 3 8/12/1/0 btlan4 CLAIMED INTERFACE HP HSC 100Base-TX
lan 4 8/12/2/0 btlan4 CLAIMED INTERFACE HP HSC 100Base-TX
lan 0 10/12/6 lan2 CLAIMED INTERFACE Built-in LAN
#
The netstat output shows that lan1 is currently configured with IP address 192.1.1.153. The ioscan output shows
spare HSC 100BT devices lan2, lan3, and lan4.
You decide that lan2 will be the standby link for the failover group, with lan1 as the primary device.
To configure the failover group, do the following:
1. Connect lan1 and lan2 to the same switch or to different switches or hubs on the same subnet.
2. Obtain the station address for lan2 by issuing the lanscan command, as follows:
# lanscan
Hardware Station Crd Hdw Net-Interface NM MAC HP-DLPI DLPI
Path Address In# State NamePPA ID Type Support Mjr#
8/8/2/0 0x0060B04B7B83 2 UP lan2 snap2 3 ETHER Yes 119
8/12/2/0 0x001083953C1D 4 UP lan4 snap4 4 ETHER Yes 119
8/8/1/0 0x0060B04B7B82 1 UP lan1 snap1 5 ETHER Yes 119
10/12/6 0x080009D43696 0 UP lan0 snap0 6 ETHER Yes 119
8/12/1/0 0x001083953C1C 3 UP lan3 snap3 7 ETHER Yes 119
LinkAgg0 0x000000000000 900 DOWN lan900 snap900 9 ETHER Yes 119
LinkAgg1 0x000000000000 901 DOWN lan901 snap901 10 ETHER Yes 119
LinkAgg2 0x000000000000 902 DOWN lan902 snap902 11 ETHER Yes 119
LinkAgg3 0x000000000000 903 DOWN lan903 snap903 12 ETHER Yes 119
LinkAgg4 0x000000000000 904 DOWN lan904 snap904 13 ETHER Yes 119
The station address is 0x0060B04B7B83.
3. Verify that a linkloop command between lan1 and lan2 succeeds, as follows:
#
# linkloop -i 1 0x0060B04B7B83
Link connectivity to LAN station: 0x0060B04B7B83
-- OK
#
If the linkloop fails, resolve the connectivity issue between the devices.
4. Verify that an entry exists in the /etc/rc.config.d/hp_apaportconf file for the primary and standby
interfaces that sets the interfaces' port configuration mode to LAN_MONITOR.
HP_APAPORT_INTERFACE_NAME[0]=lan1
HP_APAPORT_CONFIG_MODE[0]=LAN_MONITOR
HP_APAPORT_INTERFACE_NAME[1]=lan2
HP_APAPORT_CONFIG_MODE[1]=LAN_MONITOR
5. Activate the configuration by entering:
# /sbin/init.d/hplm stop 1
# /sbin/init.d/hpapa stop
# /sbin/init.d/hpapa start
# /sbin/init.d/hplm start
1 An error message similar to ERROR: Unable to open /etc/lanmon/lanconfig for reading.
might appear. Ignore the message because no failover groups were created.
6. If the device to be the primary link does not have the desired IP address, enter ifconfig to assign the IP address.
Also add an entry to the /etc/rc.config.d/netconf file to assign the IP address permanently (or use SAM
to do it).
# ifconfig lan1 192.1.1.153
7. Enter the lanqueryconf -s command to query the system for possible failover groups.
# lanqueryconf -s
ASCII output is in the /etc/lanmon/lanconfig.ascii file.
a. Verify that the content of the ASCII file is valid. Enter lancheckconf:
# lancheckconf
b. View the contents of the /etc/lanmon/lanconfig.ascii file and verify that it contains the configuration
information you want.
# cat /etc/lanmon/lanconfig.ascii

c. Verify that /etc/lanmon/lanconfig.ascii has the failover group configured, as planned.
# cat /etc/lanmon/lanconfig.ascii
d. Edit the file, if needed, and enter lancheckconf again.
8. Use the lanapplyconf command to build the failover group, and check it with the lanscan -q and netstat
-in commands:
# lanapplyconf
Reading ASCII file /etc/lanmon/lanconfig.ascii
Creating Fail-Over Group lan900
Updated binary file /etc/lanmon/lanconfig
# lanscan -q
4
0
3
900 1 2
901
902
903
904
# netstat -in
Name Mtu Network Address Ipkts Opkts
lan0 1500 191.1.1.0 191.1.1.1 1794 1173
lo0 4136 127.0.0.0 127.0.0.1 390 390
lan900 1500 192.1.1.0 192.1.1.153 0 0
9. The failover group is now operational. A reboot will restart the failover group as long as the
/etc/lanmon/lanconfig.ascii file is intact and the primary port or primary link aggregation has an IP
address in /etc/rc.config.d/netconf that matches the failover group's Stationary IP entry in
/etc/lanmon/lanconfig.ascii.
If lan1 fails, lan2 becomes the active port. Similarly, if the failover group consists of two link aggregates, failover from
the primary link aggregate to the standby link aggregate occurs only when all ports in the primary link aggregate failed.




2 comments: