]> git.ipfire.org Git - thirdparty/systemd.git/commit - test/fuzz/fuzz-network-parser/directives.network
networkd: Add support for setting a preferred subnet id for IPv6 PD leases 15669/head
authorAndreas Rammhold <andreas@rammhold.de>
Wed, 13 May 2020 22:54:37 +0000 (00:54 +0200)
committerAndreas Rammhold <andreas@rammhold.de>
Tue, 26 May 2020 10:41:22 +0000 (12:41 +0200)
commit02e9e34bd9a8a252610e181533e477ec10733e27
tree9a5872c6e0fea19cc877bb52e041c7e13461ec49
parent171f625b9e1b942e6d61f4706f26864b7c9b1452
networkd: Add support for setting a preferred subnet id for IPv6 PD leases

This allows users to configure a subnet id that should be used instead
of automatically (sequentially) assigned subnets. The previous attempt
had the downside that the subnet id would not be the same between
networkd restarts. In some setups it is desirable to have predictable
subnet ids across restarts of services and systems.

The code for the assignment had to be broken up into two pieces. One of
them is the old (sequential) assignment of prefixes and the other is the
new assignment based on configured subnet ids. The new assignment code
has to be executed first and has to be taken into account when (later
on) allocating the "old" subnets from the same pool.

Instead of having one iteration through the links we are now trying to
allocate a prefix for every link on every delegated prefix, unless they
received an assignment in a previous iteration.
man/systemd.network.xml
src/network/networkd-dhcp6.c
src/network/networkd-network-gperf.gperf
src/network/networkd-network.c
src/network/networkd-network.h
src/network/networkd-radv.c
src/network/networkd-radv.h
test/fuzz/fuzz-network-parser/directives.network