Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 Oct 2018 08:57:16 -0700
From:      =?UTF-8?B?56We5piO6YGU5ZOJ?= <jinmei@wide.ad.jp>
To:        vas@mpeks.tomsk.su
Cc:        asomers@freebsd.org, FreeBSD Net <freebsd-net@freebsd.org>
Subject:   Re: why rtsold ?
Message-ID:  <CAJE_bqcLL9Ywijrw1Nhi14=rLF%2B6LuS0c8bX=_%2BS_v4UVNBkZA@mail.gmail.com>
In-Reply-To: <20181018015314.GA81422@admin.sibptus.ru>
References:  <20180930022007.GA2041@admin.sibptus.ru> <CAOtMX2gDVSmEacBacumPjthNU-RxoxLanjp%2BEhPb=nefX2m5cg@mail.gmail.com> <20181018015314.GA81422@admin.sibptus.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
At Thu, 18 Oct 2018 08:53:14 +0700,
Victor Sudakov <vas@mpeks.tomsk.su> wrote:

> > The router may send a router advertisement whenever it wants.  That's
why
> > your machine seems to work even without rtsold.  However, SLAAC
addresses
> > expire after a certain amount of time.  rtsold will ask the router for a
> > new advertisement before your address expires.
>
> Who actually processes these router advertisements: the rtsold daemon
> or the kernel itself?
>
> Is this passage:
>
> 8.1.1.4. Plug and Play
>
> Most of the IPv6 stateless address autoconfiguration is implemented in
> the kernel. Neighbor Discovery functions are implemented in the kernel
> as a whole. Router Advertisement (RA) input for hosts is implemented
> in the kernel. Router Solicitation (RS) output for endhosts, RS input
> for routers, and RA output for routers are implemented in the
> userland.
>
> still correct?
> (from https://www.freebsd.org/doc/en/books/developers-handbook/ipv6.html)

It's slightly outdated.  "RA input for hosts" was originally limited
to what's described in RFC4862, but it's been extended over time.  The
RFC4862-side (aka SLAAC) is still implemented in the kernel, but DNS
configuration options (RFC8106, although the FreeBSD implementation
may still only conform to RFC6106) are used in the user space.  The
current trend seems to introduce more such high level config
information to RA, so I'd expect these will also be handled in the
user space.

BTW, regarding the original topic of 'why rtsold', my understanding is
that its original motivation is to help hosts moving links.  At least
at the time of development, there was no sophisticated detection
mechanism when a host is connected to a new link, so no one else could
send RS to get new network configuration information.  rtsold monitors
link status and invokes new RS-RA exchanges when it detects a change
of the link status from off to on.  Address lifetime expiration is not
usually an issue since routers are supposed to send RAs periodically
(with sufficiently short intervals to prevent accidental expiration);
and in any case (AFAIK) rtsold doesn't help that situation, as it
doesn't send RSes based on address lifetimes.

Today, we now use DNS config information provided via RA in the user
space, so another role of rtsold is to reflect any changes to it while
the host is still connected to the same link.   Routers are supposed
to advertise RAs with new information, but without rtsold (or
something equivalent) no one in the user space listens to those RAs to
apply the configuration change.

--
JINMEI, Tatuya



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJE_bqcLL9Ywijrw1Nhi14=rLF%2B6LuS0c8bX=_%2BS_v4UVNBkZA>