2

So you can configure eth0 with vlan100:

VLAN=yes
VLAN_NAME_TYPE=VLAN_PLUS_VID_NO_PAD
DEVICE=vlan100
PHYSDEV=eth0
BOOTPROTO=static
ONBOOT=yes
TYPE=Ethernet
IPADDR=10.10.10.1
NETMASK=255.255.255.0

Now the interface will see traffic tagged with vlan 100.

I can configure Centos to forward vlan100 packets to where ever.

Now suppose I have multiple private vlans inside of vlan 100?

Vlan 103, vlan 104.

How would I get the interface to see the private vlans?

Dre_Dre
  • 153
  • 1
  • 6

1 Answers1

4

You want 802.1q tunneling, or QinQ. See this:

http://www.microhowto.info/howto/configure_an_ethernet_interface_as_a_qinq_vlan_trunk.html

ip link add link eth0 eth0.100 type vlan proto 802.1ad id 100
ip link add link eth0.100 eth0.100.103 type vlan proto 802.1Q id 103
ip link set eth0 up
ip link set eth0.100 up
Erik
  • 56
  • 2