Cannot resolve .local hostname after upgrading ...
I had the same issue and found out how to fix it: turn any of the sharing services ON in the system preferences. (File sharing worked for me).
For some reason .local hostname is kept turned off unless any of the sharing services is active. If you turn the sharing service off, the .local address will keep working for a minute or so and then get deactivated. > Running "host mymac.local" gives Host server.local not found: 3(NXDOMAIN). Which is normal > pinging the hostname gives "Unknown host".
Which is not normal
As Bonjour's Multicast Domain Name Service (mDNS) uses the ".local" suffix to identify Bonjour-accessible devices, are these two daemons running on your system:
1. /usr/sbin/mDNSResponder; and 2. /usr/sbin/mDNSResponderHelper
If not, which is very odd, then you need to manually restart them.
Open an Applications > Utilities > Terminal window and post the following command:
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.mDNSResponder.plist
mDNS will then be running again, and should also reload and run the next time your boot without further intervention. Hello piorange, Use something other than ".local". That is a private domain run by the operating system. I don't know how you managed to keep it running this long. Pretty much every OS update comes with people complaining that their custom ".local" names aren't working. mymac.local indicates that he has only being using the Bonjour service for a Mac on the network (possibly just his own) which is perfectly legitimate (see e.g. OS X Yosemite: Find your computer’s name and address) and it should be pingable. Of course, .local should not be used as a domain for normal DNS queries, but that's not what he is doing. Thanks so much for your help!
I tried to restart the mDSNResponder before but didn't resolve my issue. Quite weird i think and i totally ran out of ideas Thanks for your help, etresoft!
As trevoz said, i am only using this at my own local network so it shouldn't be a problem. Is mDSNResponder running? What's the output of the Terminal command:
ps -ax | fgrep -i mdns In the meantime i had to downgrade to El Capitan so now it is working again. In a few days when i have more time to fiddle with this, i'll upgrade back to Sierra and gonna post back the output here.
Thanks a lot, trevoz, your help is very appreciated piorange did say "hostnames", suggesting more than one, and has been mucking around with Apache files. Hello again piorange, But the question is whether you have added your own .local host names using the /etc/hosts file. That is always going to be a problem. Try some other suffix and see if it works. Thanks, etresoft! I meant "hostname", not "hostnames", sorry.
I don't want to add the hostname to the /etc/hosts file as i do want that hostname to be accessible from other devices on the network. Hello again piorange, Thanks for the clarification. You can ignore my previous replies.
Try to change your host name in System Preferences > Sharing. If that works, try to change it back. Thanks, but of course i've tried that. I wish to solution was that easy Have a great day! I had some spare time now so i upgraded again to macOS Sierra and i have the same issues again :/
Running ps -ax | fgrep -i mdns gives me this: 181 ?? 0:00.33 /usr/sbin/mDNSResponder 183 ?? 0:00.07 /usr/sbin/mDNSResponderHelper 625 ttys001 0:00.01 fgrep -i mdns I had the same issue and found out how to fix it: turn any of the sharing services ON in the system preferences. (File sharing worked for me).
For some reason .local hostname is kept turned off unless any of the sharing services is active. If you turn the sharing service off, the .local address will keep working for a minute or so and then get deactivated. 最后更新:2017-09-23 13:20:45 上一篇: |