User Tools

Site Tools


main_router

This is an old revision of the document!


Configuration files for the Main Router

Network configuration

Upstream interface (enp0s6)

The upstream network interface is configured to act as a DHCP client (both IPv4 and IPv6). It also sets this host as a router and will accept Router Announcements (RA)

[Match]
Name=enp6s0

[Network]
DHCP=yes
IPv6AcceptRA=yes
IPForward=yes

[DHCP]
UseDNS=yes
UseDomains=yes
Anonymize=false
IAID=1
RouteMetric=100

Downstraem interface (br0)

[Match]
Name=br0

[Network]
Address=192.168.19.1/24
DNS=192.168.19.5
IPForward=yes
IPv6SendRA=yes
IPv6PrefixDelegation=yes
Address=fe80::19/64
Address=2001:db8:8073:19::1/64

[Route]
Gateway=192.168.19.20
Destination=192.168.21.0/24

[IPv6SendRA]
Managed=yes
RouterLifetimeSec=1800

[DHCPv6PrefixDelegation]
SubnetId=19

DHCPv6 configuration

Here is only shown the parts that are relevant for prefix delagation. The DHCP sections are omitted.

...
# don't serve enp6s0 (WAN IF)
subnet6 2001:2db:8::8073/128 {
}

subnet6 2001:2db:8073:19::/64 {
    # Range for clients
    range6 2001:2db:8073:19::129 2001:2db:8073:19::254;

    # Range for clients requesting a temporary address
    range6 2001:2db:8073:19::/64 temporary;

    # Additional options
    option dhcp6.name-servers 2001:2db:8073:19::5;
   
    # Prefix range for delegation to sub-routers
    prefix6 2001:2db:8073:0100:: 2001:2db:8073:0f00:: /56;
}
...
main_router.1658597881.txt.gz · Last modified: 2022/07/23 17:38 by mester