SMB first fast then slow then dead

Tampa

Cadet
Joined
Jun 17, 2020
Messages
3
I recently had to reinstall freenas 11.1 u7 because the latest version with btx bricked the bootloader. Since I could not transfer settings over I had to redo them all.

Freenas System:
HP Microserver Gen8
Intel(R) Celeron(R) CPU G1610T @ 2.30GHz
16GB Ram
2x WD Red

I was able to import the old pool and am now trying to move data out of it to redo the system once more. The problem I run into however is that the SMB share is not working right. When initiating a transfer at first the speed is over 100mbps as per the gigabit line that it uses, then after about 2-3gb the speed goes down to about the drive speed of the offloading drive I use, around 20-30mbps, which in itself would be fine, but it does not stop getting slower. After about 5gb transferred data the transfer speed is 0. No data is moving at all.

According to reporting when those transfers happen the memory usage, cpu usage and disk io is well below the maximum for the system. Disk transfer is below 5mbps. Arc size immediately goes up to the maximum of vdev cache set and stays there forever, even after stopping the transfer. Hit rates and data requests are all over the place. I searched the old settings db for further changes, but I cannot find what else I had changed before redoing the system. Previously, moving the data I am pulling into the system I observed similar issues of large write operations slowing down or failing entirely, but I was able to move up to 15gb at a time without issues or significant slowdowns.

I tried setting up 3 tunables for vedv cache, kmem and arc max size I had from the previous install, setting them to relatively low values of 500-1500M to discourage use of any caching and simply read directly from the drive. I don't care for speeds, I need these transfer to actually work in the first place.

On the local machine I already upped the buffers and caches of the network driver to encourage it to handle part of the transfer as well as disabling large file offload. I setup a dedicated partition with large block sizes to aid the transfers, but to no avail. All files over 5gb in size effectively fail to transfer at all. Even using a third party software to do the moving rather than windows explorer yields the same results.

I increased the vdev, arc size and kmem to almost the size of the memory on the system to attempt a full caching of the files for the transfer, but that yields the same result as well. I read about 4 dozen threads on smb and what might help, but nothings been conclusive or straight up said what settings to use.
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
First, delete all your tunables and reboot, to get back to factory default state. Also back out the tuning changes you made to your local system.
Next, run iperf to make sure your NIC is operating at rated speed. Also run some dd copies to see if your disks are running at rated speed.
Finally, enable autotune in System->Advanced, and reboot. This will set various tunables after the reboot. Note these tunables and their values. You should use these as baseline settings for tuning, after disabling autotune and rebooting again.
 

Tampa

Cadet
Joined
Jun 17, 2020
Messages
3
That both disks and network run properly I already determined and I do see proper 100mbps transfer initially when starting transfers, but they slow to a crawl or straight up fail.

I nuked vdev, kmem and arc sizes down to just a about 300mb and now 10-20gb transfers run at about the speed of the disk array 20-30mbps, which is fine. However a large transfer of 200gb is stuck at 2mbps and will likely take days to complete. The larger the transfer the worse the performance it seems and I cannot figure out why.

Last time I let it do autotune all it did was set my caches to basically memory size which only made the problem worse, hence having them set much lower last time this system was working properly. Transfers being fast and then slowing I have seen last time as well, after a couple gb caches are full and drives are slow so 30mbps is generally average, but not even 2mbps just does not make sense. The system is under almost no load, the destination IO load on that disk is low enough that I can transfer files on my local machine to it at 10mbps without impact to the larger transfer from the nas.

It is as if something caps the speed based on the size of the transfer.
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
OK, so I believe you're seeing buffering on the sender side. Have you tried copying using eseutil, which doesn't buffer?

 

Tampa

Cadet
Joined
Jun 17, 2020
Messages
3
Well I am not on an exchange server so I do not have that tool available. The problem shows up both directions, but more so on sending from freenas to windows. I am trying freefilesync, but I doubt it will yield much better results. If I can find a download for eseutil I will try that.
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
You can also accomplish unbuffered copies via robocopy /j.
 

no_connection

Patron
Joined
Dec 15, 2013
Messages
480
Do a file transfer with TeraCopy and see how that does.


But where there is smoke there is SMR. Or something like that.
 
Top