≡ Menu

Debian IPv6 Networking Configuration

How do I configure static IPv6 networking under Debian Linux?

You need to add networking configuration to /etc/network/interfaces file as follows:
a) Ipv6 Address

b) Ipv6 Gateway

c) Netmask

Out Sample Debian Linux Ipv6 Configuration

  1. Ipv6 Address IP: 2607:f0d0:2001:000a:0000:0000:0000:0002/64
  2. Ipv6 Gateway IP: 2607:f0d0:2001:000a:0000:0000:0000:0001
  3. Interface name: eth0
  4. IPv6 Type: Static

Open /etc/network/interfaces file, enter:
# vi /etc/network/interfaces
Append configuration as follows:

#IPV6 static configuration
iface eth0 inet6 static
pre-up modprobe ipv6 
address 2607:f0d0:2001:000a:0000:0000:0000:0002
netmask 64
gateway 2607:f0d0:2001:000a:0000:0000:0000:0001
# END IPV6 configuration

Save and close the file. Restart the networking:
# /etc/init.d/networking restart

Verify IPv6 networking

Print your current routing:
# ip -6 route show
Ping Ipv6 enabled website:
# ping6 www.cyberciti.biz
# ping6 ipv6.google.com

Sample output:

PING www.cyberciti.biz(www.cyberciti.biz) 56 data bytes
64 bytes from www.cyberciti.biz: icmp_seq=1 ttl=60 time=65.2 ms
64 bytes from www.cyberciti.biz: icmp_seq=2 ttl=60 time=64.0 ms
64 bytes from www.cyberciti.biz: icmp_seq=3 ttl=60 time=64.0 ms
64 bytes from www.cyberciti.biz: icmp_seq=4 ttl=60 time=64.0 ms
64 bytes from www.cyberciti.biz: icmp_seq=5 ttl=60 time=63.9 ms

See also:

Share this tutorial on:

Like this? Follow us on Twitter OR support us by using Patreon

{ 7 comments… add one }
  • pagan April 6, 2009, 12:01 pm

    the simplest way is just : apt-get install miredo

  • nixCraft April 6, 2009, 5:38 pm


    This is static IPv6 native configuration and not tunneling through NATs.

  • Jeremy April 7, 2009, 1:41 pm

    Even better:
    1. sudo apt-get-install tspc
    2. /etc/init.d/tspc start

    done, now you have tunneled IPv6 connectivity.. It’s not that hard dude..

  • Robert Paats May 17, 2009, 8:37 pm

    It is possible to leave away the 0 in IPv6 addresses in certain cases!
    In that case it is easier to write the addresses as follow :

    1e Address : 2607:f0d0:2001:000a:0000:0000:0000:0002a
    Simplified notation : 2607:f0d0:2001:a::2

    2e Address : 2607:f0d0:2001:000a:0000:0000:0000:0001
    Simplified notation : 2607:f0d0:2001:a::1

  • ondrg January 6, 2011, 4:42 am

    Thanks a lot! This is exactly what i needed :-)

  • Mats March 23, 2012, 10:18 am

    It should be 2607:f0d0:2001:a::2a

  • ZachCheung October 22, 2012, 6:54 pm

    In Debian Squeeze, the line “pre-up modprobe ipv6” should be removed, otherwise it doesn’t work.

Security: Are you a robot or human?

Leave a Comment

You can use these HTML tags and attributes: <strong> <em> <pre> <code> <a href="" title="">

   Tagged with: , , , , , , , , ,