Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

My machine's hostname is ev.er, and I want to change it to ever. I tried editing /etc/hosts and replacing ev with ever, and also replacing ev.er with ever, saving, and editing the ev that was in /etc/hostname to ever. Then I restarted, but the hostname was still ev.er (it shows ev).

Any solution?

share|improve this question
add comment

1 Answer

Permanent hostname change:

You have to edit the file /etc/hostname and change the name of the system and then run:

/etc/init.d/hostname.sh start

to make the change active. The hostname saved in this file (/etc/hostname) will be preserved on system reboot (and will be set using the same script we used hostname.sh).

share|improve this answer
    
He said to have changed /etc/hostname and rebooted, which should have made the new hostname apply. –  blueyed Jun 2 '12 at 20:55
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.