4 Commits

Author SHA1 Message Date
Dietmar Maurer
804e0e388e bridgevlan: cleanup, remove useless case statement 2015-09-16 10:46:29 +02:00
Alexandre Derumier
755325b02c bridgevlan : allow filtering on tagged interfaces
It's possible to create 802.1ad vlan interfaces (for QinQ)
like

ip link add link eth0 eth0.100 type vlan proto 802.1ad id 100

So,we want to be able to use them in bridge vlan aware (802.1q)

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-09-16 10:44:22 +02:00
Dietmar Maurer
ea92d8b613 bridgevlan: avoid bash regex 2015-07-30 11:28:50 +02:00
Alexandre Derumier
1010159a86 add vlan aware ifupdown script v3
This add support to enable vlan aware bridge,
and management interfaces

example: 1 bridge and 1 administration port on vlan 100

auto vmbr0
iface vmbr0 inet manual
        bridge_ports eth0
        bridge_stp off
        bridge_fd 0
        bridge_vlan_aware yes
        bridge_vids 10-15

auto vmbr0.100
iface vmbr0.100 inet static
        address X.X.X.X
        netmask 255.255.255.0
        gateway X.X.X.X

bridge_vids is optional, and allow on the specified vlans.(current take 1 value or range, need to be improve with list)
If not specified, the allowed vlan are 2-4094.
vlan 1 is the default pvid. (all untagged traffic is going to this vlan).

scripts:
- /etc/network/if-up.d/bridgevlan

manage bridge vlan aware configuration

- /etc/network/if-up.d/bridgevlanport

manage bridge vlan admin port

-/etc/network/if-pre-up.d/vlan
-/etc/network/if-post-down.d/vlan

replace current vlan package, without vconfig usage and cleanups
It's only needed to create vlan interface from bridge_ports.

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
2015-07-29 06:46:16 +02:00