EDIT#2: I think I found the cause of the issue: in /proc/net/vlan/config there is an old entry for vlan620 which links to bond0 (I was trying to do bonding originally) plus an old vlan620 file again tied to bond0. How can these entries be removed since contents of /proc cannot be edited like normal files?
I am trying to use eth0 as 802.1q trunk interface - my configs are as follows:
ifcfg-eth0 # Intel Corporation 82571EB Gigabit Ethernet Controller DEVICE=eth0 #SLAVE=yes #MASTER=bond0 HWADDR=00:1b:21:ac:ae:d2 ONBOOT=yes BOOTPROTO=none TYPE=Ethernet ifcfg-vlan620 #VLAN620 Config VLAN=yes VLAN_NAME_TYPE=VLAN_PLUS_VID_NO_PAD DEVICE=vlan620 PHYSDEV=eth0 BOOTPROTO=static ONBOOT=yes IPADDR=172.16.37.7 NETMASK=255.255.255.224 GATEWAY=172.16.37.1 ifcfg-vlan621 #VLAN621 Configuration VLAN=yes VLAN_NAME_TYPE=VLAN_PLUS_VID_NO_PAD DEVICE=vlan621 PHYSDEV=eth0 BOOTPROTO=static ONBOOT=yes IPADDR=172.16.37.39 NETMASK=255.255.255.224 GATEWAY=172.16.37.33
I then execute 'ifup eth0' then 'ifup vlan620'. The following error occurs when I try to bring up vlan620:
Device vlan620 does not seem to be present, delaying initialization.
However vlan621 can be brought up fine and can be used to access network.
When both interfaces are in down state (ifdown vlan620 and ifdown vlan621) I checked the system for files named vlan620 and vlan621.
find / -name vlan620 /proc/net/vlan/vlan620
A file exists under /proc/net even though interface is down. File contents
eth1 VID: 620 REORDER_HDR: 1 dev->priv_flags: 81 total frames received 1379 total bytes received 69170 Broadcast/Multicast Rcvd 610 total frames transmitted 83 total bytes transmitted 17564 total headroom inc 0 total encap on xmit 0 Device: bond0 INGRESS priority mappings: 0:0 1:0 2:0 3:0 4:0 5:0 6:0 7:0 EGRESSS priority Mappings:
Doing the same lookup for vlan621 returns nothing and the interface works fine. The OS is RHEL5.5 32bit. Can anyone suggest a solution or a cause? Rebooting the system does not clean up the issue.
Note: the bond0 entries are commented out where relevant - I am trying to introduce bonding via eth0 and eth1 in active-backup mode but right now vlans dont work so I am trying to fix one problem at a time.