From: Alberto Cammozzo (mmzz_at_stat.unipd.it)
Date: Wed 13 Jul 2005 - 11:46:50 BST
Hello,
I am setting up a vserver with vlans: each vserver one or
more dot1q vlans.
Seems to work fine, except that the "vserver start" insists
on giving the interface a fake 127.0.0.1 address,
even if it has an interface configuration in
/etc/vservers/XX/interfaces/0/ip
and /etc/vservers/XX/interfaces/dev has "eth0.2" in it.
To have it working properly I have to deconfigure and
reconfigure by hand the interface from the host server
after the vserver is started.
Seems like this is a known and correct (?) behavior since 2003:
<http://vserver.13thfloor.at/Stuff/VServer-IP-Setup-0.1.txt>
> 1.3 Is there a Device?
>
> now the script checks whether <device> is non empty
> (which means either IPROOTDEV or the device part for
> this entry wasn't empty), and if found so, does the
> following (if not, continue with the next entry):
>
> - if a vlan device was specified (<name>.<vlan>)
> some vlan setup (vconfig add ...) is done and
> a fake base address (127.0.0.1) is assigned.
In vserver.functions the code says:
> test -f /proc/net/vlan || {
> _addInterfaceCmd VCONFIG ${dev/./ }
> _addInterfaceCmd IP_ADDR 127.0.0.1/8 broadcast 127.255.255.255 dev "$dev"
> _addInterfaceCmd IP_LINK "$dev" $up
> }
What do I have to do to give eth0.2 a different IP address?
Thanks!
Alberto
# vserver-info
Versions:
Kernel: 2.6.11.11+dm-1.00.21+evms-2.5.2+vs1.9.5
VS-API: 0x00010025
util-vserver: 0.30.204; May 24 2005, 22:22:03
Features:
CC: gcc, gcc (GCC) 3.3.5 (Debian 1:3.3.5-5)
CXX: g++, g++ (GCC) 3.3.5 (Debian 1:3.3.5-5)
CPPFLAGS: ''
CFLAGS: '-Wall -g -O2 -std=c99 -Wall -pedantic -W'
CXXFLAGS: '-g -O2 -ansi -Wall -pedantic -W -fmessage-length=0'
build/host: i386-pc-linux-gnu/i386-pc-linux-gnu
Use dietlibc: yes
Build C++ programs: yes
Build C99 programs: yes
Available APIs: compat,v11,v13,fscompat,net,oldproc,olduts
ext2fs Source: e2fsprogs
syscall(2) invocation: fast
vserver(2) syscall#: 273/glibc
Paths:
prefix: /usr
sysconf-Directory: /etc
cfg-Directory: /etc/vservers
initrd-Directory: $(sysconfdir)/init.d
pkgstate-Directory: /var/run/vservers
Kernelheaders: /lib/modules/2.6.10-1-686-smp/build/include
vserver-Rootdir: /var/lib/vservers
-- Alberto Cammozzo V.Cesare Battisti 241/243. PADOVA ITALY System/Network Manager e-mail : mmzz_at_stat.unipd.it Universita` di Padova -IT tel : +39 49 8274175 _______________________________________________ Vserver mailing list Vserver_at_list.linux-vserver.org http://list.linux-vserver.org/mailman/listinfo/vserver