Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am getting this problem when checking the hostname of my server

Primary address     = 176.16.1.227

Current HostName    = grandcentral.xx.xx.xx

The DNS hostname is not available, please repair DNS and re-run this tool.

dirserv:success = "success"

How can I repair the DNS to ensure I get a result like

Primary address     = 10.20.30.3

Current HostName    = host.example.com
DNS HostName        = host.example.com

The names match. There is nothing to change.
dirserv:success = "success"
share|improve this question

1 Answer 1

The key to this is going to be making sure that your DNS servers are responding with the same information for forward and reverse lookups, and that the server is configured to be reachable.

hostname and dig are two great tools to help determine if things are correctly configured.

My suggestion is to start with dig -x 176.16.1.227 in order to find out what the DNS server is returning when queried for that address. If you get a server error, check your basic DNS configuration to make sure you are talking to the right servers. If you get a Not Found error, then you need to fix or create the reverse record for that IP address. The process for doing that can be complicated depending upon where your IP addresses are administered. For example, when using static IP addresses from an Internet provider, you often must have them create the mapping for you. However, when using private IP addresses behind a NAT, this is most commonly provided by an interna Server. Either way, the basic form is going to be a PTR record of class IN which looks like

227.1.16.176.in-addr.arpa.  IN PTR hostname.mydomain.com

Once your reverse is working, you should then verify that the forward request goes the same place. So, if your host name is www.foo.bar, then use dig www.foo.bar to look up the IP address. It should resolve to the same IP address.

If the forward DNS for the host name you are using doesn't match the reverse DNS of the IP address you are using, server won't be happy.

One other thing to consider is the primary IP address of the machine. When considering the host name, I have often found that OS X wants to get the host name and IP address from the primary network interface. For OS X, the primary interface is the one that appears first in the Network control panel. If this is out of order, use the Set Service Order... command in the Network settings to change the order.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.