Rocky Linux 8でホスト名を設定する

2021年10月28日

OSバージョンを確認

# cat /etc/redhat-release
Rocky Linux release 8.4 (Green Obsidian)

1.現在のホスト名を確認

# hostname
localhost.localdomain

2.ホスト名変更

# hostname test.arkgame.com
# hostname
test.arkgame.com

3.恒久的ホスト名を変更
# hostnamectl set-hostname test.arkgame.com

設定確認

# hostnamectl
   Static hostname: test.arkgame.com
         Icon name: computer-vm
           Chassis: vm
        Machine ID: f6cd2672ba2f4afea88dd963605dfa0f
           Boot ID: dde8c63495f649f799a2c3de42485405
    Virtualization: vmware
  Operating System: Rocky Linux 8.4 (Green Obsidian)
       CPE OS Name: cpe:/o:rocky:rocky:8.4:GA
            Kernel: Linux 4.18.0-305.19.1.el8_4.x86_64
      Architecture: x86-64

 

 

Rocky Linux 8

Posted by arkgame