HomeFreeBSD

rc: Teach netwait to wait for DAD

Description

rc: Teach netwait to wait for DAD

In some configurations, especially in jails, it is possible for the
system to boot so fast that we end up launching daemons while duplicate
address detection is still ongoing. If that happens, said daemons may
fail to bind to IPv6 addresses, as they are still tentative. Teach the
netwait service to wait (up to 10 seconds, by default) for the tentative
flag to vanish.

MFC after: 1 week
Reviewed by: olce
Differential Revision: https://reviews.freebsd.org/D51889

(cherry picked from commit 5ead817c3b7af6d6b5fea222ab144db2c3167b22)

rc: Improve netwait DAD logic

Disable if IPv6 is not supported, and instead of 10 seconds, default to
one more than the value of net.inet6.ip6.dad_count.

Fixes: 5ead817c3b7a ("rc: Teach netwait to wait for DAD")
Reviewed by: bz
Differential Revision: https://reviews.freebsd.org/D52905

(cherry picked from commit ec6ad605ecea5c4a76d2e744df0265cc3f3a01b9)

Details

Provenance
desAuthored on Oct 2 2025, 9:28 AM
Reviewer
olce
Differential Revision
D51889: rc: Teach netwait to wait for DAD
Parents
rGe5c0b4f03692: release: Avoid generating .pkgsave files in OCI images
Branches
Unknown
Tags
Unknown