OpenVZ Forum


Home » General » Support » vlan networking problem
vlan networking problem [message #2216] Fri, 24 March 2006 22:27 Go to next message
cleavoy is currently offline  cleavoy
Messages: 3
Registered: March 2006
Junior Member
Does openvz work with VLANS? Hardware node 'storm' can ping virtual node 192.168.77.25, but hosts on vlan id 0 are unable to ping it. tcpdump on the hw node shows the arp requests, but no response. tcpdump on virutal node 'rain' doesnt seem to be receiving the arp requests.

[root@storm ~]# ifconfig eth0.0
eth0.0 Link encap:Ethernet HWaddr 00:90:27:25:1D:FD
inet addr:192.168.77.2 Bcast:192.168.77.255 Mask:255.255.255.0

[root@storm ~]# vzlist
VPSID NPROC STATUS IP_ADDR HOSTNAME
101 20 running 192.168.77.25 rain

[root@storm ~]# ping 192.168.77.25
PING 192.168.77.25 (192.168.77.25) 56(84) bytes of data.
64 bytes from 192.168.77.25: icmp_seq=0 ttl=64 time=0.128 ms

[root@storm ~]# tcpdump -ni eth0.0
17:04:23.346793 arp who-has 192.168.77.25 tell 192.168.77.1
17:04:24.341127 arp who-has 192.168.77.25 tell 192.168.77.1
17:04:25.341112 arp who-has 192.168.77.25 tell 192.168.77.1

Where should I look to figure out whats wrong?

Could someone explain what this option in /etc/sysconfig/vz would be used for?
#VE_ROUTE_SRC_DEV="eth0"


--Chris

[Updated on: Fri, 24 March 2006 22:27]

Report message to a moderator

Re: vlan networking problem [message #2224 is a reply to message #2216] Sat, 25 March 2006 18:06 Go to previous messageGo to next message
dev is currently offline  dev
Messages: 1693
Registered: September 2005
Location: Moscow
Senior Member

cleavoy, OpenVZ works with VLANs.
I suppose you simply need to setup correct routing rules in host system. Something like:
# /sbin/ip r a 192.168.77.0/24 dev eth0.0 src 192.168.77.2

Also according to 'man vz', this option should also help you:

Quote:


Network interface parameters
VE_ROUTE_SRC_DEV="device"
This parameter specifies the network device name which ip address will used for source ip. If on HN configured > 1 network interfaces and
needed to specify the source ip address, set corresponding device. By default takes the first in network device list.


this parameter is used in /usr/lib/vzctl/scripts/vps-net_add scripts.



http://static.openvz.org/userbars/openvz-developer.png
Re: vlan networking problem [message #2273 is a reply to message #2224] Tue, 28 March 2006 05:34 Go to previous messageGo to next message
cleavoy is currently offline  cleavoy
Messages: 3
Registered: March 2006
Junior Member
My troubles continue.. The vlan interfaces are up and working, however when i try to cat /proc/net/vlan/conf, it segfaults. I'm going to try bringing the system upto date with centos 4.3 and the latest openvz utils/kernel. Hopefully this issue is fixed. Has anyone else run into this problem?

Btw, I did a quick test, and the Centos 2.6.9-22.EL stock kernels are not causing segfaults, so i think this might be a bug with the openvz kernel config/modules.

[root@storm ~]# uname -a
Linux storm.dawn.local 2.6.8-022stab070.1 #1 Mon Feb 20 19:17:39 MSK 2006 i686 athlon i386 GNU/Linux

[root@storm ~]# cat /proc/net/vlan/config
Segmentation fault
[root@storm ~]# dmesg |tail -n 25
eth0.0: add 01:00:5e:00:00:01 mcast address to master interface
loop: loaded (max 8 devices)
Unable to handle kernel paging request at virtual address 10101069
printing eip:
f4beac68
*pde = 00000000
Oops: 0000 [#5]
Modules linked in: loop simfs vznetdev vzdquota vzmon vzdev af_packet ipt_length ipt_ttl ipt_tcpmss ipt_TCPMSS iptable_mangle ipt_multiport ipt_limit ipt_tos ipt_REJECT ip_tables parport_pc lp parport w83627hf eeprom i2c_sensor i2c_isa i2c_viapro i2c_dev i2c_core sunrpc 8021q thermal processor fan button battery asus_acpi ac ohci_hcd ehci_hcd uhci_hcd usbcore pciehp e100 mii floppy ide_cd cdrom
CPU: 0, VCPU: 0:0
EIP: 0060:[<f4beac68>] Not tainted
EFLAGS: 00010206 (2.6.8-022stab070.1)
EIP is at vlan_skip+0x8/0x20 [8021q]
eax: 10101011 ebx: 00000000 ecx: d5aa0f4c edx: 00000001
esi: e364e480 edi: 00000001 ebp: 00000047 esp: d5aa0f34
ds: 007b es: 007b ss: 0068
Process cat (pid: 8366, veid=0, threadinfo=d5aa0000 task=eeb638c0)
Stack: c017e6b1 10101011 00000001 d5aa0f4c e364e498 00000000 00000001 00000000
00000000 00000000 00000000 e191b480 d5aa0fac 00000400 c015fd08 e191b480
0804d858 00000400 d5aa0fac 00000000 00000000 e191b480 fffffff7 00000400
Call Trace:
[<c017e6b1>] seq_read+0x1c1/0x2f0
[<c015fd08>] vfs_read+0xb8/0x130
[<c015ffb1>] sys_read+0x51/0x80
[<c03e8123>] syscall_call+0x7/0xb
Code: f6 40 58 01 75 0f 89 f6 8b 40 28 85 c0 74 06 f6 40 58 01 74

[root@storm ~]# lspci|grep Ethernet
00:06.0 Ethernet controller: Intel Corporation 82557/8/9 [Ethernet Pro 100] (rev 05)
Re: vlan networking problem [message #2278 is a reply to message #2273] Tue, 28 March 2006 07:31 Go to previous message
cleavoy is currently offline  cleavoy
Messages: 3
Registered: March 2006
Junior Member
Well its working now and my source routing problem is fixed too. cat /proc/net/vlan/config no longer seg faults. I suspect it was fixed in either the updates to centos 4.3 (from 4.2) or to openvz kernel 2.6.8-022stab072.2 (from 70.1)

One other thing, if anyone has this problem:

Mar 28 01:47:33 storm ifup: e100 device eth0.0 does not seem to be present, delaying initialization.
Mar 28 01:47:33 storm network: Bringing up interface vlan0: failed

I had to hack /etc/sysconfig/network-scripts/ifup to fix support for vlan id 0. Maybe there is support for vid 0, but for whatever reason its not working with my config. If i do vconfig add eth0 0 then ifup eth0.0 it works fine. But i needed this dirty patch for it to work on startup. Maybe someone with better knowledge of the initscripts can check into this.

Search for,
if [ -n "$VID" ]; then
add this above it,
if [ "$DEVICE" == "eth0.0" ]; then
VID="0"
fi

----
For reference:

[root@storm etc]# grep eth0 modprobe.conf
alias eth0 e100
alias eth0.0 e100
alias eth0.1 e100
alias eth0.2 e100

[root@storm sysconfig]# cat network
NETWORKING=yes
HOSTNAME=storm.dawn.local
VLAN=yes

[root@storm network-scripts]# cat ifcfg-vlan0
DEVICE=eth0.0
IPADDR=192.168.77.2
NETMASK=255.255.255.0
ONBOOT=yes
TYPE=Ethernet
BOOTPROTO=none
USERCTL=no
IPV6INIT=no
PEERDNS=yes

-- Chris
Previous Topic: Missing File
Next Topic: *SOLVED* VPS Reboot
Goto Forum:
  


Current Time: Mon Nov 18 10:18:25 GMT 2024

Total time taken to generate the page: 0.03746 seconds