Skip to content

Instantly share code, notes, and snippets.

@mgedmin

mgedmin/interfaces

Created May 11, 2020
Embed
What would you like to do?
/etc/network/interfaces with static IPv6
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address X.X.X.X
pointopoint X.X.X.Y
netmask 255.255.255.255
gateway X.X.X.Y
dns-nameservers A.B.C.D A.B.C.E A.B.C.F
iface eth0 inet6 static
address XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX
netmask 128
post-up /bin/ip -6 route add XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:YYYY dev eth0
post-up /bin/ip -6 route add default via XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:YYYY
pre-down /bin/ip -6 route del default via XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:YYYY
pre-down /bin/ip -6 route del XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:YYYY dev eth0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment