[Bug 952517] New: "hostname -f" returns null instead of fqdn
http://bugzilla.opensuse.org/show_bug.cgi?id=952517 Bug ID: 952517 Summary: "hostname -f" returns null instead of fqdn Classification: openSUSE Product: openSUSE Distribution Version: 13.2 Hardware: All OS: openSUSE 13.2 Status: NEW Severity: Normal Priority: P5 - None Component: Basesystem Assignee: bnc-team-screening@forge.provo.novell.com Reporter: tonysu@su-networking.com QA Contact: qa-bugs@suse.de Found By: --- Blocker: --- Don't know if the scope of this issue extends beyond 13.2. "hostname -f" is supposed to return the fqdn, but currently returns null (an empty result) Note that simply "hostname" seems to return the fqdn by default. Ordinarily this may not be much of an issue for most people, but in my current case this command is buried somewhere deep in a maze of dependent scripts so will be difficult to find and modify. So, should be fixed. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=952517
http://bugzilla.opensuse.org/show_bug.cgi?id=952517#c1
--- Comment #1 from Tony Su
http://bugzilla.opensuse.org/show_bug.cgi?id=952517
http://bugzilla.opensuse.org/show_bug.cgi?id=952517#c3
Bernhard Wiedemann
http://bugzilla.opensuse.org/show_bug.cgi?id=952517
http://bugzilla.opensuse.org/show_bug.cgi?id=952517#c4
--- Comment #4 from Tony Su
When the result is empty, it usually means that your host's IP addr does not resolve back to a name via /etc/hosts or DNS.
Can you please check your /etc/hosts file for an entry about your IP addr? If you use DHCP, it should be something like 127.0.0.2 yourhostname.domain
Running that test today on the problem machine, your statement appears to be true. After pinging the hostname by name to verify hostname resolution, I was able to successfully run "hostname -f" Although my memory is imperfect, I have not made any changes to how the machine is configured since yesterday when the problem existed. The machine was newly built, and had just changed the hostname using YAST. A curious thing I've observed is that after changing the system's hostname, the change isn't usually reflected immediately in a console, for awhile the console still indicates the old hostname but changes after some time. Although I'm sure the hostname in the console had changed by the time I ran a script using "hostname-f" I wonder if the entire system still had not completely switched over to using the new hostname. Note that simply running "hostname" returns the correct fqdn so name resolution is still somehow working even if appending a flag causes a null result. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=952517
http://bugzilla.opensuse.org/show_bug.cgi?id=952517#c7
Tony Su
participants (1)
-
bugzilla_noreply@novell.com