Hi there! This post is part of a series I am doing where I attempt to move most of the applications I use at home over to Linux. If you find this interesting you may enjoy the other posts too!
Most of the information in this post is a simplified version of the following guide. Basically you can think of this as the CliffsNotes for getting up and running with a static IP Address on Ubuntu Server.
First you will need the name of the NIC you want to assign the static IP Address to. This is as simple as running the below command and picking the most appropriate sounding name form the results:
1 $ ls /sys/class/net/
In my case my NIC would be
Next you will need to create (or edit) the /etc/netplan/99_config.yaml file:
1 $ sudo nano /etc/netplan/99_config.yaml
Add the below lines to the file substituting in your NIC and desired IP Addresses where applicable:
1 2 3 4 5 6 7 8 network: version: 2 renderer: networkd ethernets: enp63s0: addresses: - 10.0.0.51/24 gateway4: 10.0.0.1
Save and close the file followed by restarting the network service via netplan.
1 $ sudo netplan apply
Comments powered by Disqus.