Change Hostname on Linux
7:47 PM
What is a hostname?
|
---|
A hostname is a label that is assigned to a device connected to a computer network and that is used to identify the device in various forms of electronic communication such as the World Wide Web, e-mail or Usenet. Hostnames may be simple names consisting of a single word or phrase, or they may have appended the name of a Domain Name System (DNS) domain, separated from the host specific label by a full stop (dot). In the latter form, a hostname is also called a domain name. If the domain name is completely specified including a top-level domain of the Internet, the hostname is said to be a fully qualified domain name (FQDN). |
Add new hostname to network file |
sudo vi /etc/sysconfig/network |
Add new host name to hosts file |
sudo vi /etc/hosts |
Restart network services |
sudo /etc/init.d/network restart |
Check hostname |
hostname
0 comments