Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: Hostname and servername set in DA do not match..  (Read 14322 times)

0 Members and 1 Guest are viewing this topic.

Aby

  • Guest
Hostname and servername set in DA do not match..
« on: January 16, 2014, 07:09:02 am »
Your hostname, and the servername you have set in DirectAdmin, server.host.com

where the hostname is blank (note the ", ,"), a reported cause of this is an incorrectly setup /dev/null file.
First make sure the hostname isn't simply blank by checking:

Code: [Select]
/bin/hostname --fqdn
To ensure you get something displayed.
If you do see something, then the solution is to set it correctly:

Code: [Select]
rm /dev/null
mknod -m 0666 /dev/null c 1 3


Related:
http://directadmin.com/forum/showthread.php?t=37339
Another confirmed solution for when you get the error message:

Code: [Select]
hostname: Name or service not known
is to edit your /etc/hosts file, and change:

Code: [Select]
1.2.3.4   your.hostname.com
to be:
Code: [Select]
1.2.3.4   your.hostname.com your
such that you have both the long and short forms of your hostname beside your server IP.

If you do have a hostname in the output, eg:

Code: [Select]
Your hostname, bob.host.com, and the servername you have set in DirectAdmin, server.host.com, do not match.
it means you just need to update the hostname:
Admin Level -> Admin Settings -> servername
set it, and save.   You may need to change it to something else, then back again to re-sync it.
Also ensure that you have a full zone for the hostname in your dns:
Admin Level -> DNS Admin -> server.host.com
so that it resolves and has MX records
----