Operating System - HP-UX
1820623 Members
1817 Online
109626 Solutions
New Discussion юеВ

Re: How to simultate a NIC failure

 
SOLVED
Go to solution
Andrew Underhill
Occasional Advisor

How to simultate a NIC failure

Can anyone advise how to simulate a NIC failure to test that our cluster has been configured correctly. The reason why I ask is that we can't seem to get any Network types to do things to the switches.

Thanks
8 REPLIES 8
Mark Grant
Honored Contributor

Re: How to simultate a NIC failure

Well, pulling the cable out will have the same effect.

However, in most cases, if the NIC failes, hpux will bring the interface down. Therefore, you could simulate this by bringing the interface down yourself. "ifconfig lanX down"
Never preceed any demonstration with anything more predictive than "watch this"
Stephen Doud
Honored Contributor
Solution

Re: How to simultate a NIC failure

Software "downing" a NIC does -not- have the same effect as pulling the cable out of the NIC!

All that does is disable the IP traffic-handling ability of the adapter - layer 3 of the OSI model. However Serviceguard does it's LAN failure detection at layer 2 - NO IP assignment is required in order to pass this test!

Hence, physically disconnecting from the network is one of the few legitimate methods to test NIC failure detection.

See the section titled "Testing the Network Manager" of the Managing Serviceguard document for reitteration:
http://docs.hp.com/cgi-bin/fsearch/framedisplay?top=/hpux/onlinedocs/B3936-90073/B3936-90073_top.html&con=/hpux/onlinedocs/B3936-90073/00/00/56-con.html&toc=/hpux/onlinedocs/B3936-90073/00/00/56-toc.html&searchterms=the%7cNetwork%7cManager%7cTesting&queryid=20040420-054822

-SD-
Andrew Underhill
Occasional Advisor

Re: How to simultate a NIC failure

Thanks Stephen, a definitive answer but not the one I wanted.

Would it be possible to do it through OLAR?
SS_6
Valued Contributor

Re: How to simultate a NIC failure

Use lanadmin and reset that card, you must see the IP will failover to standby card and will come back to original after few seconds. Do man on lanadmin and lanscan to see ppa i.e lan number ( you need it for lanadmin)
By providing solutions I am helping myself
Michael Tully
Honored Contributor

Re: How to simultate a NIC failure

If you have a rpxxxx system it is possible I guess using the swag of 'rad' commands. It would be easy enough to suspend the software on the port using:

# /usr/bin/rad -s slot_id

The man pages for 'rad' explain fairly well.
Anyone for a Mutiny ?
Rasheed Tamton
Honored Contributor

Re: How to simultate a NIC failure

lanadmin -x 0 (will show you the current speed of lancard 0 config)
if the speed is 100 Full-Duplex,
you can do
lanadmin -X 0 100FD or according to your speed (HD for Half Duplex, etc.) to reinitialize the lan card thereby the lan 0 will fail to lan1 and return back to lan 0 in a Service Guard cluster. That will produce and lan failover on a SG cluster and you can see it logged in a syslog.log file.

Rasheed.
Rasheed Tamton
Honored Contributor

Re: How to simultate a NIC failure

Adding to the prev. one.
-----
lanadmin -x 0 (to see the settings, it is a small x)

lanadmin -X 100FD 0 (it will reconfigure or reset the setting as 100Full Duplex - pls note it is a capital X to reconfigure).

Rasheed.
Stephen Doud
Honored Contributor

Re: How to simultate a NIC failure

I don't know OLAR capabilities, so I can't say for certain whether using OLAR is a valid test.
Michael Tully mentioned the 'rad' command (OLAR).
lanscan reports the hardware path of the NIC.
rad -q reports the slot for each I/O device.
On my virtual partition on my superdome, I didn't see the LAN adapter in the rad -q output:

# model
9000/800/SD64000

# lanscan
Hardware Station Crd Hdw Net-Interface NM MAC HP-DLPI DLPI
Path Address In# State NamePPA ID Type Support Mjr#
12/0/0/1/0 0x001083FD1DFC 0 UP lan0 snap0 1 ETHER Yes 119

# rad -q
Driver(s)
Slot Path Bus Max Spd Pwr Occu Susp Capable Max Mode
Num Spd Mode
1-1-1-0 12/0/0 0 N/A 33 On Yes No No N/A N/A
1-1-1-1 12/0/1/0 8 N/A 33 On Yes No Yes N/A N/A
1-1-1-5 12/0/6/0 48 N/A 66 On Yes No Yes N/A N/A
1-1-1-6 12/0/14/0 112 N/A 33 On No N/A N/A N/A N/A
1-1-1-7 12/0/12/0 96 N/A 66 On Yes No Yes N/A N/A
1-1-1-8 12/0/11/0 88 N/A 33 On No N/A N/A N/A N/A
1-1-1-11 12/0/8/0 64 N/A 33 On Yes No Yes N/A N/A

So - I'm not certain that the LAN NIC can be disabled. You may want to confirm this in the HPUX-OS forum.

-SD-