Operating System - HP-UX
1837239 Members
2282 Online
110115 Solutions
New Discussion

Can I change Lan Interface Name from lan1 to lan0

 
SOLVED
Go to solution
Deborah Grierson
Frequent Advisor

Can I change Lan Interface Name from lan1 to lan0

I have a problem with the lan card on a D-Class server.

It is the only lan card on the machine.

When I do a 'lanscan' I get a NetworkInterface Name Unit of lan1 (see attachment). This has not been a problem until I installed a licence which is tied into the Station Address of the unit, because the licence is looking for lan0.

A simple solution would be to change it from lan1 to lan0. Is this possible, and if so, how do I do it?

JJHH
I'll need all the help I can get
18 REPLIES 18
James R. Ferguson
Acclaimed Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi John:

Edit your /etc/rc.config.d/ configuration file and specify the card you want as the *first* (element [0]).

In this case, if I recall, the file should be 'hpetherconf'.

Regards!

...JRF...
Sukant Naik
Trusted Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi,

Make the following changes to the /etc/rc.config.d/hpetherconf file.

HP_ETHER_INTERFACE_NAME[0]=lan1

Use the lanadmin command lanadmin -a and find the station address.
for eg:
sukant@nask3>> lanadmin -a 0
Station Address = 0x080009adacbd

Then change the following parameter to the station address in the /etc/rc.config.d/hpetherconf file

HP_ETHER_STATION_ADDRESS[0]=

This would do.

-Sukant
Who dares he wins
John Bolene
Honored Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

Yup, like James said.

It would appear that the interface has been configured more than once, hence the lan1 designation.

fix the /etc/rc.config.d/netconf file and the easiest way is to reboot to make it change
It is always a good day when you are launching rockets! http://tripolioklahoma.org, Mostly Missiles http://mostlymissiles.com
Johan Gjestvang
Frequent Advisor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi, ain't nessesary easy this thing. I need to see a full ioscan list to check if you parhaps have a lancard with no driver attached to it.
It may be possible to change from lan1 to lan0 by doing
rmsf on /dev/lan1 and then
doing insf -e to recreate the lan0 device. However you have to run this commands from the console hench the lanconnectoion will be gone.
Then you have to reboot.
Do't forget to update the /etc/rc.config.d/netconf file.
From the output format of the lanscan, it looks like
you are running 10.20
Be very carefully! It's a risky operation.
Deborah Grierson
Frequent Advisor

Re: Can I change Lan Interface Name from lan1 to lan0

Nice try, guys, but as you can see (attachment) the hpetherconf file is already as you have suggested. .....And the machine has been rebooted several times in this state.

JJHH
I'll need all the help I can get
Ravi_8
Honored Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi,
Just changing the name from lan1 to lan0 doesn't work, or even by modifying the file as JRF says, since the lan card has a path on scsi and major/minor attached to it.
never give up
sven verhaegen
Respected Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

some more bad news , the lan naming itself is not only dependant on lancard but on the slot it is in and the order in which it has been introduced , meaning if you put a lancard in physical slot 1 it will get lan0 as driver , if you take the same card and put it for instance in slot 4 that will become lan1 , another card put in slot 1 wil be called lan0 , the driver name is bound to the slot not the card so it's much harder to get out of that situation
...knowing one ignores a greath many things is the first step to wisdom...
James R. Ferguson
Acclaimed Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi (again) John:

OK, you want to change the card's instance number. Do this:

Make a file, called '/tmp/laninit' and place the following line in it:

8/16/6 lan 0

Now, do:

# ioinit -f /tmp/laninit

Now reboot and verify the correct instance number with 'lanscan'. Then:

# cd /dev
# insf -e
# lssf /dev/lan* #...to verify device files...

Regards!

...JRF...





Sanjay_6
Honored Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi John,

Try these procedures to change the instance no of the lan cards,

http://us-support2.external.hp.com/cki/bin/doc.pl/sid=0a25dc6b1cf07dffc8/screen=ckiDisplayDocument?docId=200000058668743

Hope this helps.

Regds


Deborah Grierson
Frequent Advisor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi James,

I was beginning to get VERY NERVOUS after reading some of the replies, but yours was more encouraging. I'll try it when I can get the users off the system.

May I ask you, in the tmp file, should there be a space between 'lan' and '0' ?

JJHH
I'll need all the help I can get
James R. Ferguson
Acclaimed Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi John:

Yes, there *is* a blank (space) between "0" and "lan" in the line of the file I showed.

Regards!

...JRF...
Deborah Grierson
Frequent Advisor

Re: Can I change Lan Interface Name from lan1 to lan0

James,

I tried your solution, but when I entered 'ioinit -f /tmp/laninit' I got the response:

'ioinit: Instance number 0 already exists for class lan.'
Line 1. 8/16/6 lan 0

JJHH
I'll need all the help I can get
Deborah Grierson
Frequent Advisor

Re: Can I change Lan Interface Name from lan1 to lan0

Sanjay,

Thanks for your reference, but I can't access it. I'm registered in the Europe Resource Centre and can't access the US Resource Center.

JJHH
I'll need all the help I can get
Sanjay_6
Honored Contributor
Solution

Re: Can I change Lan Interface Name from lan1 to lan0

Hi John,

To access the link posted by us, if the link has us-support and you are accessing the same from europe itrc, substitute europe-support in place of us-support and the link should open up on the europe itrc. By the way the TKB doc no is KBAN00000795

Hope this helps.

Regds
James R. Ferguson
Acclaimed Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

Hi (again) John:

I presume then, that at one time there *was* a card at instance #0. Although the thread referenced below describes a case with a tape drive, the issue is the same, I believe. Follow the discussion starting with the thread referenced by Joseph in this thread, and continue with its denoument by Carsten Krege. If this fits, contact HP Support for the utility Carsten used.

http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x60cacf38d6bdd5118ff10090279cd0f9,00.html

Regards!

...JRF...
sven verhaegen
Respected Contributor

Re: Can I change Lan Interface Name from lan1 to lan0

 
...knowing one ignores a greath many things is the first step to wisdom...
Deborah Grierson
Frequent Advisor

Re: Can I change Lan Interface Name from lan1 to lan0

Thank you all for your enthusiastic and helpful input; there are so many threads to explore, but of necessity I must try one at a time.

James, you are the lucky one as I've had some success following the Carsten thread. The ioc program was attached to his reply, so I detached it and gave it a spin:

> ./ioc | grep -e Class -e lan

Class I H/W Path Driver
lan 0 8 8 1 0 btlan4
lan 1 8 16 6 lan2

The previously configured lan0 was there!

I created a file /tmp/laninit containing the lines:

8/8/1/0 lan 2
8/16/6 lan 0

and did:

> ioinit -f /tmp/laninit
> ./ioc | grep -e Class -e lan

Class I H/W Path Driver
lan 2 8 8 1 0 btlan4
lan 0 8 16 6 lan2

Then I did a similar procedure to change lan2 to lan1. - Just to practice my newly acquired skill!

So, now I need to reboot to verify the instance number change with lanscan, and to create the device files.

It looks as if things are going to work out. I'll let you know.

Once again, THANK YOU VERY MUCH !!!!!!!

JJHH

I'll need all the help I can get
Deborah Grierson
Frequent Advisor

Re: Can I change Lan Interface Name from lan1 to lan0

James,

It worked like a dream! Thank you.

And thanks to everyone who contributed.

JJHH
I'll need all the help I can get