802.1Q
This page may be outdated or contain incorrect details. Please update it if you can. |
This page describes VLAN tagging (802.1Q) setup between the switches and servers.
Switch
To be written
Server
Using 802.1Q on Fedora is not that hard. First, enable 802.1Q support by putting
VLAN=yes
in /etc/sysconfig/network. Use the exact same casing, or it won't work.
Every VLAN to which the server needs to be connected gets its own virtual interface on top of the real, physical interface. For example, VLAN 2 connected to eth0 becomes eth0.2.
To make use of an interface in VLAN 2, create a file eth0-interfacename in /etc/sysconfig/network-scripts/ as usual. For example:
DEVICE=eth0.2 BOOTPROTO=static IPADDR=10.0.0.14 NETMASK=255.255.0.0 ONBOOT=yes TYPE=Ethernet REORDER_HDR=no
Repeat this for every VLAN the server needs an interface in.
IF no native VLAN is used, i.e. all packets sent by the switch to this interface are tagged, then the physical device does not need to be set up separately, and its configuration should be removed, e.g. /etc/sysconfig/network-scripts/ifcfg-eth0 needs to be deleted.
However, sometimes we are using VLAN tagging for one VLAN, for which a VLAN specific interface is setup using eth0.vlannr, and packets from the native vlan are received by device eth0. In this case, eth0 should be setup as usual. This dirty setup is in use on benet, for example. Please try to avoid this.