This article is also an article for new Ubuntu users and new users. It will guide you how to easily change your computer name when using Ubuntu, many users never consider changing the computer name or host name on Ubuntu, which is the last thing they have to worry about.
Many users will use the names created or set during Ubuntu installation, but new users who want to know how to change their names can continue to learn. This article is not prepared for Ubuntu experts, but for beginners who have just started using Ubuntu.
So why do you want to change your computer name? If you want to learn how to operate, you don't have a good reason. Otherwise, if you have a good reason or want to learn how to operate, continue.
Press Ctrl-Alt-T to open the terminal. When the terminal opens, enter the following command and use gedit to edit the hostname file.
Sudo gedit/etc/hostname
Next, no matter what the old computer name is, change it to a new one. For example, if you want your computer to be named "RDOMNU", first delete the file content, enter RDOMNU, and then save the file.
Then, run the following command to open the hosts file:
Sudo gedit/etc/hosts
Change the value of the position marked by the arrow in the second line so that it matches the name of the computer you just entered. After that, save the file.
That's it! Restart your computer and your machine will display a new name. This is how to change the name of the Ubuntu machine.
Try it!