Announcement: Upgrade to macOS Mojave

With features like Dark Mode, Stacks, and four new built-in apps, macOS Mojave helps you get more out of every click. 
Find out how to upgrade to macOS Mojave > https://support.apple.com/macos/mojave

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Question:

Question: AFP/SMB Directory Listings very slow in Finder

Hello comunity!


Since the upgrade to OS X Mavericks we are experiencing server problems, browsing AFP/SMB shares on remote servers (VPN). The Directory Listing is very slow an can take up to 30 minutes for large listings.


Here's the setup


  • 2 networks are connected thanks to a VPN connection.
  • All clients, in all connected networks can communicate to a common fileserver (MacPro with OS X 10.6 SnowLeopard Server) in Network A
  • Firewall is not an issue between those networks
  • The fileserver also has other network services set up (DNS, Mailserver, SMB, AFP, Firewall, ...)
  • The clients authenticate via OpenDirectory and Kerberos to the fileserver


So the problems occur if i want to connect a client on network B to the server on network A. Connection, authentication, ... all good. Even the performance over the VPN, to tranfer files is OK. But browsing subfolders is catastrophic. I used AFP and SMB alike, results are the same.


I also made tests on older clients, to see if the fileserver is the problem. 10.6 and 10.8 clients can browse normally, speed is OK. Even Windows Clients can browse normally all the subfolders of the fileserver.


I analyzed different approaches made here, but none of them worked:

  • Connect to share with explicit port
  • Connect to share with FQDN
  • Connect to share with port 445 (SMB)
  • Setup an nsmb.conf with notify_off=yes
  • ...


I also did analyze different logs and there's something i found, but can not say if it's connected. I did see many log entries like this:

...

29.10.13 12:21:51,960 icbaccountsd[775]: -[ICBLocalDictionary writeLocalMapping:]: Status: Writing out local mapping to disk

29.10.13 12:21:51,960 icbaccountsd[775]: -[ICBLocalDictionary writeLocalMapping:]: Status: Ending writing out local mapping to disk

29.10.13 12:21:51,960 icbaccountsd[775]: -[ICBRemoteDictionary writeDevices]: Status: Writing out of devices

29.10.13 12:21:51,960 icbaccountsd[775]: -[ICBRemoteDictionary writeDevices]: Status: Ending writing out of device

...


I also saw tha a process "icbaccountsd" was often coming up an using all of my CPU, when i start browsing the share. Thus i could not find any documentation on it.


So my question: What can I do to accelerate the browsing of my AFP/SMB shares for all my Mavericks clients? What can I do to speed up the Directory Listing? And yes: i know about solutions like PathFinder, TotalFinder, .... but i'm more interested in a native solution to this problem.


Thx!!

OS X Mavericks (10.9), 10.6.8 Server

Posted on

Reply
Question marked as Helpful

Nov 26, 2015 6:50 AM in response to TenjuZenjin In response to TenjuZenjin

!! Possible solution that worked for me - at the moment !!


Hello,


I also got the problem that browsing an afp share gets very slow.

My Share is little over 5TB big with much media data.


I tried all the solutions that I found on this forum but nothing helped as much as what I just found.


After spending many hours today to find a solution I finally turned on wireshark to have a look whats going on on port 548 (AFP over TCP Port)

I saw that whenever I opened a folder many requests were send to the server - my guess was that the finder is requesting the little preview images because inside of each request was a filename of the folder I just opened.

My guess is that whenever you open up a folder, OSX sends multiple requests to the server to get the preview image.

The server tries to answer all the requests but when you navigate to another folder the next requests for this folder are sent - kind of DDOS.


After realising this, I went to the root share, right clicked -> Show Vew Options and turned off Show Icon Preview.

The result was phenomenal - afp was fast and the traffic on port 548 was shut down very drastic.


I would like to hear if this solves the problem for others too or if I'm the only one where this helped

Question marked as Helpful

Apr 14, 2014 7:22 AM in response to TenjuZenjin In response to TenjuZenjin

I went through a bunch of the steps in this thread with no luck.


Ended up forcing the Macs to use SMB1 until this is fixed by Apple:


echo "[default]" >> ~/Library/Preferences/nsmb.conf; echo "smb_neg=smb1_only" >> ~/Library/Preferences/nsmb.conf


That's all one line and it fixed the issue for use instantly. No reboot required.

There’s more to the conversation

Read all replies

Page content loaded

Oct 30, 2013 11:07 AM in response to ramz225 In response to ramz225

Nope. Working on it, but no solution in sight. Meanwhile i had to switch to SSHFS/SFTP to get productive again. Dont ask... SMB, AFP, NFS, FTP, .... nothing wanted to work and also SSHFS was'nt easy, due to timeouts, connection drops and file permissions. But i managed to get it working.


I hope Apple get's things done very soon! I rely heavely on networks and it's quite a shame that connecting Windows and Linux clients to an OS X Server (10.6.8) is easier and more reliable than connecting Mac clients. No joke; sad but true...


PS: and no, i wont upgrade the server to Mavericks Server... after what happened with my last OS X Lion Servers... *outch*

Oct 30, 2013 11:07 AM

Reply Helpful

Oct 30, 2013 11:16 AM in response to TenjuZenjin In response to TenjuZenjin

Im showing my ignorance here but could you tell me how to do that switch to sshfs I read a few tutorials on it and tried but got lost I down load fuse and sshfs and installed then but got messed up with terminal and putting in the right info? I to rely completely on the server to work im at a stand still

Oct 30, 2013 11:16 AM

Reply Helpful

Oct 30, 2013 11:31 AM in response to ramz225 In response to ramz225

Dont argue with those thingsto much.


Just download and install those 2:


I did get it working with those. I also generated an RSA PUB Key the i installed on the server for authentication. Read this, it's worth it: http://www.thegeekstuff.com/2008/11/3-steps-to-perform-ssh-login-without-passwor d-using-ssh-keygen-ssh-copy-id/


Optionally, if you run into some problems you can also give some extra options to MacFusion. If you want to know which ones, check this out: http://jann.is/daily/archives/757-ExtraAdvanced-options-for-MacFuseMacFusion.htm l


I think that should help you to get it up and running.


Keep in mind that it's only a temporary solution, until Apple fixed the problems...

Oct 30, 2013 11:31 AM

Reply Helpful

Nov 2, 2013 6:07 PM in response to TenjuZenjin In response to TenjuZenjin

Experienced similar problems; most probably due to problems with the browsing client's Finder using .DS_store files on the remote server. The deeper into the remote server's directory tree you browse, the longer the delay. All good though after typing the following in Terminal (no SUDO needed) and rebooting the client.


defaults write com.apple.desktopservices DSDontWriteNetworkStores true

Nov 2, 2013 6:07 PM

Reply Helpful (2)

Nov 4, 2013 12:46 AM in response to -KEPHSTER- In response to -KEPHSTER-

Thx -KEPHSTER-!


I already followed that approach but it did not change much. I did set the client so that they wont write .DS_store files and also instructed the server so he would noch "accept" them and clean them. Browsing was not faster in any way...


Like you, browsing from on level to another deeper level, it slowed down with every level i did go deeper. I also experienced some sort of caching, wich speeded up things a little. But once the drive disconnects, the cache was purged too.


On the server i saw something quite strange. It seems that, upon connection from a client, the 10.9 client requests the whole folder tree, what a 10.8 and below client did not. With a tree af many thousand folders and even much more files, this could be a huge slow down. Might be hint...?

Nov 4, 2013 12:46 AM

Reply Helpful

Nov 11, 2013 2:35 PM in response to TenjuZenjin In response to TenjuZenjin

I also have the same problem running on a synology NAS disk station (with SMB2 support for mavericks update installed).


  • Running a windows 8 VM on the same machine as Mavericks loads the share in seconds, the same folder in Mavericks takes 30mins plus.
  • To confirm https (WebDAV) is no quicker either (to add to TenjuZenin's list above)
  • I'm on a LAN so I can't image how painful this would be on a VPN.


Apple, please can you provide some enterprise support for file shares and other basics (including iSCSI). It can (and does) take hours to do basic file maintenance jobs which takes minutes on a PC.

Nov 11, 2013 2:35 PM

Reply Helpful (1)

Nov 14, 2013 1:58 PM in response to TenjuZenjin In response to TenjuZenjin

As with everyone here, I'm experiencing the exact same issue. I've used the solution to force the network connection using SMB1 (via the CIF protocol).


However the implementation by Apple and without clear warning has ground my business to a halt with problems due to not being able to access the server. The solution isn't guaranteed to work.


Maverick's was in beta for 3 months and has now been out for over a month. This should have been resolved by now and the fact that everyone except Apple have made comment is unsatisfactory.


This has got to be fixed as a matter of urgency or a valid workaround.

Nov 14, 2013 1:58 PM

Reply Helpful

Nov 14, 2013 3:00 PM in response to chattphotos In response to chattphotos

Thank you for a quick reply to my post charrphotos.


I'm no network or protocol expert but able to follow instructions and understand the technical rudimentaries.


As shares have been easy to connect to as Bonjour/zeroconf have developed, I haven't needed to look at other protocols such as NFS. Help on this would be welcome.


In this scenario, I was in the midst of moving all the business data from a simple Netgear Stora (clearly based on a Linux OS) to the Mac temporarily. Therefore NFS could be supported but I'm not sure because the only interface to configure the Stora is web-based. I never really use it since it's just a storage vehicle (that currently isn't moving at all).


It's all setup on a one-subnet straightworward LAN. The Mac and the NAS are connected to the same switch. I've tried this on another Mac and the result is the same.


Internet access isn't necessary and therefore there is no VPN to complicate matters. All I need to do is a simple copy of files but the directory structure is quite lengthy which is probably exacerbating the issue. However in the directories I have been able to access, copying is impossibly slow.


Do I force the NFS protocal via the Finder? Also will the Stora recognise that protocol without hacking?

Nov 14, 2013 3:00 PM

Reply Helpful

Nov 14, 2013 4:42 PM in response to dpasarchi In response to dpasarchi

To note, I replied to the OP...

You network setup is quite different from the original post, so the troubleshooting steps may be different.


To attempt an NFS connection:

Connect to Server (Command + K) NFS://server.name.ip.here


Is your network Gigabit (1000mbps)?


If not, there will be a bottleneck if anything is going over a 10/100mbps port which sounds like that may be your issue.


Do you use any Wifi connections?

Nov 14, 2013 4:42 PM

Reply Helpful

Nov 14, 2013 11:42 PM in response to TenjuZenjin In response to TenjuZenjin

To reply to the new informations: yes, i did try NFS and it was as slow as AFP and SMB2. I also did try to force to SMB1 using CIFS, with no better results as SMB2. I think all those protocols are based on the same implementation. That's why switching protocols does not offer any relief.


The only solution thats seems practicable for the moment is SSHFS/SFTP. The directory listings are quick, browsing is fast and file transfers are quite comfortable. I think the SSH protocol is the only one that they left untouched and is still based on the original OpenSource implementation. It's sad that you have to think first:"What did Apple not touch?" to get to a working solution...


Note that using SSHFS/SFTP is a quick and dirty fix and should not be used further in the future. I'm hoping Apple fixes this URGENTLY! I'm also conerned about the fact that Apple until now did not commented this issue, even to just say:"OK, we will fix this ASAP".


Also note: i tested all teh protocols on other clients with other systems (Windows 7 and OS X with Snow Leopard or Mountain Lion) and they all did not have any problems with any of the cited protocols. I did not try OS X Lion because IMHO it's not a working system, it's a **** of a mess.

Nov 14, 2013 11:42 PM

Reply Helpful
User profile for user: TenjuZenjin

Question: AFP/SMB Directory Listings very slow in Finder