Bug 21349 - hostname should be required during installation
Summary: hostname should be required during installation
Status: NEW
Alias: None
Product: Mageia
Classification: Unclassified
Component: Installer (show other bugs)
Version: Cauldron
Hardware: All Linux
Priority: Normal normal
Target Milestone: Mageia 7
Assignee: Mageia tools maintainers
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-07-25 17:08 CEST by magnux77
Modified: 2019-05-05 23:18 CEST (History)
5 users (show)

See Also:
Source RPM:
CVE:
Status comment:


Attachments

Description magnux77 2017-07-25 17:08:45 CEST
After installation, a Mageia machine is always named 'localhost.localdomain'

It is possible to edit /etc/hostname and /etc/hosts, but it will be better if installer requires the hostname from the user during installation (as Debian does)

Kernel updates should not clear anymore this hostname value as it is now.

Ant these names should be recognize by the local router. I do not know why but my router knows my RasPi's, the CPL plugin, but not the Mageia machines...

I have no opinion about localdomain. 
Advices during installation could be very simple : the name you want give to your machine, the name you want to give to your local network.

Thanks
Comment 1 Rémi Verschelde 2017-07-25 17:11:28 CEST
I agree, that would be a nice feature to have. So far the workflow I've used to set my hostname is when (re)configuring the Internet connection after install in the MCC; it would be much better to be able to set it up during install independently of the network.

Target Milestone: --- => Mageia 7
Assignee: bugsquad => mageiatools

Comment 2 Frank Griffin 2017-07-25 17:15:02 CEST
This should be optional, since advanced setups use DHCP to supply the hostname based on MAC address.

CC: (none) => ftg

Comment 3 Charles Edwards 2017-07-25 19:01:45 CEST
This can easily be set at the Configuration stage of the installation by manually
configuring the Network.

It can also be set when you add online media during the Mga X installation.
(I do it on my installs)

[charles@SuperSize ~]$ hostname
SuperSize.eslrahc.com

CC: (none) => cae

Comment 4 Bit Twister 2017-07-26 05:06:29 CEST
(In reply to magnux77 from comment #0)
> After installation, a Mageia machine is always named 'localhost.localdomain'

Hmm, I always set it during install of classic DVD via the network setup screen.

> It is possible to edit /etc/hostname and /etc/hosts,

Or better yet, use the "hostname new_FQDN_here" command to set /etc/hostname

I assume you also change other files like
/etc/sysconfig/network and DOMAIN= in any network configuration files.

> but it will be better
> if installer requires the hostname from the user during installation (as
> Debian does)
> 
> Kernel updates should not clear anymore this hostname value as it is now.

I have yet to see that problem. It has never changed on any of my setups,
running 4 nodes and any number of VirtualBox guests.
Then again, I always select Manual ip setup in network setup screen.

> Ant these names should be recognize by the local router.

Nope, we do not need that "requirement". I have no desire to have a FQDN like  cpe-74-085-167-193.tx.res.rr.com

I prefer values I set during install.

$ grep -i host /etc/sysconfig/network
HOSTNAME=wb.home.test
NEEDHOSTNAME=no

$ cat /etc/hostname
wb.home.test

$ grep $(hostname) /etc/hosts
192.168.11.132 wb.home.test wb

$ grep -i domain /etc/sysconfig/network-scripts/ifcfg-en*
/etc/sysconfig/network-scripts/ifcfg-enp3s0:DOMAIN=home.test
/etc/sysconfig/network-scripts/ifcfg-enp4s0:DOMAIN="home.test"

> I do not know why
> but my router knows my RasPi's, the CPL plugin, but not the Mageia
> machines...

During network setup there is a selection which determines if a DHCP user wants name from DHCP server or not. 
 
> I have no opinion about localdomain. 
> Advices during installation could be very simple :

But should suggest not dreaming up just any domain name.

> the name you want give to
> your machine, the name you want to give to your local network.

I suggest default TLD2 name would be .test or .invalid if name not provided by DHCP server.

See http://www.ietf.org/rfc/rfc2606.txt

CC: (none) => bittwister2

Comment 5 magnux77 2019-01-23 15:01:04 CET
I don't know nothing about network admin. I don't even completely understand your solutions. I don't know what should be done. I just say others distros ask for the name of the machine during install and Mageia does not.
magnux77 2019-01-23 15:01:18 CET

CC: (none) => magnux77

Comment 6 Florian Hubold 2019-05-05 23:18:45 CEST
I believe a good idea could be to offer to run manahost from the mageia welcome applet after installation, so that users get a valid hostname. Even when it is possible to set a hostname during installation, most users end up with no hostname and after installation they usually ask how to properly set one.

Also see https://bugs.mageia.org/show_bug.cgi?id=12580

CC: (none) => doktor5000


Note You need to log in before you can comment on or make changes to this bug.