Guest User!

You are not Sophos Staff.

Wrong VLAN Behaviour

why are we allowed to define multiple VLANs for same hardware with same VLAN tag ?

This is annoying... and on the console only the last one show up of course...

You need to check and forbid this...
Parents Reply Children
  • For clarity, can you please install a debug kernel there, redo your test and send me the output of 'dmesg'?.  The kernel is available from

    http://www.astaromail.com/people/heitzenberger/v7/kernel/debug/kernel-default-2.6.16.60-65vl1.i686.rpm

    Please install via 'rpm -i kernel-default-2.6.16.60-65vl1.i686.rpm' and the do a reboot.


    Ok So I've installed your RPM

    Here is the results:

    First I've only eth2 active which is my admin iface:


    asg1:/root # ifconfig 
    eth2      Link encap:Ethernet  HWaddr 00:16:3E:5A:AF:1C  
              inet addr:192.168.9.251  Bcast:192.168.9.255  Mask:255.255.255.0
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:1367 errors:0 dropped:0 overruns:0 frame:0
              TX packets:1783 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:204128 (199.3 Kb)  TX bytes:1869839 (1.7 Mb)
              Interrupt:193 Base address:0x6200 

    lo        Link encap:Local Loopback  
              inet addr:127.0.0.1  Mask:255.0.0.0
              UP LOOPBACK RUNNING  MTU:16436  Metric:1
              RX packets:77486 errors:0 dropped:0 overruns:0 frame:0
              TX packets:77486 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:0 
              RX bytes:21337035 (20.3 Mb)  TX bytes:21337035 (20.3 Mb)


    And I want to set up vlan 101 for eth1, which is initially down


    asg1:/root # ethtool eth1
    Settings for eth1:
            Supported ports: [ TP MII ]
            Supported link modes:   10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
            Supports auto-negotiation: Yes
            Advertised link modes:  10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
            Advertised auto-negotiation: Yes
            Speed: 100Mb/s
            Duplex: Full
            Port: MII
            PHYAD: 32
            Transceiver: internal
            Auto-negotiation: on
            Supports Wake-on: pumbg
            Wake-on: d
            Current message level: 0x00000007 (7)
            Link detected: no


    I then enable the vlan 101 for eth1
    and dmesg gives:


    asg1:/root # dmesg -c
    eth1: link up, 100Mbps, full-duplex, lpa 0x05E1
    802.1Q VLAN Support v1.8 Ben Greear 
    All bugs added by David S. Miller 
    vlan_ioctl_handler: args.cmd: 0
    register_vlan_device: if_name -:eth1:-  vid: 101
    About to allocate name, vlan_name_type: 3
    Allocated new name -:eth1.101:-
    About to go find the group for idx: 3
    Allocated new device successfully, returning.
    eth1.101: add 01:00:5e:00:00:01 mcast address to master interface
    net_enable_timestamp [named]: netstamp_needed=4


    An ifconfig gives:


    asg1:/root # ifconfig 
    eth1      Link encap:Ethernet  HWaddr 00:16:3E:5A:AF:1B  
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:2 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:0 (0.0 b)  TX bytes:84 (84.0 b)
              Interrupt:185 Base address:0x4100 

    eth1.101  Link encap:Ethernet  HWaddr 00:16:3E:5A:AF:1B  
              inet addr:1.2.3.4  Bcast:1.2.3.255  Mask:255.255.255.0
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:0 
              RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

    eth2      Link encap:Ethernet  HWaddr 00:16:3E:5A:AF:1C  
              inet addr:192.168.9.251  Bcast:192.168.9.255  Mask:255.255.255.0
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:1476 errors:0 dropped:0 overruns:0 frame:0
              TX packets:1857 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:218342 (213.2 Kb)  TX bytes:1888271 (1.8 Mb)
              Interrupt:193 Base address:0x6200 

    lo        Link encap:Local Loopback  
              inet addr:127.0.0.1  Mask:255.0.0.0
              UP LOOPBACK RUNNING  MTU:16436  Metric:1
              RX packets:79345 errors:0 dropped:0 overruns:0 frame:0
              TX packets:79345 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:0 
              RX bytes:21994099 (20.9 Mb)  TX bytes:21994099 (20.9 Mb)


    eth1 is up and link status ok:


    asg1:/root # ethtool eth1
    Settings for eth1:
            Supported ports: [ TP MII ]
            Supported link modes:   10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
            Supports auto-negotiation: Yes
            Advertised link modes:  10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
            Advertised auto-negotiation: Yes
            Speed: 100Mb/s
            Duplex: Full
            Port: MII
            PHYAD: 32
            Transceiver: internal
            Auto-negotiation: on
            Supports Wake-on: pumbg
            Wake-on: d
            Current message level: 0x00000007 (7)
            Link detected: yes
    asg1:/root # ethtool eth1.101
    Settings for eth1.101:
            Supported ports: [ TP MII ]
            Supported link modes:   10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
            Supports auto-negotiation: Yes
            Advertised link modes:  10baseT/Half 10baseT/Full 
                                    100baseT/Half 100baseT/Full 
            Advertised auto-negotiation: Yes
            Speed: 100Mb/s
            Duplex: Full
            Port: MII
            PHYAD: 32
            Transceiver: internal
            Auto-negotiation: on
            Supports Wake-on: pumbg
            Wake-on: d
            Current message level: 0x00000007 (7)
            Link detected: yes


    Now adding a second vlan with same vlan id 101 for eth1 with different ip:


    asg1:/root # dmesg -c
    vlan_ioctl_handler: args.cmd: 0
    register_vlan_device: if_name -:eth1:-  vid: 101
    register_vlan_device: ALREADY had VLAN registered
    net_enable_timestamp [named]: netstamp_needed=5


    and ip still from the first one..


    asg1:/root # ifconfig 
    eth1      Link encap:Ethernet  HWaddr 00:16:3E:5A:AF:1B  
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:6 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:0 (0.0 b)  TX bytes:252 (252.0 b)
              Interrupt:185 Base address:0x4100 

    eth1.101  Link encap:Ethernet  HWaddr 00:16:3E:5A:AF:1B  
              inet addr:1.2.3.4  Bcast:1.2.3.255  Mask:255.255.255.0
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:0 errors:0 dropped:0 overruns:0 frame:0
              TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:0 
              RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

    eth2      Link encap:Ethernet  HWaddr 00:16:3E:5A:AF:1C  
              inet addr:192.168.9.251  Bcast:192.168.9.255  Mask:255.255.255.0
              UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
              RX packets:1606 errors:0 dropped:0 overruns:0 frame:0
              TX packets:1960 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:1000 
              RX bytes:232657 (227.2 Kb)  TX bytes:1921572 (1.8 Mb)
              Interrupt:193 Base address:0x6200 

    lo        Link encap:Local Loopback  
              inet addr:127.0.0.1  Mask:255.0.0.0
              UP LOOPBACK RUNNING  MTU:16436  Metric:1
              RX packets:80708 errors:0 dropped:0 overruns:0 frame:0
              TX packets:80708 errors:0 dropped:0 overruns:0 carrier:0
              collisions:0 txqueuelen:0 
              RX bytes:22627866 (21.5 Mb)  TX bytes:22627866 (21.5 Mb)



    Hope this will help...

    and CPU is 92% on that test box... and I've nothing active except vlans [:(]
    I've no PF rules, no nat, no IPS, no anti-virus, no web proxy... nothing...


      PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND                                                                                                  
     3070 root      25   0 21544  18m 2972 R 43.2  4.9   3:21.85 mdw_daemon.plx                                                                                           
    32309 root      15   0 30720  15m 2084 S 14.0  4.1   0:00.43 confd.plx                                                                                                
     2710 root      15   0 30764  17m 3784 S  2.3  4.5   0:07.17 confd.plx                                                                                                
    32475 root      17   0  7272 4408 1796 R  1.6  1.1   0:00.05 websec-reporter                                                                                          
    32480 root      17   0  6432 4536 1676 R  1.6  1.2   0:00.05 admin-reporter.                                                                                          
    32302 root      16   0  9752 7164 2812 R  0.6  1.9   0:00.09 pfilter-reporte                                                                                          
    32476 root      17   0  4520 2864 1548 R  0.6  0.7   0:00.02 mailsec-reporte                                                                                          
    32477 root      16   0  4648 2932 1548 R  0.6  0.8   0:00.02 vpn-reporter.pl