Linode Forum
https://forum.linode.com/

CentOS hostname -f returns hostname: Unknown host
https://forum.linode.com/viewtopic.php?f=19&t=8568
Page 1 of 1

Author:  bigclaw [ Tue Mar 13, 2012 10:34 am ]
Post subject:  CentOS hostname -f returns hostname: Unknown host

Hello, does anybody know why hostname -f returns "hostname: Unknown host" for me?

I just set up a CentOS 6 (32-bit) 512MB linode and followed the CentOS wiki to change my hostname to somehostname. I did it by doing the following:

Code:
$hostname somehostname


Also the new hostname permanent by modifying HOSTNAME in /etc/sysconfig/network (HOMENAME=somehostname).

I rebooted the instance even. I now see my correct hostname in the PS1 prompt and if i do just "hostname". However, I couldn't get the full name somehow.

Anybody had a similar issue and know how to resolve it? Thanks!

Author:  jbenamy [ Wed Mar 14, 2012 1:50 pm ]
Post subject: 

Did you follow this guide? http://library.linode.com/networking/co ... tos-fedora

Author:  Nibbler [ Wed Mar 14, 2012 6:37 pm ]
Post subject: 

It will do that if the hostname is not resolvable. Make sure you actually have a DNS record for the hostname.

Author:  bigclaw [ Mon Mar 19, 2012 12:23 pm ]
Post subject: 

jbenamy wrote:


Yes I did.

Nibbler wrote:
It will do that if the hostname is not resolvable. Make sure you actually have a DNS record for the hostname.


I think this may be my problem.

Thanks for the replies!

Page 1 of 1 All times are UTC-04:00
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/