13

Once in a while Finder stops connecting to SMB shares.

FinderCmd+KConnect → It shows a window like this infinitely: Finder dialog box connecting to SMB infinitely

What I've tried already:

  1. I have tried connecting to multiple shares (Linux, Windows), Finder didn't connect to any of them
  2. Connecting with an alternative client works. For example, Kodi media player includes its own SMB client and it connects just fine.
  3. Connecting from other running Mac works too
  4. Reset Finder settings by deleting ~/Library/Preferences/com.apple.finder.plist
  5. Kill Finder with killall Finder command
  6. Add username and password explicitly into the Cmd+K connect to server dialog: smb://myusername:[email protected]/MyFiles

I assume this is a macOS SMB client issue.

This issue will go away with a reboot. I'd like to fix the issue without restarting macOS – how can I restart SMB services only?

5
  • There’s no daemon for the SMB client like there is for the server. When you run into this problem, use Terminal and list the existing mount points; type mount in Terminal. If there’s already a connection to the server, try unmounting those volumes and then try your mount again
    – Allan
    Mar 24, 2020 at 13:18
  • I have no mounted network drives; mount command lists only local APFS drive related mountpoints.
    – babca
    Mar 24, 2020 at 16:06
  • A couple of things...can you try in Safe Mode (Hold Shift while booting)? Also, if possible, install an earlier version of macOS (don't wipe your internal drive!) to an external drive (flash drives are cheap now) and boot from that and see if the problem goes away. You're not reinstalling macOS, just putting a different version on a removable drive for testing. I have a suspicion it's an issue with Catalina.
    – Allan
    Mar 24, 2020 at 19:52
  • 1
    I can simply reboot the Mac and the problem goes away, but I'd like to fix it without rebooting and interrupting running programs - that's the key point of the question. There must be a Terminal command for that.
    – babca
    Mar 24, 2020 at 23:09
  • It’s not necessarily a Terminal command. The client isn’t working properly so we have to diagnose it. It could be a conflicting 3rd party app or kext; Safe Mode will help diagnose that
    – Allan
    Mar 24, 2020 at 23:13

3 Answers 3

14

I had the same problem, solved it by launching Activity Monitor and stopping netbiosd process, it gets restarted and then the connections started working immediately. It's possible that I also stopped NetAuthSysAgent process as well, so if it doesn't work for you with the netbiosd process only, try stopping NetAuthSysAgent as well.

3
  • 2
    FWIW I stopped netbiosd and it wasn't until I stopped NetAuthSysAgent that the connection started working immediately
    – RazerM
    May 29, 2020 at 16:11
  • Same here. Before I even saw the PID change on NetAuthSysAgent, the share mapped perfectly.
    – Hugh
    May 17, 2022 at 12:57
  • MacOS 14.0 (Sonoma) beta here. There didn't seem to be a netbios but as soon as I did killall NetAuthSysAgent -- boom, got the popup saying it couldn't connect and right after that the connection popup listing available volumes. Awesome!
    – Tom Hundt
    Aug 15 at 4:42
9

As stated by @yssup - Using the mac "Activity Monitor" tool to stop "NetAuthSysAgent" solved the problem for me.

Note that stopping "netbiosd" did not solve the problem.

Ideally one would do this by clicking on a shortcut to a shell script which could stop "NetAuthSysAgent" more quickly and efficiently. However, I cannot figure out the correct shell command to stop "NetAuthSysAgent" programmatically. Perhaps someone else can answer that here.

2
  • I too have had this problem, and killing NetAuthSysAgent does fix it. Presumably, you could just use killall in shell script, as killall does take a process name as an argument.
    – benwiggy
    Jun 9, 2020 at 21:45
  • Thanks! I'm using the command "sudo -S killall NetAuthSysAgent" in a script now, and it seems to work to solve the problem. For instance, I had a file management program which would hang and refuse to shut down when the problem occurred, but when "sudo -S killall NetAuthSysAgent" is issued, then the program shuts down instantly and everything seems to works fine when the program is re-run.
    – TFabris
    Jun 10, 2020 at 19:20
3

Alternatively you can achieve this with sudo pkill -i netauthsysagent. -i makes it case-insensitive.

3
  • Welcome to Ask Different SE and thank you for your contribution. When you get a chance, please take the tour to understand how the site works and how it is different than others.
    – agarza
    Sep 2, 2021 at 3:44
  • Excellent answer. +1. It would just be appropriate to add that it needs to be written in Termial.app, because (as later you will find out) the terminal is not very popular here. :) :)
    – clt60
    Sep 2, 2021 at 7:18
  • Thanks for the tour @agarza and thank you for that tip @jm666; I'll make use of it going forward.
    – GSheppard
    Sep 3, 2021 at 4:51

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .