HomeFreeBSD

route(8): convert to netlink

Description

route(8): convert to netlink

This change converts all kernel rtsock interactions in route(8)
to Netlink.

Based on the WITHOUT_NETLINK_SUPPORT src.conf(5) variable, route(8)
now fully operates either via Netlink or via rtsock/sysctl.
The default (compile-time) is Netlink.

The output for route delete/add/get/flush is targeted to be exactly
the same (apart from some error handling cases).
The output for the route monitor has been changed to improve
readability and support netlink models.

Other behaviour changes:

  • exact prefix lookup (route -n get a.b.c.d/e) is not yet supported.
  • route monitor does not show the change originator yet.

Differential Revision: https://reviews.freebsd.org/D39007

Details

Provenance
melifaroAuthored on Mar 26 2023, 9:13 AM
Differential Revision
D39007: route(8): convert to netlink
Parents
rGa85dcd4ac4b0: netlink: restrict default userland switch to netlink to i386/amd64.
Branches
Unknown
Tags
Unknown