petek, 11. maj 2007

Additional IP on Ubuntu 7.04

I've been using Ubuntu (6.10 and now 7.04) for couple of months now and I love it.
In my company there are a lot of computers with different IPs and netmasks and I need to access them. I haven't found a way how to do it with a GUI, since a lot of things can be done via GUI in Ubuntu.
So, for you who are interested in the solution, here it is:

sudo vi /etc/network/interfaces

and edit the file to get something like:

auto eth0 eth0:1 eth0:2
iface eth0 inet static
address 192.168.0.2
netmask 255.255.255.0
gateway 192.168.0.1

iface eth0:1 inet static
address 10.10.33.10
netmask 255.255.255.0

iface eth0:2 inet static
address 10.10.50.10
netmask 255.255.255.0


Now I have three IPs (192.168.0.2, 10.10.33.10 and 10.10.50.10).

Ni komentarjev: