Operating System - HP-UX
1833350 Members
3151 Online
110051 Solutions
New Discussion

2 ethernet address, two different ip

 
SOLVED
Go to solution
Rob O'Connor
Advisor

2 ethernet address, two different ip

Hi everyone:
I need help in configuring two separate ethernet interface with two different ip address. This won't be done until later but need to make sure is right before implementing the changes. The lan0 has ip address 10.X.X.X
and the lan1 has ip address of 10.X.X.Z.
I changed the /etc/rc.config.d/netconf and looks like the following:
INTERFACE_NAME[0]=lan0
IP_ADDRESS[0]=10.X.X.X
SUBNET_MASK[0]=255.255.255.0
BROADCAST_ADDRESS[0]=10.X.X.Y
INTERFACE_STATE[0]=""
DHCP_ENABLE[0]=0

INTERFACE_NAME[1]=lan1
IP_ADDRESS[1]=10.X.X.Z
SUBNET_MASK[1]=255.255.255.0
BROADCAST_ADDRESS[1]=10.X.X.Y
INTERFACE_STATE[1]=""
DHCP_ENABLE[1]=0
Do I need to configure any more files in order for two interface to work? Thanks.

H
5 REPLIES 5
Enrico P.
Honored Contributor
Solution

Re: 2 ethernet address, two different ip

Hi,

after modify the /etc/rc.config.d/netconf

#/sbin/init.d/net stop
#/sbin/init.d/net start

You need to modify the /etc/hosts with the new IPaddres

Enrico.
Elena Leontieva
Esteemed Contributor

Re: 2 ethernet address, two different ip

I would suggest to reboot the server when all changes are implemented.

Elena.
Steven E. Protter
Exalted Contributor

Re: 2 ethernet address, two different ip

In HP-UX you can't have to lan card's lan0 and lan1 in this example on the same network and subnet.

In this example, because your subnet is 255.255.255.0 the network is the first three octets of the IP address

both networks are 10.X.X

That is a good way to lock up your machine or drop it right off the network. Trust me, I've got the tee-shirt on this one, tried it myself.

If you are attempting to team the NIC cards or create a failover situation, you need to purchase APA, Auto Port Agregation.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Elena Leontieva
Esteemed Contributor

Re: 2 ethernet address, two different ip

Note, that if you get it on 10.X.Y and 10.X.Z, - it works fine. We have two cards/IPs on most of our servers.
Suresh Patoria
Super Advisor

Re: 2 ethernet address, two different ip

Hi,

Above configuration is OK

After editing /etc/rc.config.d/netconf file i wll suggest u to reboot the system for proper binding the lan interfaces.

And also put the entry in /etc/hosts file

Check the interfaces after rebooting use the command ifconfig,lanscan,netstat,lanadmin