OpenSUSE – Change hostname

After installing of an OpenSUSE server the hostname often has to be modified. The following steps must be performed via the CLI:

  1. Open the /etc/hostname file with a text editor (vi/nano) and change the hostname:
    sudo vi /etc/hostname

  2. Next open the /etc/hosts file and change the hostname:
    sudo vi /etc/hosts

  3. To apply the changes, the server has to be rebooted:
    sudo reboot
5 1 vote
Article Rating
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments