*SOLVED* VLAN on VETH device? [message #6841] |
Mon, 25 September 2006 09:31 |
szocske
Messages: 35 Registered: September 2006
|
Member |
|
|
Hi!
I'd like to issue vconfig commands within a VE to set up VLANs on its veth interface. (which it beleives to be eth0.) But there is no /proc/net/vlan directory inside the VEs.
I have the 8021q module loaded in the kernel, so vconfig works fine outside, in the HW node, on the real eth0.
Is this a known limitation, a bug, or my misconfiguration?
OpenVz patch version 026test015.
[Updated on: Tue, 07 November 2006 19:42] by Moderator Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
|
Re: VLAN on VETH device? [message #8137 is a reply to message #8107] |
Thu, 09 November 2006 10:19 |
szocske
Messages: 35 Registered: September 2006
|
Member |
|
|
Andrey Mirkin wrote on Tue, 07 November 2006 11:19 | The patch for 2.6.18 kernel is ready.
You can try it right now.
vlan virtualization will be available in next kernel release.
|
We have it working, and see no regression in regular functionality.
/proc/net/vlan directory exists and can be populated via vconfig.
But any vlan subinterface created in one VE is visible in all (the veth device is called eth0 in all VEs)
ifconfig -a does not list "foreign" vlans.
It is not possible to create vlans with the same vlan ID in multiple VEs:
eserver25-vz6:~# vconfig add eth0 106
Added VLAN with VID == 106 to IF -:eth0:-
eserver25-vz7:~# vconfig add eth0 107
Added VLAN with VID == 107 to IF -:eth0:-
eserver25-vz6:~# vconfig add eth0 107
ERROR: trying to add VLAN #107 to IF -:eth0:- error: Invalid argument
eserver25-vz6:~# cat /proc/net/vlan/
config eth0.106 eth0.107
eserver25-vz6:~# cat /proc/net/vlan/config
VLAN Dev name | VLAN ID
Name-Type: VLAN_NAME_TYPE_RAW_PLUS_VID_NO_PAD
eth0.106 | 106 | eth0
eserver25-vz6:~# ls /proc/net/vlan/
config eth0.106 eth0.107
eserver25-vz6:~# cat /proc/net/vlan/eth0.107
eth0.107 VID: 107 REORDER_HDR: 1 dev->priv_flags: 1
total frames received 0
total bytes received 0
Broadcast/Multicast Rcvd 0
total frames transmitted 0
total bytes transmitted 0
total headroom inc 0
total encap on xmit 0
Device: eth0
INGRESS priority mappings: 0:0 1:0 2:0 3:0 4:0 5:0 6:0 7:0
EGRESSS priority Mappings:
Can we have this revised please?
Editing:
Just noticed, same goes for host machine:
eserver25:~# ls /proc/net/vlan/
config eth0.106 eth0.107
eserver25:~# cat /proc/net/vlan/config
VLAN Dev name | VLAN ID
Name-Type: VLAN_NAME_TYPE_RAW_PLUS_VID_NO_PAD
Editing again:
And I can't shut down the VE which has a VLAN configured:
eserver25:~# vzctl stop 109
Stopping VPS ...
Message from syslogd@localhost at Thu Nov 9 11:34:37 2006 ...
localhost kernel: unregister_netdevice: waiting for eth0 to become free. Usage count = -1
Message from syslogd@localhost at Thu Nov 9 11:35:17 2006 ...
localhost last message repeated 4 times
Meanwhile, the vlans disappear from the remaining machines:
eserver25-vz6:~# ls /proc/net/vlan/
config
eserver25-vz6:~# cat /proc/net/vlan/config
VLAN Dev name | VLAN ID
Name-Type: VLAN_NAME_TYPE_RAW_PLUS_VID_NO_PAD
eth0.106 | 106 | eth0
[Updated on: Thu, 09 November 2006 10:41] Report message to a moderator
|
|
|
|
Re: *SOLVED* VLAN on VETH device? [message #8336 is a reply to message #6841] |
Thu, 16 November 2006 09:15 |
szocske
Messages: 35 Registered: September 2006
|
Member |
|
|
Hi again!
Sorry for the high latency, we had to provision the new sun servers we purchased for openvz
The updated patch works, we can now ping over a vlan from one VE to another. (tested within a HW node only)
Stopping VEs works fine too.
/proc/net/vlan looks funny though:
sun03:/# ls /proc/net/vlan
config eth0.42 eth0.42 eth2.42
VLAN ID 42 was configured on the veth-s of two VEs (both eth0) and the HW node eth2. Looks the same from HW node and VEs.
We'll continue testing across a switch, and with our ioctls, and report.
One more (probably unrelated) quirk:
Despite setting up /etc/hostname correctly in the VEs, when started, `hostname` returns the HW node hostname in all of them.
Better yet: issuing the hostname command within a VE to change the hostname changes it for all VEs, and the HW node as well!
Used to work fine on 2.6.16.
Debian stable + vlan-enabled kernel
[Updated on: Thu, 16 November 2006 10:00] Report message to a moderator
|
|
|
|
|
|
|
|