Multiple IPs
Pierfrancesco Caci
pf at caci.it
Wed Jan 19 22:15:39 UTC 2005
:-> "Ben" == Ben Hodgson <ubuntu-list at blahpro.com> writes:
> Hi,
> How can I add multiple IPs to one physical ethernet card? I tried using the
> built-in tool in webmin (i.e to create a virtual interface) but it just
> wrecked
> all the network settings and rendered the machine network-blind.
ip addr add x.x.x.x dev eth0
(needs the iproute package that I don't remember if it's installed by
default in ubuntu)
or you can use aliases
ifconfig eth0:1 ....
> Is there a config file I can edit? (or, what config file can I edit, lol)
I usually add an "up" line in /etc/network/interfaces doing the above
command:
iface eth0 inet static
address x.y.z.114
netmask 255.255.255.248
gateway x.y.z.113
up ip addr add 192.168.1.2/24 dev eth0
down ip addr del 192.168.1.2 dev eth0
the iproute tools are explained in the "Linux Advanced Routing and
Traffic Control HOWTO" (http://lartc.org/)
Pf
--
-------------------------------------------------------------------------------
Pierfrancesco Caci | ik5pvx | mailto:p.caci at tin.it - http://gusp.dyndns.org
Firenze - Italia | Office for the Complication of Otherwise Simple Affairs
Linux penny 2.6.10-ac2 #1 Sat Jan 1 20:35:39 CET 2005 i686 GNU/Linux
More information about the ubuntu-users
mailing list