Set hostname

Set host name on Centos:

/etc/sysconfig/network

 

HOSTNAME="mycomputer"


/etc/hosts wrote:

127.0.0.1 mycomputer.mydomain.local mycomputer

 

check it with

hostname 
hostname --fqdn
hostname -a

 

Was this answer helpful?

 Print this Article

Also Read

Epel Centos

Some packages are missing from the base repository. This guide shows how to install RHEL EPEL...

Configure OpenVPN client on Windows

How to configure OpenVPN client on Windows: First download and install the client. Then...

Squid with authentication on Centos 6

How to install Squid with authentication on Centos 6 >>Get VPS with current...

Autorun in Linux

To set a script to start at boot in CentOS, add it into /etc/rc3.d/S99local. For example:...

Disabling selinux

Selinux annoying you? Get it out! How to disable selinux Open its config file nano...