Menu
User

DropVPS Team

Writer: Cooper Reagan

How To Configure Static IP On Ubuntu 25.04?

How To Configure Static IP On Ubuntu 25.04?

Publication Date

08/15/2025

Category

Articles

Reading Time

2 Min

Table of Contents

Configuring a static IP ensures your Ubuntu machine always uses the same IP address, which is useful for servers or network devices.

Step 1: Identify Your Network Interface

First, find the name of the interface you want to assign a static IP to:

ip a

Look for interfaces like eth0, enp0s3, or ens33.

Step 2: Edit Netplan Configuration

Ubuntu 25.04 uses Netplan for network configuration. Open the Netplan YAML file:

sudo nano /etc/netplan/01-netcfg.yaml

The filename may differ, but it’s usually in /etc/netplan/.

Step 3: Configure a Static IP

Modify the file to set your static IP. Example configuration:

network:
  version: 2
  renderer: networkd
  ethernets:
    enp0s3:
      dhcp4: no
      addresses:
        - 192.168.1.100/24
      gateway4: 192.168.1.1
      nameservers:
        addresses: [8.8.8.8, 8.8.4.4]

Replace enp0s3 with your interface name and adjust the IP, gateway, and DNS as needed.

Step 4: Apply the Configuration

Save the file and apply the changes with:

sudo netplan apply

Step 5: Verify the Static IP

Check that your interface now uses the new IP:

ip a

You should see your configured IP assigned to the interface. Your Ubuntu 25.04 machine now has a static IP address.

Linux VPS
U
Loading...

Related Posts

How To Configure Static IP On Ubuntu 25.04?