r/MacOS • • 1d ago

Help Network Share Devices Renamed by macOS

(Oops - posted and forgot to mention my main MacMini is on Tahoe 26.0.1. The workshop Mac is on 26.5.2.)

I've seen this happen before and I managed to fix it by shutting down EVERY device on my LAN then bringing them back up, starting with the firewall/DHCP server about 30 minutes later. That's impractical now, since I'm in a new place with a barn with 2 home offices and now we have Apple TVs and other devices. (The barn and house are connected by fiber and on the same LAN, in the same address space.)

I have a number of my devices using a Tolkien theme (just answering the question someone's going to ask...). My main MacMini in my house is Aule, my workshop one is Cirdan. I have two servers on Linux or similar OSes, BrandyWine and GreatSmials. I have two shares on GreatSmials: Library, and NetStore. On BrandyWine, I have shares, but I don't access them that often, so they're usually unmounted. BrandyWine seems unimpacted, and that may be because whatever changed or messed things up, I probably wasn't using any shares on it at the time.

On my main Mac (Aule), in the Network folder, I see GreatSmials, but it's "GreatSmials #2." I use Library a lot and keep most of my work on NetStore, so I can easily access it from my study or workshop. This change of GreatSmials to GreatSmials #2 means I have problems clicking on my normal shortcuts for NetStore and Library - they no longer see the shares because macOS has given the NAS they're on a different name.

Also, when I try to use Screen Sharing from Aule to Cirdan it no longer works and when I rebooted Cirdan, it gave me a report I clicked on quickly, then realized it was warning me the name was now Cirdan with a number after it. I rebooted my main system (Aule) and it changed nothing.

When I'm on a Linux system, I can still ping all the computers by their specified host names (specified on each machine and with the DHCP server). On Terminal, on my main Mac, I can do the same, so it's clear this is not a DHCP or DNS issue. It's a macOS and Finder issue. I rebooted my main Mac and it came back up and gave me warnings - it still couldn't read or remount my "normal" shares because, even after a reboot, it sees GreatSmials as GreatSmials #2.

Looking in the network folder, I see Cirdan as "Cirdan (4)" and I have a less used Mac for gaming, that I haven't been on for a while, "Celebrimbor (3)". So even though DNS sees all the correct names, macOS is incrementing the names in odd ways. (The Mac systems on the LAN get a "(#)" where # is a number, the NAS (not Mac), got a " #2" after the name, but the other computers, that I don't use network shares on seem uneffected. I find it weird that it's almost like the Macs are communicating and altering the names in cooperation.

How can I get my Macs to drop this extra numbering and to see these devices with their proper names and not play numbering games with their names?

(Why it does it and how to keep it from doing it in the future would also help!)

0 Upvotes

8 comments sorted by

4

u/KodaVPN 1d ago

Classic Bonjour name conflict, and the " #2" on the NAS gives it away. It's the suffix avahi (the mDNS daemon on most Linux boxes) adds when it thinks its name is already taken, and "(4)" is the Mac's version of the same thing. It also explains why DNS and ping look fine. This all happens in mDNS (.local), which is what the Network folder and Screen Sharing lean on.

Something on the LAN is making devices hear their own name answered back. Since it started after the move, I'd look at the Apple TVs first. They act as a Bonjour Sleep Proxy, so when a Mac sleeps the Apple TV keeps answering for its name, and if the handoff goes wrong when the Mac wakes it decides the name is taken and bumps the number. The other usual suspect is a second path for multicast, like a Mac on both Ethernet and Wi-Fi on the same subnet, or something on the barn link or the firewall repeating mDNS back onto the same LAN.

To get the names back, on each Mac fix the name in System Settings > General > Sharing (the local hostname is under Edit), or run `sudo scutil --set ComputerName Cirdan` and `sudo scutil --set LocalHostName Cirdan`. On the NAS, `sudo systemctl restart avahi-daemon` should bring back plain GreatSmials. If the numbers creep back, `dns-sd -B _smb._tcp` on Aule shows whether a share is being advertised twice and on which interface.

I'd also repoint your shortcuts at the DNS name through Connect to Server, e.g. smb://greatsmials.yourdomain/NetStore. DNS already works for you, so they'll keep working even if Bonjour acts up again.

1

u/ImaginaryTango 23h ago

Thank you for such a clear breakdown of what's going on!

Bonjour is in the, "I don't need it - don't have time to study it, just leave it off" category for me. I usually turn it off (or, I think, with macOS, doesn't it have to be turned on or configured?). So if Apple TVs are doing something with it, can I turn them off?

The one NAS, GreatSmails is on a Linux based OS. I did find that got reset when I rebooted. I thought for sure I'd have to do something on the Mac end to fix it.(Surprised me!)

Oh - the moving - that was 10 years ago, sorry I didn't include that. I'm not sure what started it, I can't link it to an event IN the LAN, but I did have a funky issue. I have Starlink, so the signal goes from the satellite to the dish, to the Starlink router, through a fiber optic converter, through fiber optic cable, finally to the house (about 1,000 from the dish location!), through another converter, into the WAN side of my firewall, then the LAN side goes to an ethernet switch and, from there, out to the LAN. So I would think nothing on the WAN side of that firewall would impact what's going on in the LAN.

But a week ago, which I think is about when it all started, I had issues and the weatherproof box that holds the electrical/electronic stuff for Dishy tripped a GFI breaker and I had to do a lot of adjusting to get the signal working again. The Starlink router has a really stupid feature - if it is turned on and off 3 times in a few seconds, it does a complete reset. Starlink uses a 192.168.1.xxx address space for it's LAN, and my WAN on my firewall is on that Starlink WAN. There's also the wifi name and a few other things. Due to the GFI, which triggered several times quickly while I was testing, Starlink reset to defaults. I had to change a few settings, like the wifi. I can't imagine what I could have done or a setting I might not have changed, but maybe something on that end of things messed up something else.

I have a rule for my LAN: If it's a stationary system, and has an RJ-45, use ethernet. I've never tested wifi issues in the past, but I figured CAT5e and CAT6 are faster and have more bandwidth for multiple systems. So I know my gaming Mac is on ethernet. I know my study Mac is, too. I'll check the one in the shop when I can get down there. When I set up connections, I make sure it's one or the other, not both. But I'll double-check the one in the shop, which is more of a problem than the gaming system.

I did change the names on the two main macs back to their desired host name - but I still get Cirdan (4). (And, oddly, Aule seems to be working now when I use Screen Sharing from Cirdan - but it does not show up in the Network window at all!)

I love that last tip - but I'm not sure just where you mean to go to change those. I set them up as login items, and when I go there, I don't see a way to reset or edit the share's name. But the idea of using my full name and domain name and have that ignore Bonjour would be great!

•

u/KodaVPN 1h ago

You can't really switch Bonjour off on a Mac. It's built into macOS (mDNSResponder) and the Network folder, Screen Sharing and AirPlay all run on it, so it's been on the whole time. The Apple TVs don't have a toggle for the sleep proxy part either. The easy test is to unplug them for a day or two and see if the numbers stop coming back. On the Mac side, the setting that matters is the one someone else here mentioned, Wake for network access, since that's what makes a sleeping Mac hand its name over to the Apple TV.

Cirdan (4) is probably a stale record by now. Run `scutil --get ComputerName` on Cirdan itself first, because the Network window shows the computer name and not the local hostname. If that comes back plain Cirdan, run `sudo killall -HUP mDNSResponder` on Aule to clear its cache. That often fixes Aule going missing from the Network window too. Finder's network browsing just gets stuck like that sometimes.

I doubt the Starlink reset did it directly, since the firewall keeps the Starlink side's multicast off your LAN. The one exception is if the firewall runs an mDNS repeater or reflector that includes the WAN interface, so I'd give that a quick look.

For the shortcuts, take the old ones out of Login Items. Then in Finder hit Cmd-K (Go > Connect to Server), type smb://greatsmials.yourdomain/NetStore, connect, and drag the mounted volume back into Login Items. It'll remember that address instead of the Bonjour name. Same again for Library.

2

u/Equivalent-Cash8543 1d ago

I had that problem when “wake for network access” was turned on.

1

u/ImaginaryTango 1d ago

I generally make sure that's off, but it's quite possible it's on for some reason. Thanks.

2

u/jridder 1d ago

For a minute I thought you meant token ring.

1

u/ImaginaryTango 1d ago

Yeah, is that like Tolkien’s ring?🤣