0

I have read that on BSD/macOS/OS X, hostname is found from a search that includes a few places. One part of the search can be a reverse DNS lookup. For DNS lookup, I observe different behavior on different machines running the same version of the OS. When checked with host xxx.xxx.xxx.xxx, one machine ("MachineA") shows a reverse DNS entry xxx.xxx.xxx.xxx.in-addr.arpa domain name pointer MachineA.lan. The other machines report Host yyy.yyy.yyy.yyy.in-addr.arpa. not found: 3(NXDOMAIN). Only on MachineA does hostname show the .lan domain suffix (i.e., MachineA.lan). .lan is the domain supplied by the router, which is running openwrt. To restore hostname to a "normal" macOS domain value, I would like to change the router's DNS entry for the IP address of MachineA. That is, I would like to void the entry so that, as elsewhere, the reverse DNS returns null and macOS advances to the next step of its hostname value search. How can/should this be accomplished?

Note, I am aware that an option is to set a value in /etc/hostconfig or in /Library/Preferences/SystemConfiguration/preferences.plist via scutil but, these solutions would appear to deviate from "standard/default" macOS configuration. For similar reasons, I would like to avoid using a static address or setting a DHCP client ID.

jbjo
  • 101

1 Answers1

0

Reverse DNS checks a PTR record. Records seem to be stored in RAM. For me, restatring dnsmasq seemed to work: ./etc/init.d/dnsmasq restart. This may have flushed the cache. That is not a complete answer as something else must have changed in the config at some point such that restart was sufficient. Still, problem solved: host xxx.xxx.xxx.xxx now results in Host xxx.xxx.xxx.xxx.in-addr.arpa. not found: 3(NXDOMAIN).

jbjo
  • 101