james at gray.net.au
Sun Jan 21 23:37:52 UTC 2007
On Monday 22 January 2007 09:00, IsomerX wrote:
> I'm trying to create an IP address alias for the network card on one of
> y servers. It is running Ubuntu 6.9.
> I have the following lines in my /etc/network/interfaces:
> auto eth1
> iface eth0 inet static
> address 192.168.0.98
> netmask 255.255.255.0
> gateway 192.168.0.1
> iface eth1:0 inet static
> address 192.168.1.100
> When I issue the command ifconfig eth1:0 up I get the following error:
> SIOCSIFFLAGS: Cannot assign requested address
Do you have an "eth1" interface? If not, then of course you wont be able to
add a virtual interface to a non-existent interface :P
I think you've simply got the numbering switched around. Based on the config
above, you should be able to assign a virtual interface to "eth0" like this:
iface eth0:0 inet static
# You could use eth0:1 if you prefer too.
The numbering is always "eth<REAL-INTERFACE>:<VIRTUAL-INTERFACE>".
The "real-interface" must exist otherwise you'll get the error you describe
"It's a dog-eat-dog world out there, and I'm wearing Milkbone underware."
-- Norm, from _Cheers_
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 1349 bytes
Desc: not available
More information about the ubuntu-users