How to Change the Hostname on CentOS 5.5 Server

In this post, i will show you how to change the hostname on linux CentOS 5.5. Reboot is required for both steps.

Option 1. Change Hostname using command shell:

    [root@server ~]# vi /etc/sysconfig/network

Change the HOSTNAME=your_preferred_hostname

Option 2. Change Hostname using GUI
Type Setup as below and Press Enter

    [root@server ~]# setup

Select Network Configuration –> Edit DNS Configuration –> Hostname

A world leading hosting company that provides fully-managed innovative and secure solutions, suitable for hosting small to medium-sized websites

Built on the best available technologies combined with Google Cloud for strong redundancy and application availability. Backed by skilled experts to address web security threats, a devops team to create advanced custom security solutions, and 24/7 sysadmins to watch over the platform. This powerful, hands-on approach makes your sites faster, safer, and easier to manage. Starting from only $3.95/mo.


* up to 30 days money back guarantee