how can i config two IP address on one network card?

how can i config two IP address on one network card?

Post by ston » Sat, 15 Apr 2000 04:00:00



as the title,i want to config two IP address on one card.
the two IP is such as 192.20.11.3 and 201.4.2.88.
how can carry it out?
thanks!
 
 
 

how can i config two IP address on one network card?

Post by Barry Margoli » Sun, 16 Apr 2000 04:00:00



>as the title,i want to config two IP address on one card.
>the two IP is such as 192.20.11.3 and 201.4.2.88.
>how can carry it out?

The answer depends on the version of Unix, which you haven't supplied.

--

Genuity, Burlington, MA
*** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.

 
 
 

how can i config two IP address on one network card?

Post by John » Sun, 16 Apr 2000 04:00:00


It's fairly simple.

You are going to a main interface whether it be hme0 or le0 that is
the interface that will be configured at bootup. Do ifconfig -a to
list all the interfaces. I am going to do this for your ip 201.4.2.88
Next step
ifconfig hme0:1 201.4.2.88 netmask 255.255.255.0 broadcast + up
you need to enter your correct netmask. Next type ifconfig -a
and you should see the interface you just created and you should
be able to ping it. Next vi /etc/hostname.hme0:1 and put in the
interface name i.e. www.checkthisout.com
Next modify your /etc/hosts file and put the entry in. And there you go.

John


>as the title,i want to config two IP address on one card.
>the two IP is such as 192.20.11.3 and 201.4.2.88.
>how can carry it out?
>thanks!