How do I change the hostname in Ubuntu 16?

How do I change the hostname in Ubuntu 16?
Answer
How to Change the Hostname on Ubuntu 16.04
  1. Step 1: Edit the hostname configuration file. Run the following command to open the hostname configuration file: sudo vim /etc/hostname.
  2. Step 2: Edit the hosts configuration file. Run the following command to open the hosts file: sudo vim /etc/hosts.
  3. Step 3: Restart the machine to apply the changes.
 

Tìm kiếm

Back
Top