Page 1 of 1

[SOLVED] How do change the name of the machine?

PostPosted: Sep 26th, '11, 03:34
by nigelc
Hello,
How do I change the name of the machine from localhost.
cheers

Re: change name to endor

PostPosted: Sep 26th, '11, 07:39
by nigelc
I've worked out how to do it.
At the end of /etc/sysconfig/network I added the line
HOSTNAME=endor
and changed /etc/hosts to
127.0.0.1 endor localhost

Re: How do change the name of the machine?

PostPosted: Sep 26th, '11, 07:51
by Max
Great!
Now one of the mods can mark this thread as SOLVED.

Also, watch out for the little furry guys. ;)

Re: How do change the name of the machine?

PostPosted: Sep 26th, '11, 09:49
by doktor5000
You could have also easily done that within Mageia Control Center, though ;)

Re: [SOLVED] How do change the name of the machine?

PostPosted: Jan 11th, '13, 15:41
by morgano
In MCC, I have only found how to edit /etc/hosts (mcc > network and interfaces > machine definition)
But on my two last installs of mga2 i was confused to find only one of them contained the HOSTNAME= line in /etc/sysconfig/network so I too edited it by hand.
Then there is also possibly to spell the name in /etc/hostname and i have no idea where this takes precedence or how important it is.

Optimally i think the machine name should be asked and set during install.

And there should be a specific button to set own name in (mcc > network and interfaces > machine definition) that writes it in all relevant places.

But should it really be needed or even allowed to define machines own name in more than one place?
It feels like risk of odd problems!

Re: [SOLVED] How do change the name of the machine?

PostPosted: Jan 11th, '13, 17:14
by jkerr82508
morgano wrote:Optimally i think the machine name should be asked and set during install.

At the Configuration Summary page you can choose to configure the network connection. There you can set the hostname. That module is also available in MCC - Network & Internet - Set up a new network interface. Running that wizard will enable you to re-configure your network device and give you an opportunity to set the hostname of your choice.

I agree that an explicit requirement to set a unique hostname would be desirable during installation, especially since so many people now have local networks, for which each machine should have a unique hostname.

Jim