IPv6: "xxx::x already configured" in logs... why?

Hiroki Sato hrs at FreeBSD.org
Thu Mar 30 04:12:45 UTC 2017


Lawrence Stewart <lstewart at freebsd.org> wrote
  in <56d1a947-a0a1-0297-7151-4e36ab53cff1 at freebsd.org>:

ls> On 29/03/2017 21:49, Rui Paulo wrote:
ls> > On Wed, 2017-03-29 at 21:46 -0500, Lawrence Stewart wrote:
ls> >> [resurrecting an old thread]
ls> >>
ls> >> On 19/06/2014 23:08, Hiroki Sato wrote:
ls> >>> Larry Rosenman <ler at lerctr.org> wrote
ls> >>>   in <20140619140801.GA65420 at thebighonker.lerctr.org>:
ls> >>>
ls> >>> le> > le> Ideas? (I may be an idiot, so any criticism welcomed).
ls> >>> le> > le>
ls> >>> le> > le> if you need the 1841's config, I can supply that as
ls> >>> well.  It's using a Hurricane
ls> >>> le> > le> electric Tunnel.
ls> >>> le> >
ls> >>> le> >  How frequent were the log message added into
ls> >>> /var/log/messages?  And
ls> >>> le> >  when did it start to happen after boot.  Just after lagg0 is
ls> >>> le> >  configured?
ls> >>> le> >
ls> >>> le> > -- Hiroki
ls> >>> le> Looks like:
ls> >>> le>
ls> >>> le> Jun 12 07:00:01 thebighonker kernel: in6_ifadd:
ls> >>> 2001:470:1f0f:3ad:223:7dff:fe9e:6e8a is already configured
ls> >>>
ls> >>>  Thank you.  Three more questions:
ls> >>>
ls> >>>  1. output of "ifconfig lagg0", "ifconfig bce0", and "ifconfig
ls> >>> bce1".
ls> >>>
ls> >>>  2. output of "netstat -s -i".
ls> >>>
ls> >>>  3. output of "ndp -p".
ls> >>>
ls> >>>  The cause of the message is that the automatically-configured
ls> >>> address
ls> >>>  is not recognized as "configured" one and FreeBSD IPv6 stack is
ls> >>>  trying to add it every time a Router Advertisement message is
ls> >>>  received.  I am still not sure why it happened, but the above
ls> >>> three
ls> >>>  would help for further investigation.
ls> >>
ls> >> I've recently set up a VPS with v6 and am seeing the same "in6_ifadd:
ls> >> <v6_addr> is already configured" messages in response to periodically
ls> >> received router advertisements every 5-10 mins. The host is a KVM-
ls> >> based
ls> >> virtual machine with vtnet-based NIC. v6 is fully functional with the
ls> >> statically assigned v6 address, but the spam in /var/log/messages is
ls> >> annoying.
ls> >>
ls> >>
ls> >> FreeBSD revision:
ls> >>   FreeBSD lauren 12.0-CURRENT FreeBSD 12.0-CURRENT #0 r315059: Sun
ls> >> Mar
ls> >> 12 20:44:50 AEDT 2017
ls> >> root at builder-head-amd64:/usr/obj/lauren/usr/src/sys/GENERIC-
ls> >> NODEBUG  amd64
ls> >>
ls> >>
ls> >> Relevant bits from /etc/rc.conf:
ls> >>   rtsold_enable="YES"
ls> >>   ipv6_activate_all_interfaces="YES"
ls> >>   rtsold_flags="-aF"
ls> >>   ifconfig_vtnet0_ipv6="inet6 <v6_addr> prefixlen 64"
ls> >>
ls> >>
ls> >> Interface:
ls> >>   vtnet0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0
ls> >> mtu 1500
ls> >>
ls> >> options=6c07bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_H
ls> >> WCSUM,TSO4,TSO6,LRO,VLAN_HWTSO,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
ls> >>         ether <mac>
ls> >>         inet <v4_addr> netmask 0xfffffe00 broadcast <v4_bcast>
ls> >>         inet6 <v6_linklocal>%vtnet0 prefixlen 64 scopeid 0x1
ls> >>         inet6 <v6_addr> prefixlen 64
ls> >>         nd6 options=23<PERFORMNUD,ACCEPT_RTADV,AUTO_LINKLOCAL>
ls> >>         media: Ethernet 10Gbase-T <full-duplex>
ls> >>         status: active
ls> >>
ls> >>
ls> >> I would have thought rtsold should be able to play nice with
ls> >> statically
ls> >> assigned v6 addresses... any ideas?
ls> >
ls> > Hmm, why would it?  If you setup an IPv6 address and then there's a
ls> > router solicitation advertising the same address, the log message makes
ls> > sense.
ls> >
ls> > I don't think you should run rtsold if you have a static IPv6 address.
ls>
ls> How would the host learn about router(s) on the network and other
ls> addresses it might want? (In my particular environment, I'm pretty sure
ls> they don't change so could be statically configured, but interested in
ls> understanding if (and why) these are mutually exclusive modes of operation).

 As Rui already pointed out, I guess you manually configured exactly
 the same address as the auto-configured EUI-64 address such as
 2001:db8::211:85ff:fefe:d6db/64 where the upper 64 bits are equal to
 your IPv6 global prefix and the lower 64 bits are the same as ones in
 <v6_linklocal>.  I do not think this manual configuration is required
 here.  Only ifconfig_vtnet0_ipv6="inet6 accept_rtadv" line instead of
 the four lines in your rc.conf should work.  Because most of RA
 options are handled in the kernel, just enabling "accept_rtadv" in
 $ifconfig_IF_ipv6 is sufficient.

 Enabling rtsold is required only when 1) an IPv6 router on your
 subnet is sending DNS information in RAs and you want to receive it
 to configure /etc/resolv.conf automatically or 2) an IPv6 router on
 your subnet requires DHCPv6 to IPv6 host nodes on the subnet.  In
 both cases, some userland program has to handle the RA options.  The
 rtsold daemon is exactly for this purpose.  The other information in
 RAs including default routers, prefixes, MTUs, and etc. is directly
 handled in the kernel.

 Configuring a static address and enabling accept_rtadv/rtsold are not
 mutually exclusive.  The problem is that you are using the
 auto-configured address manually.  If you need it for some reason,
 you can add "autoconf" flag to the rc.conf line like this:

  ifconfig_vtnet0_ipv6="inet6 <v6_addr> prefixlen 64 autoconf accept_rtadv"

 This per-address flag means whether the address is auto-configured or
 not.  Although normally this is set only by the kernel, you can set
 it by using ifconfig.  If the address has this flag, the kernel
 thinks it has been configured by RAs and does not emit the warning
 messages.

-- Hiroki
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-net/attachments/20170330/05619d46/attachment.sig>


More information about the freebsd-net mailing list