[Bug 803653] New: hostnamed/hostnamectl is just broken
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c0 Summary: hostnamed/hostnamectl is just broken Classification: openSUSE Product: openSUSE 12.3 Version: RC 1 Platform: x86-64 OS/Version: Other Status: NEW Severity: Major Priority: P5 - None Component: Basesystem AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: mike.catanzaro@gmail.com QAContact: qa-bugs@suse.de Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:18.0) Gecko/20100101 Firefox/18.0 hostnamed/hostnamectl is just broken. By default... michael@linux-h2qj:~> hostnamectl Static hostname: n/a Transient hostname: linux-h2qj.site Pretty hostname: n/a <snip> That's not my transient hostname, which is completely different. That's my static hostname. It's supposed to be stored in /etc/hostname according to the manpage and upstream, but it's actually in /etc/HOSTNAME as that's where it's always been for openSUSE. michael@linux-h2qj:~> hostnamectl set-hostname 'Victory Road' michael@linux-h2qj:~> hostnamectl Static hostname: victory-road Pretty hostname: Victory Road <snip> Now that made /etc/hostname: michael@linux-h2qj:~> cat /etc/hostname victory-road michael@linux-h2qj:~> cat /etc/machine-info PRETTY_HOSTNAME=Victory Road michael@linux-h2qj:~> cat /etc/HOSTNAME linux-h2qj.site YaST of course only knows about /etc/HOSTNAME. So I think hostnamed is not really accomplishing anything? Maybe it should be patched to use /etc/HOSTNAME instead for now? And something is really odd about the transient hostname. I'm not sure what it's doing there, but mine is absolutely completely different from what is displayed.... (Maybe we don't need to build hostnamed/hostnamectl at all for 12.3 -- does anything hard depend on them?) Reproducible: Always Also we're missing a soft dependency on nss-myhostname, so if hostnamed DID work it would make the new hostname unresolvable. That's merged into systemd 197 upstream, but since we're on systemd 195 we just get a little complaint in the journal that we're doing it wrong: Warning: nss-myhostname is not installed. Changing the local hostname might make it unresolvable. Please install nss-myhostname! -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c Ludwig Nussel <lnussel@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lnussel@suse.com AssignedTo|bnc-team-screening@forge.pr |fcrozat@suse.com |ovo.novell.com | Summary|hostnamed/hostnamectl is |hostnamed doesnt read |just broken |/etc/HOSTNAME -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c1 --- Comment #1 from Frederic Crozat <fcrozat@suse.com> 2013-02-15 15:26:38 UTC --- (In reply to comment #0)
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:18.0) Gecko/20100101 Firefox/18.0
hostnamed/hostnamectl is just broken.
By default...
michael@linux-h2qj:~> hostnamectl Static hostname: n/a Transient hostname: linux-h2qj.site Pretty hostname: n/a <snip>
That's not my transient hostname, which is completely different. That's my static hostname. It's supposed to be stored in /etc/hostname according to the manpage and upstream, but it's actually in /etc/HOSTNAME as that's where it's always been for openSUSE.
michael@linux-h2qj:~> hostnamectl set-hostname 'Victory Road'
michael@linux-h2qj:~> hostnamectl Static hostname: victory-road Pretty hostname: Victory Road <snip>
Now that made /etc/hostname:
michael@linux-h2qj:~> cat /etc/hostname victory-road michael@linux-h2qj:~> cat /etc/machine-info PRETTY_HOSTNAME=Victory Road michael@linux-h2qj:~> cat /etc/HOSTNAME linux-h2qj.site
YaST of course only knows about /etc/HOSTNAME. So I think hostnamed is not really accomplishing anything? Maybe it should be patched to use /etc/HOSTNAME instead for now?
I'll modify hostnamed to read /etc/HOSTNAME if /etc/hostname doesn't exist. When assigning a new hostname, /etc/hostname will be filled and /etc/HOSTNAME will be replaced by a symlink to /etc/hostname. I've checked modifying hostname with YaST will correctly modify /etc/hostname, by following created symlink.
Also we're missing a soft dependency on nss-myhostname, so if hostnamed DID work it would make the new hostname unresolvable. That's merged into systemd 197 upstream, but since we're on systemd 195 we just get a little complaint in the journal that we're doing it wrong:
Warning: nss-myhostname is not installed. Changing the local hostname might make it unresolvable. Please install nss-myhostname!
This part is handled in bnc#783841 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c2 Frederic Crozat <fcrozat@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED --- Comment #2 from Frederic Crozat <fcrozat@suse.com> 2013-02-15 16:24:23 UTC --- pushed to Base/System. Will forward to Factory and 12.3 after. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c3 --- Comment #3 from Bernhard Wiedemann <bwiedemann@suse.com> 2013-02-16 11:00:39 CET --- This is an autogenerated message for OBS integration: This bug (803653) was mentioned in https://build.opensuse.org/request/show/155589 Factory / systemd -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c4 Christian Boltz <suse-beta@cboltz.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |REOPENED CC| |suse-beta@cboltz.de Resolution|FIXED | --- Comment #4 from Christian Boltz <suse-beta@cboltz.de> 2014-01-14 21:03:00 CET --- The behaviour on 13.1 is interesting[tm]: After a fresh install, there's only /etc/HOSTNAME (owned by netcfg package), but no /etc/hostname: -rw-r--r-- 1 root root 13 21 nov 16:05 /etc/HOSTNAME When calling "hostnamectl set-hostname ein.host.name", the result is -rw-r--r-- 1 root root 14 14. Jan 20:49 /etc/hostname lrwxrwxrwx 1 root root 13 14. Jan 20:49 /etc/HOSTNAME -> /etc/hostname This doesn't break anything, but is at least confusing. Can you please sort out what the correct filename is? ;-) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c5 --- Comment #5 from Michael Catanzaro <mcatanzaro@gnome.org> 2014-01-14 22:22:33 UTC --- (In reply to comment #4)
This doesn't break anything, but is at least confusing. Can you please sort out what the correct filename is? ;-)
Setting the hostname in gnome-control-center (on either the Details panel or the Sharing panel) is broken for new installs, until /etc/hostname has been created. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c6 Frederic Crozat <fcrozat@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |RESOLVED Resolution| |FIXED --- Comment #6 from Frederic Crozat <fcrozat@suse.com> 2014-01-15 09:01:08 UTC --- closing back the bug report. Please open a different bug report, it makes thing difficult to reopen bugs which are on a different openSUSE release than the one reported, where update was released. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=803653 https://bugzilla.novell.com/show_bug.cgi?id=803653#c7 --- Comment #7 from Christian Boltz <suse-beta@cboltz.de> 2014-01-15 21:20:07 CET --- ok, reported as bug 858908. Michael, please open another bugreport for gnome-control-center (with a pointer to bug 858908 included). -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com