Results 1 to 5 of 5

Thread: How to change Host name in RH Linux

  1. #1
    Join Date
    Mar 2010

    How to change Host name in RH Linux

    I installed Red Hat Linux and need to change the Host name using linux command line way .when i newly installed and configured, it displayed as - [root@localhost root]#

    This was the default provided by system, can you all help me chnage this in the following format - [root@pc1 root]#

    Is there any way to change host name?
    Last edited by Morea; 01-04-2010 at 07:08 PM.

  2. #2
    Join Date
    Apr 2008

    How to change Host name in RH Linux

    Why not, This is very simple procedure to change it from the command line argument and you have to restart the computer to get the changes after issuing command from the command line argument :

    #hostname Desired_Name
    It is possible in case only, if you are the root user of the linux system and update theses changes in network file also.

  3. #3
    Join Date
    Apr 2008

    How to change Host name in RH Linux

    For permanent changes in the configuration of linux host name, you need to have the privilege of root user and open up the network file from the following location in Vi editor -

    [root@localhost root]#cd  /etc/sysconfig/
                [root@localhost root]# vi network
    And edit the following parameter with proper information in the configuration file for host related queries by the system -

    Network type :
    Hostname :
    Gateway :

  4. #4
    Join Date
    Mar 2010

    How to change Host name in RH Linux

    Hello sir,

    I issued the command and edit the network configuration file and then restart Linux computer. After all of the operation, it is abusing me like -

    "Could not look up internet address for PC1.localdomain.
    This will prevent GNOME from opening correctly.
    it may be possible to correct the problem by adding PC1.localdomain to the file /etc/host.

    Any other procedure or trick to solve this or my PC is going to corrupt. Please help me

  5. #5
    Join Date
    Nov 2005

    How to change Host name in RH Linux

    hello dear,

    You are about to change the host name, something is going to left. You need to edit the hosts file also located in /etc/hosts.

    Just open it with vi and fill the appropriate value for the dedicated parameter and in case if the old name is already tagged there then replace the old host name and fill up your new host name. Now save the changes and restart your PC. The error would not be displayed for you.


Similar Threads

  1. Brink Agents of Change: Waiting For Host
    By Dead-Man in forum Video Games
    Replies: 7
    Last Post: 08-08-2011, 12:02 AM
  2. How to change host browser in CloudMe?
    By Iason in forum Technology & Internet
    Replies: 3
    Last Post: 14-06-2011, 07:09 AM
  3. Which Linux should be used to host a database on a notebook?
    By Ferdinand Alosa in forum Operating Systems
    Replies: 4
    Last Post: 19-01-2011, 03:20 PM
  4. Need to change website host
    By sonuinfy in forum Networking & Security
    Replies: 1
    Last Post: 16-11-2010, 12:39 AM
  5. Linux or Windows Host for these multiple programming languages
    By Rock Villa in forum Software Development
    Replies: 3
    Last Post: 16-03-2009, 06:32 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts