Ubuntu 25.04
Sponsored Link

Set Hostname2025/04/21

 

This is the example for setting Hostname of your system.

[1] Change hostname. (but if rebooting, it will be back).
# show current hostname

root@ubuntu:~#
ubuntu
# change hostname

root@ubuntu:~#
root@ubuntu:~#
dlp    
# just changed

[2] Change hostname permanently.
root@ubuntu:~#
hostnamectl set-hostname dlp.srv.world
# show settings

root@ubuntu:~#
 Static hostname: dlp.srv.world
       Icon name: computer-vm
         Chassis: vm
      Machine ID: 2d04c429f6b3426daf27c7a9a727ebbc
         Boot ID: 9f4921cfff0b4bb090666e30f74859b6
    Product UUID: 7b9731cd-eb2a-4e01-ad59-f800192faac0
  Virtualization: kvm
Operating System: Ubuntu 25.04
          Kernel: Linux 6.14.0-15-generic
    Architecture: x86-64
 Hardware Vendor: Red Hat
  Hardware Model: KVM
Firmware Version: 1.16.3-2.el9_5.1
   Firmware Date: Tue 2014-04-01
    Firmware Age: 11y 2w 6d
Matched Content