Configuring IPV6 Interfaces

FreeBSD

ADDRESS = 2001:618:400:bd9f::2
GATEWAY= fe80::2b0:d0ff:feaa:ad7b
INTERFACE = xl0

 

Add the IPv6 address for the interface

ifconfig xl0 inet6 add 2001:918:fffc:12:1::2 prefixlen 64

Remove IPv6 address from the interface

ifconfig xl0 inet6 2001:918:fffc:12:1::10 prefixlen 64 delete

Autoconfiguration on/off

sysctl net.inet6.ip6.accept_rtadv=1
sysctl net.inet6.ip6.accept_rtadv=0

Add specific route to host

route add -inet6 2001:800:40::1 fe80::209:c0ff:fe30:4357%xl0

Add specific route to network

route add -inet6 2001:800:40::/48 fe80::209:c0ff:fe30:4357%xl0

Remove specific route

route delete -inet6 2001:800:40::/48 fe80::209:c0ff:fe30:4357%xl0

Add default IPv6 route

route add -inet6 ::/0 fe80::209:c0ff:fe30:4357%xl0

Remove default IPv6 route

route delete -inet6 ::/0 fe80::209:c0ff:fe30:4357%xl0

Display current routing table

netstat -r
netstat -nr (no address-to-name resolution)

Display current interface configuration

ifconfig
ifconfig -a (for all interfaces, also inactive)


WindowsXP/Windows Server 2003

ADDRESS = 2001:618:400:bd9f::2
GATEWAY= fe80::2b0:d0ff:feaa:ad7b
INTERFACE = Local Area Connection

 

Add the IPv6 address for the interface

netsh interface ipv6 set address "Local Area Connection" 2001:618:400:bd9f::200

Remove IPv6 address from the interface

netsh interface ipv6 delete address "Local Area Connection" 2001:618:400:bd9f::200

Enable IPv6

Netsh interface ipv6 install

Disable IPv6

Netsh interface ipv6 uninstall

Add specific route to host

netsh interface ipv6 add route 2001:618:400:bd9f::/64 "Local Area Connection"

Add specific route to network

netsh interface ipv6 add route 2001:618:400:bd9f::/64 "Local Area Connection"

Remove specific route

netsh interface ipv6 delete route 2001:618:400:bd9f::/64 "Local Area Connection"

Add default IPv6 route

netsh interface ipv6 add route ::/0 "Local Area Connection" fe80::2b0:d0ff:feaa:ad7b

Remove default IPv6 route

netsh interface ipv6 delete route ::/0 "Local Area Connection" fe80::2b0:d0ff:feaa:ad7b

Establish v6-in-v4 tunnel

netsh interface ipv6 add v6v4tunnel "Local Area Connection" <local IPv4 Adress> <Remote IPv4 Adress>

netsh interface ipv6 add address "<Tunnel-Name>" \\
      <IPv6-Adress>

netsh interface ipv6 add route
      <Route-prefix>/<length of prefix> \\
      "Tunnel-Name" <remote IPv6 addres s (next Hop)>

(Not tested)

Display current routing table

netsh interface ipv6 show route

Display current interface configuration

Ipconfig

IPv6 Firewall disable

Netsh firewall set adapter "Local Area Connection" filter=disable

IPv6 Firewall enable

Netsh firewall set adapter "Local Area Connection" filter= enable

Check connectivity

Ping www.kame.net
Ping6 www.kame.net

Trace route

Tracert www.kame.net
Tracert6 www.kame.net

Disable IPv6 privacy addresses

netsh interface ipv6 set privacy disabled

Enable IPv6 privacy addresses

netsh interface ipv6 set privacy enabled


Linux

ADDRESS = 2001:618:400:bd9f::2 prefixlen 64
GATEWAY= fe80::2b0:d0ff:feaa:ad7b
INTERFACE = eth0

 

Add the IPv6 address for the interface

ifconfig eth0 add 2001:618:400:bd9f::2/64

Remove IPv6 address from the interface

ifconfig eth0 del 2001:618:400:bd9f::2/64

Autoconfiguration on

echo "1" > /proc/sys/net/ipv6/conf/eth0/accept_ra

echo "1" > /proc/sys/net/ipv6/conf/eth0/autoconf

Autoconfiguration off

echo "0" > /proc/sys/net/ipv6/conf/eth0/accept_ra

echo "0" > /proc/sys/net/ipv6/conf/eth0/autoconf

Enable IPv6

compile kernel with IPv6 support

or

modprobe ipv6 (if compiled as module)

Add specific route to host

route .A inet6 add 2001:618:400:bd9f::1 gw fe80::2b0:d0ff:feaa:ad7b dev eth0

Add specific route to network

route .A inet6 add 2001:800:40::/48 gw fe80::2b0:d0ff:feaa:ad7b dev eth0

Remove specific route

route .A inet6 del 2001:800:40::1 gw fe80::2b0:d0ff:feaa:ad7b dev eth0

Add default IPv6 route

route .A inet6 add ::/0 gw fe80::2b0:d0ff:feaa:ad7b dev eth0

Remove default IPv6 route

route .A inet6 del ::/0 fe80::2b0:d0ff:feaa:ad7b dev eth0

Display current routing table

netstat .nr .A inet6
netstat .r .A inet6 (with reverse name resolution)

Display current interface configuration

ifconfig

Check connectivity

ping6 www.kame.net

Trace route

traceroute6 www.kame.net

 

Support . Contact 3Segment . Network . Site Map . Policies