Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

pedzsan

macrumors 6502
Original poster
I think this may be a Spectrum problem but I thought I would start here. As mentioned, I have Spectrum internet with two devices: a cable modem and a Wi-Fi router.

My Mac is suppose to be called "peace". At this point, `hostname` returns "peace.local". System Settings => General => About => Hostname has "peace" and Sharing => Local Hostname shows "peace.local". When I started this adventure I found that going to the "My Spectrum" app and finding the hostnames yielded a lot of problems and in particular, it listed the Mac as MacBookPro. A `dig peace` from the Mac returns nothing while `dig macbookpro` returns the Mac's IP address and the server is the local DNS in the Wi-Fi router.

I've rebooted the Mac as well as the cable modem and the Wi-Fi router but `dig` still returns the same answers. As I said, there were multiple problems. My iPad was simply called "iPad", etc. Maybe things will fix themselves when DNS entries time out somewhere... maybe? But as I recall DNS entries time out relatively fast -- like a few minutes.

Any suggestions anyone?
 
"peace.local" is your mDNS (Bonjour) name.


That's a different system of naming than the traditional DNS. "dig" uses traditional DNS and is asking your DNS server (presumably your router) for information. Your router set a DNS entry for your Mac. It probably set it up from some information it got from your Mac during DHCP negotiations to give your Mac its IP address.

I don't know anything about Spectrum and what you should do to get its DNS server using your mDNS name. The DNS server on your router delegates to the provider's server offsite for public names, but it is authoritative for your local machines. Perhaps there is some maintenance app that you can use to manage that on the router.
 
  • Like
Reactions: gilby101
As @svenmany says re mDNS.

For dig it really depends on your router and the DHCP interaction between it and your Mac. For example my router returns the IP address when I ask dig beth or dig beth.modem, but returns nothing for dig beth.local (my Mac is called Beth). The nothing response for dig x.local is the "correct" behaviour for a DNS responder which meets the DNS specs because the use of .local is reserved for exclusive use by mDNS/Bonjour.

In your case it looks like your router is identifying devices by model/type and not by hostname. Hence dig macbookpro works. I am guessing that Spectrum is your internet service provider (I have never heard of it - wrong country probably) so it is good that there is consistency in naming between the router and the service.

On my router I can edit the names that it uses for DHCP connected devices which have static IP addresses. You may be able to do something similar with your router and change the name from macbookpro to peace. But that may just causes more confusion - ymmv.
 
Last edited:
  • Like
Reactions: svenmany
I did a quick test, tracking the dhcp request as my Macbook Pro requests an IP address from my router. The Wireshark trace shows that the Macbook Pro, in its DHCP request, provides a "Host Name" of "MacBookPro". That is not the name I've given to that mac. I see no evidence in the DHCP request where the mac is telling the router the name I chose for the laptop.

As @gilby101 says, a DHCP static mapping might solve this for you. Or, your router might provide some way to configure DNS entries directly.
 
And - Exploding Kittens on Netflix mentioned Spectrum in the episode I just watched. That inspired me to get out of bed and do the little research I did. 🙂 Now, on to my regular workday.
 

Great input.

The second of the three is unrelated and I think relates to name collisions, but I haven't figured out how it happens. I think it might be related to having the mac simultaneously on multiple networks or accidental switch loops.

But the first and third seem to be on the money. That suggests that Apple feels giving away the host name is a vulnerability. I tested again on another computer and renewed my lease on the WiFi and then on the Ethernet. The Ethernet renew showed me providing my configured name. The WiFi renew showed me providing "Mac" as my host name.
 
Yes - your host name is obfuscated when "private wifi address" setting is enabled (which is the default).
 
Last edited:
  • Like
Reactions: pedzsan
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.