Two utilities worth noting here, changeip and scutil. You can check if your name and hostname match using changeip. It will look at the DNS and look at the name your system has for itself and let you know if they match:
changeip -checkhostname
You can also use scutil to see what the hostname is:
scutil –getHostName
If you want to change the hostname:
scutil –setHostName <new hostname>
With the DNS, if the name server runs on the system you’re sitting at then you can edit the zone files on that system. Use dig to check whether the name matches the hostname. Think FQDN here btw, with Server…