proxmox vlan
June 26, 2024
If you have a single network interface and want to have your VM's in a VLAN,
modify the /etc/network/interfaces
to look something like:
auto lo
iface lo inet loopback
iface eno1 inet manual
auto vmbr0
iface vmbr0 inet static
address 192.168.0.2/24
gateway 192.168.0.1
bridge-ports eno1
bridge-stp off
bridge-fd 0
auto vmbr1
iface vmbr1 inet manual
bridge-ports eno1.20
bridge-stp off
bridge-fd 0
iface eno1.20 inet manual
vlan-raw-device eno1
source /etc/network/interfaces.d/*
After modifying apply the changes:
systemctl restart networking
In this case, thee is only one interface eno1
and the VLAN-ID is 20