Set Static IP Address in Ubuntu 22.04 Example
For teams turning “Set Static IP Address in Ubuntu 22.04 Example” into a repeatable delivery task, the corresponding workflow can document setup, troubleshooting and review time; managers should interpret those records alongside reliability and completed work, not as a stand-alone score.
Package and operating-system behaviour can change, so verify the commands and supported versions through Ubuntu before running them on a production host.
Jul 07, 2022
Hi Guys,
This tutorial will provide example of Ubuntu 22.04 on Set Static IP Address. it's simple example of How to Set Static IP Address on Command Line. Here you will learn Step by Step Set Static IP Address in Ubuntu 22.04. you will learn Command Line on Set Static IP Address in Ubuntu 22.04. follow bellow step for Linux Basics - Set a Static IP on Ubuntu.
You can use this post for ubuntu 14.04, ubuntu 16.04, ubuntu 18.4, ubuntu 20.04, ubuntu 21 and ubuntu 22.04 versions.
Use the following steps to set static ip address using command line; is as follows:
Step 1 – Check device name
Step 2 – Create a Static connection
Step 3 – Add DNS IP to static-ip
Step 4 – Activate the Static connection
Step 5 – Verify the IP assignment to the selected device
Step 1: Check device name
First open a terminal or command line using the following command:
nmcli connection show
Step 2: Create a Static connection
Use the following command to create a new static connection named "static ip":
$ sudo nmcli con add type ethernet con-name 'static-ip' ifname emp0s3 ipv4.method manual ipv4.addresses 192.168.1.102/24 gw4 192.168.1.1
Step 3: Add DNS IP to static-ip
Execute the following command to add the DNS IP to the “static-ip” connection:
sudo nmcli con mod static-ip ipv4.dns 192.168.1.1
Step 4: Activate the Static connection
Execute the following command on command lien to active “static-ip” connection:
sudo nmcli con up id 'static-ip'
Step 5: Verify the IP assignment to the selected device
Run the "ip" command with the "a" option to validate the assigned IP:
ip a
Check Internet connectivity using the following command:
ping google.com
- How to Zip a Folder in Ubuntu/Linux Using the Command Line?
- How to Add and Delete Users on Ubuntu?
- How to Change Hostname on Ubuntu 22.04?
- How to Install PHP SOAP Extension on Ubuntu 22.04?
- How to Install and Master Django on Ubuntu 22.04?
- How to Install PHP JSON Extension in Ubuntu 22.04?
- How to install PHP Imagemagick on Ubuntu 22.04?
- How to Install PHP Intl Extension in Ubuntu 22.04 ?