This is an example of how you can configure IPv4 and IPv6 static ip-addresses in Debian.
nano /etc/network/interfaces
1 2 3 4 5 6 7 |
auto eth0 iface eth0 inet static address 192.168.3.10 netmask 255.255.255.0 network 192.168.3.0 broadcast 192.168.3.255 gateway 192.168.3.1 |
1 2 3 4 |
iface eth0 inet6 static address fd4e:a32c:3873:9e59:0004::254 gateway fd4e:a32c:3873:9e59:0004::1 netmask 80 |
Use ctrl x to save the configuration.
After the ip configuration change you can reboot the computer, restart the network service or do ifconfig eth0 down and ifconfig eth0 up.
*Important*
Use ping for IPv4 addresses.
Use ping6 for IPv6 addresses.
Er staat een typefoutje in. inetstatic moet inet static zijn.