Enabling IPv6 on your FreeBSD VPS

Enabling IPv6 on your FreeBSD VPS is simple.

For stateless autoconfig, just add the one of following line to your /etc/rc.conf and reboot your VPS. Your VPS will automatically configure an IPv6 address on boot:

For FreeBSD 10.x: ifconfig_xn0_ipv6="inet6 accept_rtadv"

For FreeBSD 9.x: ifconfig_em0_ipv6="inet6 accept_rtadv"
 
For FreeBSD 8.x: ipv6_enable="YES"

 

To statically configure your IPv6 address, follow this procedure:

Find your IPv6 /64 prefix, which is in your RootBSD control panel under My Services -> [Server/Instance] -> Network. It will be your IPv6 gateway sans ::1. For example, if your IPv6 gateway is 2607:FC50:FFFF:FFFF::1, your /64 prefix is 2607:FC50:FFFF:FFFF.

Since you have a /64 prefix, based on our example, you can use any address from 2607:FC50:FFFF:FFFF:0000:0000:0000:0002 -  2607:FC50:FFFF:FFFF:FFFF:FFFF:FFFF:FFFE (That's 18446744073709551999 IPs!)

If you wanted to use the IPv6 address 2607:FC50:FFFF:FFFF:0000:0000:0000:0002 (2607:FC50:FFFF:FFFF::2 condensed) you would add the following to /etc/rc.conf and reboot your VPS:

For FreeBSD 10.x,

 

ipv6_activate_all_interfaces="YES"

ifconfig_xn0_ipv6="inet6 2607:FC50:FFFF:FFFF::2" # THIS IS ONLY AN EXAMPLE; USE YOUR PREFIX!

ipv6_defaultrouter="2607:FC50:FFFF:FFFF::1" # THIS IS ONLY AN EXAMPLE; USE YOUR PREFIX!

 

For FreeBSD 9.x,

 

ipv6_activate_all_interfaces="YES"

ifconfig_em0_ipv6="inet6 2607:FC50:FFFF:FFFF::2" # THIS IS ONLY AN EXAMPLE; USE YOUR PREFIX!

ipv6_defaultrouter="2607:FC50:FFFF:FFFF::1" # THIS IS ONLY AN EXAMPLE; USE YOUR PREFIX!

 

For FreeBSD 8.x,

ipv6_enable="YES"

ipv6_ifconfig_em0="2607:FC50:FFFF:FFFF::2" # THIS IS ONLY AN EXAMPLE; USE YOUR PREFIX!

ipv6_defaultrouter="2607:FC50:FFFF:FFFF::1" # THIS IS ONLY AN EXAMPLE; USE YOUR PREFIX!

 

*NOTE: If you have a Realtek NIC, you will need to use re0 instead of em0

 

For more information, please refer to the FreeBSD Handbook: http://www5.us.freebsd.org/doc/handbook/network-ipv6.html

Instantly deploy a BSD cloud VPS with RootBSD

deploy instantly

  • Fast SSD hosting
  • Full root access
  • IPv6 and IPv4 enabled hosting
  • Over 25 data center locations worldwide
  • Friendly and knowledgeable support
  • Build with current FreeBSD, OpenBSD, NetBSD, Linux releases