Until recently, I’ve been working on a Mac using Yosemite 10.10.5 and was quite happy with it, but since Sierra 10.12.2 was out, I knew I had to move on in my life, so I decided to make a clean installation (dual boot) of El Capitan to the latest available version 10.11.6 including all recent updates from Apple. However, I soon realized that my connections to both network backup HDDs via SMB was painfully slow, evidently much slower than I was used to, when synchronizing files from my Mac to my Western Digital network drives.
This meant that Apple most likely fiddled again with SMB (Samba) protocol in this OS X release, and once more we had to find a fix for returning to “status quo”. After all, I was using on my Gigabit home LAN two different WD network storage devices, namely MyBook II World (2x1TB) and MyCloud (1x2TB), most likely with different SMB implementations each.
I had read that in the older days, a quick solution to force Mac OS X to use older SMB versions, was to use CIFS protocol; but today, this didn’t work. So, this time I mounted via Finder both drives (Cmd + K) forcing the smb:// protocol:
Next, in Terminal.app the following output was presented, after running the needed query command
smbutil per volume:
This showed that older MyBook World II negotiates with SMB 1.x protocol (latest firmware v01.02.14 available) and later MyCloud storage asks for SMB 2.x protocol (firmware v03.04.01-230 kept on purpose) therefore causing a possible performance issue with latest Mac OS X systems, due to their newer and seemingly more secure SMB implementation.
After digging around, I read that there’s a hidden fix for SMB, just like the one posted by Dan Roncadin in his related article, which apparently increases transfer speeds due to the fact that it disables “client signing”. As Dan Roncadin writes:
The issue seems to come down to Apple’s SMB forcing default enabling of “client signing” which ruins performance.
The fix consists of setting a parameter in file nsmb.conf in folder /etc/ with sudo privileges, forcing the system to obey the parameter on the next use of SMB protocol (and after each reboot, obviously):
The way to implement this parameter is to quickly open Terminal.app and apply this command as your administrator password will be requested:
sudo printf "[default]\nsigning_required=no\n" | sudo tee /etc/nsmb.conf >/dev/null
Then, either restart your Mac (if you’re used to do this, due to some older Windows habit like mine) or simply unmount and re-mount your SMB shares. Please note that on a clean installation of El Capitan, this file (and therefore, parameter) does not exist, due to the fact that Apple considers this a lesser security measure; but for home connections, it is fine by me.
Through the application “GoodSync” I was able to re-check the speed and it seems things returned to normal; I didn’t go into much detailed speed measurements, but I am sure any improvement is welcome at this stage. Also, this is confirmed to have a positive effect on speed, as mentioned by users over at Computer Audiophile where they post their (positive) results after applying this fix.
Finally, should you wish to reverse the “fix”, simply remove this file (better via Teminal, again) by running:
sudo rm /etc/nsmb.conf
References and articles:
- Dan Roncadin: How to fix slow SMB file transfers on OS X 10.11.5+
- Computer Audiophile: If you have a NAS, beware OS X 10.11.5
- Apple Discussion Communities: El Capitan 10.11.5 update SMB slow (bug)