tech-net archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: PATCH to mark IPv6 addresses DETACHED when down or link down



On Fri, 19 Aug 2016 22:35:02 +0100
Roy Marples <roy%marples.name@localhost> wrote:

> IPv4 addresses now share the same semantics in -current have have
> done for some time. I also agree that something probably needs to be
> done to remedy this.

Hmm this seems like a serious issue.

> There is also the long standing use case, but equally annoying, where
> you cannot bind to an IP address which you know will exist but
> currently doesn't - say for a PPPoE interface where you know you'll
> get a static IP. This is highly annoying for say running a public
> facing DNS server like say nsd which needs to bind to the IP on the
> PPPoE interface. I need to write scripts to restart daemons when ppp
> comes up. This is not nice, and is a bug as you point out.

True, I use an ifup script which among other things restarts named,
even with static IP addresses.

> Do any other OS's try to solve this problem?
> 
> Linux has IP_FREEBIND which allows you to bind to an address if it
> doesn't exist or is tentative (they don't have the concept of
> DETACHED, but the same logic could apply)
> http://man7.org/linux/man-pages/man7/ip.7.html
> 
> FreeBSD has IP_BINDANY and IPV6_BINDANY which seems to do the same
> thing
> https://www.freebsd.org/cgi/man.cgi?query=ip&apropos=0&sektion=4&manpath=FreeBSD+11-current&arch=default&format=html

These appear interesting, but if the daemons need to be modified to
pass a special flag to be able to bind on a detached address, this
would still be an issue with most non-patched software...

> There is also the easier approach of allowing bind(2) to use detached 
> addresses, but that doesn't help the PPPoE case or when the address
> is in the tentative state.

The PPPoE case appears less of an issue to me, because at least it is
understood that the address is not yet available.

-- 
Matt


Home | Main Index | Thread Index | Old Index