Skip to main content

Ubuntu Netplan How-to

Netplan DHCP Example:

network:
    version: 2
    renderer: networkd
    ethernets:
        enp3s0:
            dhcp4: true

Netplan Static Example:

network:
    version: 2
    renderer: networkd
    ethernets:
        enp3s0:
            addresses:
                - 10.10.10.2/24
            nameservers:
                search: [mydomain, otherdomain]
                addresses: [10.10.10.1, 1.1.1.1]
            routes:
                - to: default
                  via: 10.10.10.1