User Tools

Site Tools


public:managing_networking_on_debian

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
public:managing_networking_on_debian [2024/05/15 18:51] thomaspublic:managing_networking_on_debian [2024/05/16 18:21] (current) – [Setting up VLAN interfaces] thomas
Line 8: Line 8:
  
 This requires the ''bridge-utils'' package. This requires the ''bridge-utils'' package.
 +
 +===== Setting up VLAN interfaces =====
 +
 +In /etc/modules add the line to load the module automatically on startup:
 +<code>
 +8021q
 +</code>
 +
 +Load the module manually for the current session:
 +<code>
 +modprobe 8021q
 +</code>
 +
 +Install VLAN management tools:
 +<code>
 +apt install vlan
 +</code>
 +
 +Now, in ''/etc/network/interfaces'', you can define vlan interfaces as such:
 +
 +<code>
 +auto eth0.222
 +iface eth0.222 inet static
 +        address 10.10.10.1/24
 +        vlan-raw-device eth0
 +</code>
 +
 +The vlan-raw-device parameter is optional, if you use the standard name format (''interface.vlanid''). If you use the alternative naming scheme (vlanXXX), then it must be added to refer to the underlying interface.
 +
 +If you create VLAN interfaces only to put them into a bridge, there is no need to define the VLAN interfaces manually. Just config the bridge, and the VLAN interface will be created automatically when creating the bridge.
 +===== Show overview of active VLANs =====
 +
 +<code>
 +cat /proc/net/vlan/config 
 +VLAN Dev name    | VLAN ID
 +Name-Type: VLAN_NAME_TYPE_RAW_PLUS_VID_NO_PAD
 +enp10s0.2      | 2  | enp10s0
 +enp10s0.6      | 6  | enp10s0
 +</code>
 +
  
 ===== References ===== ===== References =====
  
-  * https://wiki.debian.org/NetworkConfiguration#Howto_use_vlan_.28dot1q.2C_802.1q.2C_trunk.29_.28Etch.2C_Lenny.29+  * https://wiki.debian.org/NetworkConfiguration
public/managing_networking_on_debian.1715799088.txt.gz · Last modified: by thomas

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki