Operating System - HP-UX
1838263 Members
3484 Online
110125 Solutions
New Discussion

Multiple IP for single LAN card

 
SOLVED
Go to solution
Amod
Occasional Advisor

Multiple IP for single LAN card

How can I assign multiple IPs to single LAN card ?
If you can't change it, enjoy it !!
5 REPLIES 5
Sridhar Bhaskarla
Honored Contributor
Solution

Re: Multiple IP for single LAN card

Hi,

Use :1 attached to your lan device file. For ex., to add additional IP to lan0, you would do

ifconfig lan0:1 inet 10.10.10.10 netmask 255.255.255.0

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Ravi_8
Honored Contributor

Re: Multiple IP for single LAN card

Hi,

# ifconfig lan0:1 x.x.x.x
#ifconfig lan0:2 y.y.y.y etc

only be carefull not to assign IP to an idle lan card (backup lan card from MC/SG)

don't assign IP in the same subnet to varios interfaces, IPs in the same subnet always must be over the same card



never give up
T G Manikandan
Honored Contributor

Re: Multiple IP for single LAN card

you can use

#ifconfig inet

like
if your card is lan0
First virtual address
#ifconfig lan0:1 inet 169.168.2.1
2nd
#ifconfig lan0:2 inet 169.168.3.1

and so..on
Amod
Occasional Advisor

Re: Multiple IP for single LAN card

Hi all,

Thanks for your help. It worked perfectly.

AMOD.
If you can't change it, enjoy it !!
rick jones
Honored Contributor

Re: Multiple IP for single LAN card

Don't forget to (carefully) update the /etc/rc.config.d/netconf file or set-up the additional addresses via sam.
there is no rest for the wicked yet the virtuous have no pillows