Hostname not respecting search domain
Andrew Langhorn
andrew at ajlanghorn.com
Thu Aug 6 21:06:52 UTC 2015
Hello,
I have a machine running Trusty. I would have expected the output of `hostname -f` to respond with the hostname of the machine, followed by the search domain as set in /etc/network/interfaces or /etc/resolv.conf. For instance, if my search domain was set to `ajlanghorn.com`, and my hostname was `test01`, `hostname -f` should respond with `test01.ajlanghorn.com`.
Assuming I've not got any of the above wrong, I have a weird issue with the `hostname` command. Regardless of which flag I pass it - be that `s`, `f` or no flag at all - I always get the same response from `hostname` back, which is to give `test01` as the response.
There is a search domain set in `/etc/network/interfaces` and I've given one to `/etc/resolv.conf` using resolvconf, specifying the correct network interface.
Has anyone seen this before?
Thanks,
Andrew
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20150806/11aea8d8/attachment.html>
More information about the ubuntu-users
mailing list