This post is part of our new series called Daily Ubuntu Tips where we show students and new users how to do basic tasks on Ubuntu. This series is geared towards newbies who want to learn how to manage Ubuntu systems.
The first post in the in this series is how to change Ubuntu computer name. This should apply to all versions of Ubuntu including, Ubuntu 17.04 / 17.10 and future releases.
Folks get the chance to add the system name during Ubuntu installation. The name assigned at installation will stay in place until you change it. To change it, use the guide below.
Changing Ubuntu system name isn’t necessary. However, to learn how to manage Ubuntu, new users may want to learn the basics. Changing Ubuntu system name won’t hurt anything as well, and you can change it as many times as you’d like. You can also keep the computer name in place for ever without changing it.
To change your computer name, run the commands below to open the computer hostname file.
sudo nano /etc/hostname
When the file opens, replace the name in the file with its replacement (new name) and save.
Next, run the commands below to open the hosts file.
sudo nano /etc/hosts
Then change the line that corresponds to the hostname above.
127.0.0.1 localhost 127.0.1.1 ubuntu1704 # The following lines are desirable for IPv6 capable hosts ::1 localhost ip6-localhost ip6-loopback ff02::1 ip6-allnodes ff02::2 ip6-allrouters
Save the file and exit.
Restart your computer for the changes to apply.
Congratulations! You’ve just learned how to change Ubuntu system name.
This post shows students and new users how to change Ubuntu system name. The post is intended for newbies who just want to learn some basic tasks in Ubuntu.
When the changes are done above, restart and your computer should now be recognize by its new name.
You may also like the post below:
- Running Ubuntu 17.10 VMware Guest Machines
- Installing Webmin on Ubuntu 17.04 / 17.10
- Install VSFTPD with SSL/TLS on Ubuntu 17. 04 / 17.10
- Creating and Editing a File via SSH on Ubuntu 17.04 / 17.10
- Changing WordPress Admin Email and Password
- Install WordPress with Nginx and Memcached Support on Ubuntu 17.04 / 17.10
- Setup Self-Signed SSL/TLS Certificates on Ubuntu 17.04 / 17.10
- Reset Forgotten User Password on Ubuntu 17.04 / 17.10
- Setting Up WordPress on Ubuntu – Preparation