Page 1 of 1
[SOLVED] Very slow browsing in folders
Posted: 10 Nov 2013 00:17
by HolGORE
hey together,
i have my NAS since 4 weeks.
http://www.sysprofile.de/id178006 <-- here the hardware list but with a Intel network card.
the read/write speed is fine for me. Im using a RAID5 @ ZFS. 4 x 3TB Red.
Write ~70 mb/s
Read ~ 70 mb/s - 90 mb/s
(belongs on the size of the files ofc)
but i have a big problem. if i want to browse in my music folder for example, it takes ages to load it. and if im already listening to music and want to brose the song stucks for 2-3 secs, playing for 2-3 secs and the same.
after the music folder has been loaded everything works well. if i want to get in a folder the same procedure.
in the music folder are ~1000 folders.
Is there any way to fix this?
Thank you all in advance
regards
Holgore
Re: Very slow browsing in folders
Posted: 11 Nov 2013 17:52
by kenZ71
Anything in your system logs?
What is trying to play the music and how is that item connected ? Have you tried other PCs to play the music ?
Re: Very slow browsing in folders
Posted: 12 Nov 2013 08:29
by b0ssman
check with zfskerntune if prefetch is enabled
Re: Very slow browsing in folders
Posted: 13 Nov 2013 02:26
by 00Roush
I ran into this issue a while back while testing performance of NAS4Free versus my Windows Server. Mine was for folders of pictures.
Uncheck the box for Enable store DOS attributes under the CIFS/SMB settings page.
Let me know if that helps.
00Roush
Re: Very slow browsing in folders
Posted: 13 Nov 2013 09:32
by HolGORE
00Roush wrote:I ran into this issue a while back while testing performance of NAS4Free versus my Windows Server. Mine was for folders of pictures.
Uncheck the box for Enable store DOS attributes under the CIFS/SMB settings page.
Let me know if that helps.
00Roush
THIS helped me!
now its working fine
thank you all!
Re: [SOLVED] Very slow browsing in folders
Posted: 16 Feb 2015 00:50
by serverguy
"check with zfskerntune if prefetch is enabled"
HOW does one do this? I did the install and the PostInit command script, rebooted. But... then what? The Command is not found. I can't find any documentation by searching on how to use this or how it works.
Re: [SOLVED] Very slow browsing in folders
Posted: 16 Feb 2015 02:49
by serverguy
Turned off "Enable store DOS attributes". No hangs on the slow loading system. Going to test on the faster throughput system. Hoping it is solved.
Re: [SOLVED] Very slow browsing in folders
Posted: 16 Feb 2015 06:05
by serverguy
NOT Solved here.
Following suggestions posted in responses - Turned off "Enable store DOS attributes" and "EA Support". Saved and Restart. Still big gaps during writing. See attachment.
Current SMB checkbox config:
Max Protocol: SMB3
Local Master Browser: No
Time Server: No
Map to guest: Never
Send Buffer: 64240
Receive Buffer: 64240
Large read/write: checked
Use Sendfile: NOT checked
EA Support: NOT checked
Store DOS attributes: NOT checked
Asynchronus I?/O (AIO): checked
AIO read/write size: both 4096
So no joy here yet. Anything else to change/check? Still no idea now to execute zfskerntune to see more.
Mike
Re: [SOLVED] Very slow browsing in folders
Posted: 16 Feb 2015 09:37
by raulfg3
try to play with Send & Receive Buffer; start using x2, x3 and x4 default values.
eg: try send & receive buffer = 128480, etc...
Re: [SOLVED] Very slow browsing in folders
Posted: 02 Mar 2015 00:16
by serverguy
Changed buffer to 128480. Sadly, less than 2 minutes in, got first stutter. Minute later got 5 second pause. Problem not solved yet. Going to higher buffer size. Memory hardly used.
Now set to 256,960. Save and Restart again.
Less than 30 second in, got 3 second pause. And they continue from there.
Sadly, problem not solved yet.
Folder browsing still slow, too. On same GB switch as NAS box and nothing else going on on this branch so not a data bottleneck. Checking other threads. Wish this had not been marked as solved...
MIke
Re: [SOLVED] Very slow browsing in folders
Posted: 12 Mar 2015 02:38
by pokeyboy
This is a shot it the dark and it may be totally unrelated. I was having a similiar networking problem. I stumbled on the solution by accident. The CPU I was using was a Pentium 4 with HyperThreading. When I turned off the HyperThreading in the BIOS, everything worked fine. That's the way I left it.
Re: [SOLVED] Very slow browsing in folders
Posted: 01 Apr 2015 22:36
by Lord Crc
I too had issues with slow directory browsing. What really helped for me, if I recall correctly, was to make Samba case sensitive. IIRC without this Samba has to list all the files and do some checks (for file-name clashes) before sending it over, resulting in a lot of latency. With case sensitivity enabled it can just hand the metadata straight over. Similar for creating files.
This breaks with what's expected in the Windows world (where filesystems are case _in_sensitive) and can theoretically lead to issues (such as not being able to open a file), but I've yet to have any issues at all with this. After all, almost all programs will just reference the filename as it gets it from the filesystem, in which case there won't be any issue.
Here's what I've added to the samba conf (under "Auxilary parameters"):
Code: Select all
case sensitive = yes
getwd cache = yes
preserve case = yes
short preserve case = yes
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE
In addition I have 128480 as send and receive buffer size and AIO enabled (default read/write size). With this I can saturate my gigabit network and browsing folders with thousands of files is fast.
Re: [SOLVED] Very slow browsing in folders
Posted: 02 Apr 2015 02:45
by jollmon
Thanks @ Lord Crc!
This really helped out my 100gb photos folder when it came to generating thumbs! now it will be easier for me to sort them in a fashion that makes sense.
I just wanted to add in that It didnt seem to register these settings updates on my system until I did a reboot. I think thats like a thing actually if you make a change and see no improvement, try a reboot. Several items have been helped by this for me with tuning and cifs.
Re: [SOLVED] Very slow browsing in folders
Posted: 02 Apr 2015 04:08
by Lord Crc
Glad it helped
Regarding rebooting, yes, I tend to do that for all such config changes, but I forgot to mention as it's been quite a while since I've changed anything. I call it "stable system dementia", very annoying.
Re: [SOLVED] Very slow browsing in folders
Posted: 02 Apr 2015 18:52
by daoyama
Lord Crc wrote:Here's what I've added to the samba conf (under "Auxilary parameters"):
Code: Select all
case sensitive = yes
getwd cache = yes
preserve case = yes
short preserve case = yes
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE
It seems SO_SNDBUF=64240 SO_RCVBUF=64240 of socket options is bad parameters.
If you have a problem, please try to add
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE
to Auxilary parameters.
You can see current setting by CLI:
# testparm -vs
Also you can change the value of net.inet.tcp.delayed_ack=1 under "System|Advanced|sysctl.conf"
Thank you for reporting.
Re: [SOLVED] Very slow browsing in folders
Posted: 02 Apr 2015 20:25
by Lord Crc
It's coming back to me now. Here's the article I based my changes on:
https://www.samba.org/samba/docs/man/Sa ... efile.html