T1TAN Posted April 12, 2004 Report Share Posted April 12, 2004 hi everyone, i've tried setting the hostname of my pc (MDK9.2) to anything but localhost, but it always goes back to localhost as soon as i restart.. i'm a noob, so... :unsure: Quote Link to comment Share on other sites More sharing options...
Guest Mandrake_Mouse Posted April 12, 2004 Report Share Posted April 12, 2004 What are you doing to change the hostname? If you're using the "hostname <newname>" command, this will only change the hostname temporarily. You need to edit the /etc/sysconfig/network file, put the new name in the "HOSTNAME" field, and reboot. This should make the change stick for you. Remember that lots of services and such in Linux use the hostname to resolve dependencies, so some apps (in my case Gnome apps) may take a while to start the first time you use them after changing the hostname. Quote Link to comment Share on other sites More sharing options...
bvc Posted April 12, 2004 Report Share Posted April 12, 2004 http://www.mandrakeusers.org/index.php?showtopic=12950 after setting the hostname put it and the ip in /etc/hosts Quote Link to comment Share on other sites More sharing options...
phunni Posted April 12, 2004 Report Share Posted April 12, 2004 There are (usually) two networks ip's on any machine - your main network one and 127.0.0.1 - which is usually mapped to localhost So if I say: ping localhost or ping myHostname The I am actually pinging the same machine - make sure that the hostname is not set, as it may be set to what you want and be localhost Quote Link to comment Share on other sites More sharing options...
jeanackle Posted April 14, 2004 Report Share Posted April 14, 2004 The I am actually pinging the same machine - make sure that the hostname is not set, as it may be set to what you want and be localhost I didn't understand that, phunni. Could u try and explain it for me? Thanks :) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.