Changing the Hostname in Ubuntu 20.04 and Debian 11

The following tutorial describes how to change the hostname on Ubuntu systems 20.04 and Debian 11.
The whole thing can be done in several ways using the terminal. Both for Debian and Ubuntu the process looks the same.

We start the terminal and, depending on the method chosen by us, we issue the command:

1.

2.

3.

4.

5.

All commands have the same effect.
In order for the changes to be visible, the server must be restarted.

How useful this post was?

Click on the star, to evaluate it!

Average grade / 5. number of votes:

So far, no votes! Be the first to rate this post.