1
ls /etc/netplan/

Cu rezultatul ceva de genul “00_blablabla.yaml”.

Creezi un 99_config.yaml

1
sudo vim /etc/netplan/99_config.yaml
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      addresses:
        - 192.168.0.10/24
      gateway4: 192.168.0.1
      nameservers:
        addresses: [1.1.1.1,8.8.8.8]

Schimbi eth0 cu numele placii tale.
Schimbi 192.168.0.10/24 cu ip_ul_tau/24.

In cazul in care ai 2 IP-uri in momentul asta, sterge 00_blablabla.yaml.

1
sudo netplan apply

Et voila.