Ask Your Question

Revision history [back]

hostname is different from /etc/hostname and /etc/hosts

On a new system install of Fedora 22 KDE my hostname was initially localhost but it changed on its own. It is now dhcpp5. There is no mention of it in /etc/hostname or /etc/hosts.

[sudhir@dhcppc5 ~]$ hostname
dhcppc5
[sudhir@dhcppc5 ~]$ cat /etc/hostname
localhost.localdomain
[sudhir@dhcppc5 ~]$ cat /etc/hosts
127.0.0.1               localhost.localdomain localhost
::1             localhost6.localdomain6 localhost6

hostname is different from /etc/hostname and /etc/hosts

On a new system install of Fedora 22 KDE my hostname was initially localhost but it changed on its own. It is now dhcpp5. There is no mention of it in /etc/hostname or /etc/hosts.. Is that some new naming scheme or a bug?

[sudhir@dhcppc5 ~]$ hostname
dhcppc5
[sudhir@dhcppc5 ~]$ cat /etc/hostname
localhost.localdomain
[sudhir@dhcppc5 ~]$ cat /etc/hosts
127.0.0.1               localhost.localdomain localhost
::1             localhost6.localdomain6 localhost6