Skip to content

Instantly share code, notes, and snippets.

@KrustyHack
Created November 13, 2018 14:16
Show Gist options
  • Save KrustyHack/604f4ea2a1ae81aabef81d4a1800f2df to your computer and use it in GitHub Desktop.
Save KrustyHack/604f4ea2a1ae81aabef81d4a1800f2df to your computer and use it in GitHub Desktop.
ip link add link enp2s0 name enp2s0.4000 type vlan id 4000
ip link set enp2s0.4000 mtu 1400
ip link set dev enp2s0.4000 up
ip addr add 192.168.100.1/24 brd 192.168.100.255 dev enp2s0.4000
auto enp2s0.4000
iface enp2s0.4000 inet static
address 192.168.100.1
netmask 255.255.255.0
vlan-raw-device enp2s0
mtu 1400
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment