Jump to content
Sign in to follow this  
brent

Static IP on Ubuntu 20.04 Server

Recommended Posts

Configure static IP address using Netplan

Netplan network configuration had been first introduced to Ubuntu 18.04 LTS Bionic Beaver. It is available to all new Ubuntu 18.04 installations. 

Ubuntu Server

To configure a static IP address on your Ubuntu 20.04 server you need to modify a relevant netplan network configuration file within /etc/netplan/ directory. 


 

network:
  ethernets:
    enp0s3:
      addresses: [192.168.1.3/24]
      gateway4: 192.168.1.1
      nameservers:
        addresses: [4.2.2.2, 8.8.8.8]
  version: 2

 

Once ready apply changes with:

$ sudo netplan apply

In case you run into some issues execute:

$ sudo netplan --debug apply

Share this post


Link to post
Share on other sites
Sign in to follow this  

×
×
  • Create New...