Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I can get the ipv4 address using dhcp,But can't get the ipv6 address.

the dhcp server also support the ipv6 service.
ifconfig eth0

eth0      Link encap:Ethernet  HWaddr: 00:21:85:d3:a3:36  
          inet addr:10.16.31.183  broadcast:10.16.31.255  netmask:255.255.255.0
          inet6 addr: fe80::221:85ff:fed3:a336/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

Other configurations about ipv6:
pwd:/proc/sys/net/ipv6/conf/all

disable_ipv6 = 0;  
forwarding = 1;  
autoconf =  1;

Is there any solution for solving this problem?

share|improve this question
    
Are you trying to connect to an network that is IPv6 enabled? Also, are you on a Desktop install or a Command line only install? –  Azendale May 27 '11 at 0:12

2 Answers 2

From the output of ifconfig, it appears that IPv6 is not enabled on that interface.

There's two ways to automatically get IPv6 addresses on a network:

  • Autoconfiguration (common, supported by nearly everything IPv6 compatible), &
  • DHCPv6 (rarer, not supported by Mac OS X, just got easy support in Natty, it required config files before Natty)

Autoconfiguration will automatically get an address from a router running on the network that is running a daemon such as radvd. I would assume that autoconf=1 enables it. However, you cannot do IP forwarding on an interface that you have an autoconfigured address on. So forwarding=1 is probably turning getting addresses via autoconfiguration off.

share|improve this answer

IPv6 addresses are not distributed via DHCP. But you can install radvd which distributes IPv6 addresses and also handles the routing if required. After installing via apt-get install radvd you can find example configuration files in /usr/share/doc/radvd/examples/

Also read /usr/share/doc/radvd/README.Debian.

share|improve this answer
2  
IPv6 addresses can be distributed by DHCP version 6. (There is two ways of distributing addresses; see my answer) The dhcpv6 client is in Natty. Also, installing radvd will only give IPV6 addresses to the rest of the network. Getting autoconf to work would make it possible to have an IPv6 address and service if the network has IPv6 access. –  Azendale May 27 '11 at 0:11

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.