I have a Truenas Scale server set up on my LAN serving an SMB share. My desktop is running Debian trixie all up to date. There is a 2.5G ethernet link between them (10g on the NAS, limited by 2.5G on the desktop).
Debian is set up to automount the share via CIFS on boot time into a folder in /media.
When writing large groups of media files to the NAS, performance from Linux is very slow. It sends data only intermittently. When monitoring network traffic, you can see where the Debian file transfer window will show progress while network traffic is paused; then the file transfer window will stop moving when network traffic increases. It does this for the entire contents of a single file (e.g, 1.5gb at a time for the media I was moving).
It almost acts like it is filling an internal cache with the file then writing that cache out before streaming the next file…
Now, this is a Debian only problem. When I reboot into my Windows 11 install, this problem disappears- transfers run at full line speed as expected, no delays. So I am ruling out an issue with the Truenas box.
Is there a configuration setup in Linux that I may have set wrong for interfacing with an SMB share? Something I need to do to change? I’m not that good at the Linux, I was able to get the SMB share working from a guide but that’s about the limits of my knowledge lol.
edit: if it helps, I am just using CIFS to mount the drive using the following line in /etc/fstab:
//truenas.local/bruh2 /media/bruh2 cifs credentials=/home/<username>/.smbcredentials,rw,uid=1000,gid=1000 0 0
That is the only configuration I set.
I also found that post. They are talking about bad performance on the NAS side though with openmediavault- which I don’t have, when I boot into Windows on my main desktop there is no performance issue with the NAS whatsoever. Whatever I think is going on with mine it is debian (client) specific.
You should still be able to adjust client settings in /etc/samba/smb.conf
1.) Confirm this isn’t just a network issue by running an iperf test 2.) If above looks good, get samba and dmesg logs and post
Check ethtool to make sure your link is actually operating at 2.5gbit with full duplex. You may need to make sure the kernel module for that ethernet nic supports 2.5gbit.
I am running at 2.5g. Ethtool confirms it and in the screenshot I just added to the OP, you can see my max transfer rate is around the 280MB/s that I expect out of 2.5g. The behavior is not network speed limited.
The cifs driver is complex. I haven’t spent time tuning it in quite a while, but I once got rid of a performance problem by mounting with the nouser_xattr option, which can be included in a mount.cifs command or an /etc/fstab entry. That, or something else documented in the mount.cifs man page, might be worth a try.
Good luck!
FWIW, this is more likely Linux-specific than Debian-specific.
btw if both your server and clients are *nix, isn’t it better to use NFS?
Technically yes, but I have two windows machines that regularly need to access it as well and I preferred SMB to act like a real mapped network drive.
i see. btw, if you’re running win10/win11 they natively support nfs mounting. might be worth trying if you can’t solve this issue with smb.


