View Full Version : How do I change my hostname?
My current one is "localhost." (the redhat default)
Is there a command to change this name?
Klaus-P
12-22-02, 12:49 PM
This "localhost" is the default dummy name for the local loopback interface with the
IP 127.0.0.1
If you really don't like this name then try to modify it in "/etc/hosts" to "any_new_free_name".
Then reboot your machine and check if the modification works by running "ping any_new_free_name"
> ping any_new_free_name
should respond with something like
PING any_new_free_name (127.0.0.1) from 127.0.0.1 : 56(84) bytes of data.
64 bytes from any_new_free_name (127.0.0.1): icmp_seq=1 ttl=255 time=0.053 ms
But i think it's not a very good idea to change it!
BTW Your hostname is that name you get if you run the command "hostname".
Would there be a problem if I change the short hostname as in:
127.0.0.1 localhost.localdomain localhost
to
127.0.0.1 localhost.localdomain doom
Klaus-P
12-22-02, 04:10 PM
And i've hoped it was April 1. :-(
vBulletin® v3.7.1, Copyright ©2000-2012, Jelsoft Enterprises Ltd.