Brand new MacBook Pro - unboxed just a few minutes ago. It's running macOS Sequoia. DNS to external works just fine, and my other devices, including an iPhone and an iPad, work just fine with internal DNS.
I run Pihole internally for both the ad-blocking benefits as well as provide an authoritative DNS server for the various applications I run on my internal network.
I'm able to perform a dig for internal resources and get the expected results, as seen here:
me@MacBook-Pro ~ % dig storage.home.lan
; <<>> DiG 9.10.6 <<>> storage.home.lan
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 55954
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
;; QUESTION SECTION:
;storage.home.lan. IN A
;; ANSWER SECTION:
storage.home.lan. 0 IN A 172.16.10.5
;; Query time: 4 msec
;; SERVER: 172.16.10.2#53(172.16.10.2)
;; WHEN: Thu Dec 12 19:58:25 MST 2024
;; MSG SIZE rcvd: 61
But trying to SSH, use a web browser, or ping to these internal resources fails. I've found DNS not resolving on Mac OS X and DNS not resolving on Mac OS X but attempting to bounce Discovery and mDNS both fail:
me@MacBook-Pro ~ % sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist
Password:
Unload failed: 5: Input/output error
Try running `launchctl bootout` as root for richer errors.
me@MacBook-Pro ~ % sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist
Load failed: 5: Input/output error
Try running `launchctl bootstrap` as root for richer errors.
me@MacBook-Pro ~ % sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.discoveryd.plist
Unload failed: 5: Input/output error
Try running `launchctl bootout` as root for richer errors.
me@MacBook-Pro ~ % sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.discoveryd.plist
Load failed: 5: Input/output error
Try running `launchctl bootstrap` as root for richer errors.
I've rebooted for fun but that didn't change anything either.
Edit: Just to be abundantly clear - this also affects web browsers. It is not just a terminal problem.
I've narrowed the problem down to MacOS is preferring the public DNS server 1.1.1.1
for all DNS queries except for oddly dig
. Once I set the DNS to just the internal DNS server, things work fine. I wouldn't consider this a fix per se as I should be able to use an external DNS server should the internal one fail, but this addressed it.