Bug 570256

Summary: live ISO lacks meaningful hostname
Product: [Fedora] Fedora Reporter: Steve Tyler <stephent98>
Component: spin-kickstartsAssignee: Jeroen van Meeuwen <vanmeeuwen+fedora>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 15CC: bruno, dcantrell, jonathan, katzj, kevin, maxamillion, vanmeeuwen+fedora, wtogami
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-08-07 19:33:29 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
screenshot of F14 Live showing hostname "localhost.localdomain"
none
screenshot showing hostname in gdm login window none

Description Steve Tyler 2010-03-03 17:08:42 UTC
Description of problem:
The Fedora Live ISO lacks a meaningful hostname.

"System:About this Computer" displays "localhost.localdomain".
From a terminal, "hostname" returns "localhost.localdomain".

In contrast, "System:Preferences:About Me" displays "Live System User".
And from a terminal, "whomai" shows there is a "liveuser" account.

Version-Release number of selected component (if applicable):
Fedora Live ISO 13-Alpha-RC4

How reproducible:
Always.

Steps to Reproduce:
1. Boot from Live ISO.
2. See above.
  
Actual results:
See above.

Expected results:
Could be:
"livehost"
"fedoralive"
"fedoralivehost"
etc.

Additional info:
Ubuntu 9.10 Live has:

About Me: "Live session user"
whoami: ubuntu

About this Computer: "ubuntu" (in "System:Administration:System Monitor:System")
hostname: ubuntu

Having the distro, user, and host all with the same name could be confusing.

See also: Bug 569997 - version and architecture not completely and consistently displayed

Comment 1 Steve Tyler 2010-03-03 20:56:48 UTC
I guess this was supposed to go to "distribution" ...

Comment 2 Jesse Keating 2010-03-09 01:15:45 UTC
no, livecd-creator is the right place, that's the tool that creates the live image.

Comment 3 Fedora Admin XMLRPC Client 2010-05-07 15:40:56 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 4 Fedora Admin XMLRPC Client 2010-10-21 17:57:20 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 5 Brian Lane 2010-10-22 23:33:53 UTC
There should be a way to set this from the dhcp server (and it may already do that). But failing that livehost.localdomain is the correct name from /etc/hosts

Comment 6 Steve Tyler 2010-10-23 13:52:00 UTC
Created attachment 455250 [details]
screenshot of F14 Live showing hostname "localhost.localdomain"

(In reply to comment #5)
> There should be a way to set this from the dhcp server (and it may already do
> that). But failing that livehost.localdomain is the correct name from
> /etc/hosts

In Fedora, the hostname comes from /etc/sysconfig/network, as shown in the attached screenshot.

There is nothing in the screenshot to identify it with Fedora, which is why I opened this bug. As a matter of user convenience and marketing, a Fedora Live CD should clearly identify itself as such.

Also, a dhcp server may not be configured (e.g. in QEMU) or misconfigured. For example, the Ubuntu Live CD has the annoying habit of configuring my router to return "ubuntu" for a reverse name lookup. After rebooting into F13:

[stephent@walnut ~]$ ip addr show dev eth0 | grep 'inet '
    inet 192.168.0.100/24 brd 192.168.0.255 scope global eth0
[stephent@walnut ~]$ host 192.168.0.100
100.0.168.192.in-addr.arpa domain name pointer ubuntu.lan.

AFAICT, Fedora Live does not get its hostname from a dhcp server. Whether or not to get the live hostname from a dhcp server could be configurable.

Comment 7 Steve Tyler 2010-10-23 14:10:15 UTC
Kickstart has this option:

network
...
--hostname=
    Hostname for the installed system. 

http://fedoraproject.org/wiki/Anaconda/Kickstart#network

Comment 8 Steve Tyler 2010-10-23 16:57:10 UTC
A possible fix for this bug is to add this to fedora-live-base.ks:

network --device=eth0 --hostname=FedoraLive

(The compose failed without "--device=eth0".)

This results in the line:
HOSTNAME=FedoraLive
being written to: 
/etc/sysconfig/network

Verified with F13:
$ sudo livecd-creator -c fedora-live-base.ks
$ qemu-kvm -m 512m -cdrom livecd-fedora-live-base-201010230904.iso

$ rpm -q livecd-tools
livecd-tools-033-3.fc13.x86_64

fedora-live-base.ks is here:
http://git.fedorahosted.org/git/?p=spin-kickstarts.git;a=tree

$ rcsdiff -u fedora-live-base.ks 
===================================================================
RCS file: RCS/fedora-live-base.ks,v
retrieving revision 1.1
diff -u -r1.1 fedora-live-base.ks
--- fedora-live-base.ks	2010/10/23 15:22:59	1.1
+++ fedora-live-base.ks	2010/10/23 16:03:57
@@ -16,25 +16,26 @@
 xconfig --startxonboot
 part / --size 3072 --fstype ext4
 services --enabled=NetworkManager --disabled=network,sshd
+network --device=eth0 --hostname=FedoraLive
...

Comment 9 Steve Tyler 2010-10-23 18:23:22 UTC
Created attachment 455278 [details]
screenshot showing hostname in gdm login window

This screenshot shows a side-effect that removes info from the gdm login window:
Fedora release 14 (Laughlin)
gets reduced to:
FedoraLive

Comment 10 Steve Tyler 2010-10-25 17:58:37 UTC
(In reply to comment #9)
> This screenshot shows a side-effect that removes info from the gdm login
> window:
> Fedora release 14 (Laughlin)
> gets reduced to:
> FedoraLive

This appears to be normal gdm behavior.

If HOSTNAME is not set in /etc/sysconfig/network or it is set to "localhost.localdomain", gdm displays the string from /etc/fedora-release.

Verified with F14 installed in a VM.

Comment 11 Brian Lane 2010-11-11 17:53:24 UTC
If anything this should be implemented in the kickstarts, not in livecd-tools.

Comment 12 Bug Zapper 2011-06-02 16:20:26 UTC
This message is a reminder that Fedora 13 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 13.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '13'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 13's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 13 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 13 Steve Tyler 2011-06-02 18:00:26 UTC
F15 Live CD has hostname "localhost.localdomain". Tested with:
$ qemu-kvm -m 1024 Fedora-15-i686-Live-Desktop.iso

Comment 14 Fedora End Of Life 2012-08-07 19:33:33 UTC
This message is a notice that Fedora 15 is now at end of life. Fedora
has stopped maintaining and issuing updates for Fedora 15. It is
Fedora's policy to close all bug reports from releases that are no
longer maintained. At this time, all open bugs with a Fedora 'version'
of '15' have been closed as WONTFIX.

(Please note: Our normal process is to give advanced warning of this
occurring, but we forgot to do that. A thousand apologies.)

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, feel free to reopen
this bug and simply change the 'version' to a later Fedora version.

Bug Reporter: Thank you for reporting this issue and we are sorry that
we were unable to fix it before Fedora 15 reached end of life. If you
would still like to see this bug fixed and are able to reproduce it
against a later version of Fedora, you are encouraged to click on
"Clone This Bug" (top right of this page) and open it against that
version of Fedora.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

The process we are following is described here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping