How do I change my IP address and hostname in Linux?

Huyền Thu

New member
How do I change my IP address and hostname in Linux?
Answer
How to change the hostname in RHEL/CentOS based Linux distributions
  1. Edit the /etc/sysconfig/network file with your favourite text editor. …
  2. Edit the /etc/hosts file so that the local hostname will resolve to the localhost IP address. …
  3. Run the ‘hostname name’ command, replacing name with your new hostname.
1 окт. 2015 г.
 

Tìm kiếm

Back
Top