We can test the basic functionality of our LAN interface by trying to communicate at the Data-Link layer. Ideally, we have two nodes connected to the same wire (coaxial) or the same hub/switch. We should be able to test at a primitive level that these nodes can communicate. First, we need the station address (or MAC address) of a connected interface card from each node: root@hpeos004[dev] lanscan Hardware Station Crd Hdw Net-Interface NM MAC HP-DLPI DLPI Path Address In# State NamePPA ID Type Support Mjr# 0/0/0/0 0x00306E5C4F4F 0 UP lan0 snap0 1 ETHER Yes 119 0/2/0/0/4/0 0x00306E46996C 1 UP lan1 snap1 2 ETHER Yes 119 0/2/0/0/5/0 0x00306E46996D 2 UP lan2 snap2 3 ETHER Yes 119 0/2/0/0/6/0 0x00306E46996E 3 UP lan3 snap3 4 ETHER Yes 119 0/2/0/0/7/0 0x00306E46996F 4 UP lan4 snap4 5 ETHER Yes 119 root@hpeos004[dev] We use lan0 in this example. And from a second node: root@hpeos003[] lanscan Hardware Station Crd Hdw Net-Interface NM MAC HP-DLPI DLPI Path Address In# State NamePPA ID Type Support Mjr# 0/0/0/0 0x00306E5C3FF8 0 UP lan0 snap0 1 ETHER Yes 119 0/2/0/0/4/0 0x00306E467BF0 1 UP lan1 snap1 2 ETHER Yes 119 0/2/0/0/5/0 0x00306E467BF1 2 UP lan2 snap2 3 ETHER Yes 119 0/2/0/0/6/0 0x00306E467BF2 3 UP lan3 snap3 4 ETHER Yes 119 0/2/0/0/7/0 0x00306E467BF3 4 UP lan4 snap4 5 ETHER Yes 119 root@hpeos003[] Again, we use lan0 . Using the command linkloop , we can establish whether basic connectivity is available between these interfaces, regardless of which class of IP address has been assigned, if any. root@hpeos003[] linkloop -i 0 0x00306E5C4F4F Link connectivity to LAN station: 0x00306E5C4F4F -- OK root@hpeos003[] As you can see, we not only supply the MAC address of the other machine but we also specify the PPA of the interface on our machine over which the MAC frame will be sent. Where we have multiple interfaces, this is crucial; otherwise , we might not get a response because an interface is plugged into a different switch. In a High Availability scenario, we commonly have multiple interfaces plugged into the same switch, and in such a scenario, we need to ensure that all interfaces can communicate among each other, i.e., two interfaces per node (e.g., lan0 and lan1 ), with two nodes requires four linkloop commands: lan0 lan0 , lan0 lan1 , lan1 lan0 , and lan1 lan1 . If any of these linkloop commands fail, we need to investigate further; it may be that the switch is filtering certain MAC addresses on a port-by-port basis or the 802.1 Spanning Tree algorithm has been disabled for the switch. Other problems may include cable or interface card problems. Replacing a cable is relatively simple. Before you replace an interface card, you may wish to reset it via lanadmin . If the reset fails, there may be a problem with the card, the cable, or the hub/switch; whichever it is that needs further investigation. root@hpeos003[] lanadmin LOCAL AREA NETWORK ONLINE ADMINISTRATION, Version 1.0 Mon, Sep 15,2003 14:33:07 Copyright 1994 Hewlett Packard Company. All rights are reserved. Test Selection mode. lan = LAN Interface Administration menu = Display this menu quit = Terminate the Administration terse = Do not display command menu verbose = Display command menu Enter command: l LAN Interface test mode. LAN Interface PPA Number = 0 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: p Enter PPA Number. Currently 0: 1 LAN Interface test mode. LAN Interface PPA Number = 1 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: r Resetting LAN Interface to run selftest. LAN Interface test mode. LAN Interface PPA Number = 1 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: d LAN INTERFACE STATUS DISPLAY Mon, Sep 15,2003 14:33:16 PPA Number = 1 Description = lan1 HP A5506B PCI 10/100Base-TX 4 Port [NO LINK,,AUTO ,TT=1500] Type (value) = ethernet-csmacd(6) MTU Size = 1500 Speed = 10000000 Station Address = 0x306e467bf0 Administration Status (value) = up(1) Operation Status (value) = down(2) Last Change = 1756771 Inbound Octets = 432356 Inbound Unicast Packets = 0 Inbound Non-Unicast Packets = 1971 Inbound Discards = 0 Inbound Errors = 0 Inbound Unknown Protocols = 1971 Outbound Octets = 156 Outbound Unicast Packets = 4 Outbound Non-Unicast Packets = 0 Outbound Discards = 0 Outbound Errors = 0 Outbound Queue Length = 0 Specific = 655367 Press <Return> to continue Ethernet-like Statistics Group Index = 2 Alignment Errors = 0 FCS Errors = 0 Single Collision Frames = 0 Multiple Collision Frames = 0 Deferred Transmissions = 0 Late Collisions = 0 Excessive Collisions = 0 Internal MAC Transmit Errors = 0 Carrier Sense Errors = 0 Frames Too Long = 0 Internal MAC Receive Errors = 0 LAN Interface test mode. LAN Interface PPA Number = 1 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: q root@hpeos003[] Remember that resetting a LAN interface will disrupt any connections currently established over that interface. From the above output, the Administration Status of UP simply means that the card is working. The Operation State of DOWN simply means that we have configured an IP address to that card; this used to be displayed in the output from lanscan (HP-UX 10.X) as a Hardware State and a Software State . |