Re: WORKAROUND Re: Cannot change hostname permanently
On 02 Oct 2006, Chris Lale wrote:
[snip]
>
> I did try both manual change and the hostname command originally, but
> perhaps I did not reboot in each case - I can't remember. Subsequently,
> I have found that manually changing /etc/hostname does work, but using
> the hostname command does not work correctly. The hostname command
> appears to work (the hostname command reports the new hostname and a new
> login shows the new hostname in the prompt) but /etc/hostname retains
> the original name. Consequently, when /etc/init.d/hostname.sh is started
> (eg at boot) the old name is set as the hostname.
>
> Also, the system seems slow and unresponsive after the name is changed
> with the hostname command. Eg applications from the Gnome desktop menu
> will not open.
>
> --
> Chris.
I've found that you have to change /etc/hosts to match /etc/hostname,
otherwise various bad things happen. The same applies if you use the
hostname command.
Anthony
--
Anthony Campbell - ac@acampbell.org.uk
Microsoft-free zone - Using Linux Gnu-Debian
http://www.acampbell.org.uk (blog, book reviews,
on-line books and sceptical articles)
Reply to: