Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

IPv6 prefix length hint option for interfaces file?

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
tllewell55
Posts: 3
Joined: 2019-08-08 00:44

IPv6 prefix length hint option for interfaces file?

#1 Post by tllewell55 »

I am setting up IPv6 to be routed by a Debian 10 box. Currently I am trying to get /etc/network/interfaces to set up the upstream link to my ISP. So far I have:

Code: Select all

# WAN interface
allow-hotplug enp1s0
iface enp1s0 inet6 dhcp
        accept_ra 2
        request_prefix 1
This gets me a /64, which doesn't allow me to subnet and use EUI-64 addresses downstream (this is for a lab setup, so I can tolerate having everything blown away when the prefix changes). It doesn't look like the man page for the interfaces file has been updated since dhclient 4.4 came out, so maybe the option for the prefix length hint hasn't shown up yet. Or is there one, yet?
I could just subnet the /64 or use the command line and try to get a shorter prefix, but it would be nice to have one more obscure option for the interfaces file, wouldn't it? ;-)

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 133 times

Re: IPv6 prefix length hint option for interfaces file?

#2 Post by Head_on_a_Stick »

I don't have any experience with IPv6 but it looks like systemd-networkd may be able to do what you want, see systemd.network(5).
deadbang

tllewell55
Posts: 3
Joined: 2019-08-08 00:44

Re: IPv6 prefix length hint option for interfaces file?

#3 Post by tllewell55 »

Thanks for the reply, Head_on_a_Stick, but I'm not sure about that. What I don't see is a clear way to assign the received prefix to the interior (LAN) port. Perhaps the OtherInformation= item in [IPv6PrefixDelegation] is supposed to do this, but if so it's not very clear that's the case. And if so, that would be for the normal use case where you were simply trying to delegate the prefix, which is not exactly what I am trying to do.

Anyway, I've been trying to get something other than a /64. I've been issuing command lines like "sudo dhclient -P --address-prefix-len 60 -N enp1s0" and according to the packet traces I'm getting I'm still sending requests for a /64. So I don't know if my ISP would give me a shorter prefix if I asked for one. If I'm going to do that it doesn't look like Debian's stock ISC 4.4 dhclient is going to do it. Am I doing something wrong? I am getting leases.

However, it occurs to me that I could route to my lab environment with link local addresses and assign the prefix I got at the LAN interface where my lab's end systems live. And I can always chop up the /64 when I feel rested enough to tackle subnetting in hex numbers.

tllewell55
Posts: 3
Joined: 2019-08-08 00:44

Re: IPv6 prefix length hint option for interfaces file?

#4 Post by tllewell55 »

Well, it actually does work. You just have to specify the option correctly, because it fails silently if you don't. Argh, another umpteen hours troubleshooting operator error that I won't get back.

It'd still be nice to have an option for the interfaces file.

Post Reply