NetPlan Essentials. If no render-er is specified systemd will be used by default.
Set to DHCP
sudo nano /etc/netplan/01-network-manager-all.yaml #desktop
sudo nano /etc/netplan/50-cloud-init.yaml #server
network:
version: 2
ethernets:
eno1:
dhcp4: true
Set to Static
network:
version: 2
ethernets:
eno1:
dhcp4: false
addresses: [10.0.0.2/24]
gateway4: 10.0.0.1
nameservers:
addresses: [1.1.1.1,2.2.2.2,3.3.3.3]
WiFi
network:
version: 2
wifis:
renderer: networkd
wlan0:
access-points:
juniper:
password: 123456789
cisco:
password: 987654321
dhcp4: true
optional: true
Apply
sudo netplan apply
ip a
more info on the ip command can be found in Linux IP Essentials
Related
Links
- https://netplan.io/reference/