Samba works fine on startup then becomes sloooow / unstable

Hi everybody

as the title said i got a pretty annoying problem with the samba server sharing files from two external HDDs connected to the PI (3b+) which is connected via gigabit LAN to the home network.

i can access both HDDs just fine from my Windows(7) PC but after a while of actually accessing files (e.g. video playback, moving files around) the connection completely freezes (playback, explorer just halt). it then takes a minute or two to unfreeze but it never becomes stable again (freezing sporadically every minute or so).

it is not a problem with the network connection because SSH access works all the time even when Samba is in its frozen state.

i read somewhere that it might be due to the RPI not getting enough power, so i bought a 3A power adapter but that didn’t help either (the HDDs are connected via a separately powered USB hub anyway).

if anyone has an idea i’d very much appreciate an answer


What formats are the drives? If they are fat or NTFS; you could attach them to your PC and check them for errors.

Thanks Tom.

1 Like

I got a similar problem but only when i am doing more than one things via explorer to the external HD. If i am only copying a folder or something and leave it alone, nothing bad happens.
But if while copying i try to browse the drive again, or open a txt file or something the system might halt like you said.
But this is going on for ages now. Both on my pi2 and pi3 running osmc. I just learned to live with it. I think its a samba issue.
btw my external HD is Fat32…but i did have it ntfs as well when i had the pi2 on it.

I bet your HDDs are fine. I noticed you have a Pi 3B+. 3B+ has a flawed gigabit ethernet interface attached to legacy USB 2.0 that can not handle flow control of incoming gigabit traffic. Try installing ethtool and forcing the ethernet to 100 Mbit/s. Worked for me.

1 Like

thanks for the tip ill try that!

how stupid is that design though… that basically means that (as per hardware limitations) i can never have a stable gigabit connection to my rpi while accessing files stored on attached USB-devices? :man_facepalming:

just a quick heads up: apparently this is a general problem with the pi3. i found a workaround here:

even though i’ didn’t understand half of what i read there i found that installing ethtool and executing this command solves the problem reliantly:

now i’m still trying to figure out how to make this fix persistent after reboot. I tried adding the above line to /etc/rc.local but that didn’t seem to work… i still have to execute the command each time upon reboot:man_shrugging:


Try adding this to /etc/rc.local:

/sbin/ethtool -K eth0 tx-tcp-segmentation off tx-tcp6-segmentation off

sudo not required as rc.local is already run as root.

Thanks Tom.

1 Like

thanks for the reply.

unfortunately that didn’t work either… network connection craps out after a short while


Could you please post logs, after a reboot with the suggested line to rc.local:

grab-logs -A
dmesg | paste-log

Also what does systemctl status rc.local report?

Thanks Tom.

1 Like

ok turns out rc.local wasn’t even running…^^

i used this tutorial to activate it How to Enable /etc/rc.local with Systemd - LinuxBabe

now it’s active after reboot and network connection is stable!

thank you again for the quick help :slight_smile:

1 Like