You are not logged in.

#1 2016-06-15 09:26:11

olive
Member
From: Belgium
Registered: 2008-06-22
Posts: 1,490

ipv6 configuration

I am confused about ipv6 SLAAC. Quoted from the wiki:

The easiest way to acquire an IPv6 address as long as your network is configured is through Stateless address autoconfiguration (SLAAC for short). The address is automatically inferred from the prefix that your router advertises and requires neither further configuration nor specialized software such as a DHCP client.

But what does means "as long as your network is configured"? How do I configure it? Almost anything I can find on the web speaks about configuration files that depend on the distribution and are presumably read from scripts (or systemd?). But how is it configured at the lowest level? For ipv4, things are clear: you either configure it manually and statically with ifconfig/ip that directly interface with the kernel or you use dhcpcd/dhclient which configure the network from a broadcast message sent by the router on the local loop. Network manager and other high level software are just GUI wrapper on these two notions.

But what for ipv6? Is the wiki saying that as long as the kernel has the physical driver for the network interface, it will auto-configure the network (which would mean that somehow the equivalent of dhcpcd is integrated in the kernel?). But then, how tools like dhcpcd that still exist for ipv6, can configure it with more subtle configurations (privacy extension, etc.) if the kernel does everything once it is booted? I am really confused about what's going on here.

Note that I have no ipv6 on this machine right now to test (but I occasionally came across a machine connected to a ipv6 capable router).

Last edited by olive (2016-06-15 09:36:46)

Offline

#2 2016-07-06 08:42:41

severach
Member
Registered: 2015-05-23
Posts: 192

Re: ipv6 configuration

SLAAC and DHCPv6 are both directed by the router. For DHCPv6 the address is provided by the router. For SLAAC the router is broadcasting permission for the clients to generate their own addresses using the supplied prefix. Without an IPv6 router telling the clients what they are to use you'll get nothing. All you'll have is your FE80 link local address which is what you need to talk to your IPv6 enabled devices and printers. Public IPs are worthless without a router to send them to.

Routers supplied by AT&T and Comcast have SLAAC turned on. On a SLAAC broadcast your IPv6 stack might generate an additional Privacy Extensions address.

It is confusing because IPv6 is so different than IPv4. IPv4 was all client directed so the old simple tools could get an address once and quit, either by dhcp or by hand. This won't work with IPv6. The router can revoke DHCPv6 or SLAAC at any time, the kernel could drop or reset your address when the link goes down, and multiple IPv6 routers can be active at the same time. For full IPv6 functionality you should use a managed network tool like NetworkManager or systemd-networkd which configures the interfaces and starts a daemon to watch for changes. The kernel moves the packets. The IPv6 management is done by the daemon. IPv6 made the client side a lot more complicated so they can't be just a GUI any more.

Static public IP is not an option until your ISP provides a static prefix or you want to run NATv6 and lose all the advantages of IPv6 PD. I have not yet found a way to assign a static link local that sticks.

I use NetworkManager because it supports wifi and provides a unified CLI, TUI, and GUI. It only takes a few minutes to set up all your network cards on CLI servers or GUI desktops. For servers I configure my IPv4 and VLAN as static and IPv6 as automatic. systemd-networkd works but isn't as feature complete.

I deployed IPv6 as an adjunct separate router to existing IPv4 infrastructure. This lets me learn how IPv6 works and if problems arise I can take it down immediately during production without affecting any IPv4 routers or connectivity. All that disappears is the non critical IPv6 connectivity. Deployment has been amazingly trouble free.

Offline

#3 2016-07-06 10:49:29

olive
Member
From: Belgium
Registered: 2008-06-22
Posts: 1,490

Re: ipv6 configuration

@severach. Thanks for your answer. What still a little confuse me is what does what. The wiki seems to say that the kernel could be able to manage it by itself (at least for a basic configuration). On the other hand, and your answer implies that, there are daemons for more advanced configuration. I am right to understand that if I have a correctly configured router, the kernel will give me a working connection as long as the interface is up? If this is correct, how to kernel part does not come in conflict with all of these daemons? Does the daemons somehow disable the kernel functionality to manage it themselves?

Note that my question is more to understand the logic than to have a working configuration. Normally, I expect indeed Network Manager to do all the hard things for me. But I am frustrated to not understand what it really does.

Offline

#4 2016-07-06 12:00:49

progandy
Member
Registered: 2012-05-17
Posts: 5,190

Re: ipv6 configuration

AFAIK the kernel manages SLAAC out of the box. If you need DHCPv6, then a dhcp client is required.
SLAAC is configured with "sysctl" in the tree "net.ipv6"
http://www.tldp.org/HOWTO/Linux+IPv6-HO … ipv6..html


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

Board footer

Powered by FluxBB