Adding systemd to the Pi for networking

May 20, 2020 - Reading time: ~1 minute

Systemd and networking on the Raspberry Pi

I have been having problems with the Pi and networking. It seems Raspbian uses dhcpcd.conf to run the networking. While this is ok for the Pi while it is getting a DHCP address, it is no good for multiple ip addresses on the same interface. I decided to convert it to systemd.

I found this tutorial --> https://raspberrypi.stackexchange.com/questions/78787/howto-migrate-from-networking-to-systemd-networkd-with-dynamic-failover

What I did...Step 1, Step 2, skipped the rest.

I added all the ip addresses to the /etc/systemd/network/04-eth.network

    [Match]
    Name=e*
    [Network]
    #to use static ip (with your settings) toggle commenting in the next 8 lines.
    Address=192.168.0.13/24
    Address=192.168.0.14/24
    Address=192.168.0.15/24
    DNS=192.168.0.1
    [Route]
    Gateway=192.168.0.1
    Metric=19
    #DHCP=yes
    #[DHCP]
    #RouteMetric=10

LazyCoderOZ

I am a Linux guy, been around for 20+ years using Linux as my daily driver.
This is my blog on my discoveries and notes so I don't forget how I have done things :)