Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

What linux DHCPv6 client can I set up so it requests a prefix on one interface and then on all the other interfaces it will give out addresses (or if requested, a smaller prefix delegation)? It would also need to set up the routes and router advertisements.

If there's not a way to do this, what is the IPv6 version of programming an IPv4 router to do NAT, wherever it is put? Basically, I'm trying to understand how a manufacturer would set up their IPv6 capable routers so a customer can plug them in and they would work. I'm not talking about actual NAT in IPv6, but a way for a router to have a DHCPv6 prefix delegation client which would take the prefix it received and break it into smaller prefixes and addresses and run a DHCPv6 server for each separate downstream link.

I added a diagram:

Diagram with 9 computers. #2, #4, #6, #7, and #9 are DHCPv6 clients. #1 is assigned 2001:db8:1200::/40 and giving out /48 prefix delegations. #3, #5, and #8 are DHCPv6 servers and clients at the same time as they are requesting prefixes.

Is there (a) piece(s) of software I can run on Linux that could be configured once and then put in place number 3, 5, or 8 and it would automatically set itself up depending on the prefix it was delegated?

share|improve this question
add comment

2 Answers

The program that does prefix delegation is radvd (Router Advertisement Daemon). Other IPv6 hosts on the link should automatically configure a globally routeable address from the announced prefix.

IPv6 does not require NAT as hosts which require Internet access are expected to have globally routeable addresses. You need to be careful in your Firewall rules to prevent infiltration from the Internet.

ISPs are expected to give out a /48 or /56 network block to their customers. This requires a bit of smarts on the ISP side to ensure each router gets a unique block. One /64 block will likely be used as the uplink to the IPS's network. The router is then free to announce as many /64s as from the rest of the block as it wishes. Likely only one would be used in this scenario.

There is an IPv6 DHCP implementation as well.

One quick setup which has been done is to configure the router to use 6to4 tunneling. radvd will autoconfigure for this setup, but it requires a publicly routeable IPv4 address.

EDIT: While radvd can't subdelegate prefixes it can automatically announce a /64 prefix based on an available routeable addresses. It also has Base6to4 to automatically announce the 6to4 prefix of the router. Subdelegation requires some planning and is beyond what should be expected of a plug and play configuration.

EDIT2: Like IPv4 IPv6 does not have a method to determine which network belongs on the networks connected to eth1 or eth2 base on the address assigned to the eth0 interface. Once you have multiple network segments you need to begin managing the addresses assigned to each segment. The good news is this can usually be done once.

IPv6 makes it easier as 5 and 8 can easily be given /49 or /50 subnets of the /48 delegated to 3. An alternate approach would be to configure 3, 5, and 8 as bridges on the same /64 subnet. In such a configuration, they would work as switches. Automatic subnet generation risk routers 5 and 8 both choosing to delegate the same subnet.

Plug and pray routers for home use just use a default private address block. They quickly break down when configured as shown in your diagram. Mixing routers with different default address blocks may work. Otherwise you need to ensure each router has different block of addresses.

share|improve this answer
    
I'm pretty sure radvd can't do Prefix delegation, at least not by itself. It has to be configured to have a flag that points to using DHCPv6 and then the DHCPv6 server can delegate prefixes. I'm looking for software that can request a prefix delegation and then subdelegate that, including smaller prefix delegations. –  Azendale Jan 1 '12 at 22:04
    
In reply to edit: With IPv4 a consumer can plug in a router and connect computers through it. IPv4 uses NAT to do this. How does an IPv6 router do this? Doesn't it need a block of addresses to assign to its downstream? My question is looking for software that asks for a block of addresses and then assigns that to the downstream, whether that downstream is clients or another router with more clients behind it. –  Azendale Jan 2 '12 at 1:28
    
So, I guess the one situation I saw of NAT behind NAT was a case of lucky. I guess this is an opportunity for IPv6 to do better than IPv4. From asking this question at tunnelbroker.net/forums/index.php?topic=2212.0 , it is apparent that what I'm asking can be done while still following protocol. So I'm still looking for software to do what I want. –  Azendale Jan 3 '12 at 2:58
add comment

Looks like you need a routing protocol such as RIPng. You could install quagga on those boxes, configure the interfaces that need the routing protocol (once) and off you go.

share|improve this answer
add comment

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.