• Slow SMB performance


    ptr727
    • Minor



    User Feedback

    Recommended Comments



    9 hours ago, ncoolidg said:

    Is there any development on fixing this issue with small files?

    There are different solutions to enhance performance (impact descending): 

    • enable SMB Multichannel + RSS (this enables multi-threading, which allows transferring multiple files simultaneously instead of only one by one, which is the default in Windows, but not with Linux)
    • use Disk Shares instead of User Shares (which avoids Unraid's "FUSE (sshfs) overhead", which can be massive)
    • enable case-sensitivity (this allows co-existence of "photo.jpg" and "Photo.jpg" in the same directory, but makes SMB much faster handling a huge amount of files)
    • upload to an SSD Cache Pool instead of the Array (>1Gbit/s vs ~0.5Gbit/s)
    • install more RAM and raise the Write-Cache with Tips & Tweaks Plugin to 50 - 80%
    • use a faster CPU
    • do not use encryption
    • do not use a CoW filesystem like BTRFS or ZFS (write amplification = slower than usual filesystems)

     

     

    Link to comment
    10 minutes ago, mgutt said:
    • do not use encryption
    • do not use a CoW filesystem like BTRFS or ZFS (write amplification = slower than usual filesystems)

     

     

     

    While I agree with the rest (although had mixed results with adding more ram, I now have 256gb of ram and had to limit wrtitecache to ~2gb or it would have lockups).

     

    I did extensive testing with encryption and btrfs / XFS and noticed no difference with either of these on SMB performance at all. While they can technically slow down the drive speed SMB with small files is limited by the SMB bottleneck, not the drive speed.

     

    Even on windows with small files getting more then a few MB/s of writes was good, 10mb/s was really good. You are well below drive bottlenecks at those speeds.*

     

    You would have to have a REALLY slow CPU for either of these to make a noticeable difference in my testing. Even locking my CPU to 1200mhz didn't noticeably slow down speed tests to the drives when I was testing raw drive speed. I was only using an I5 2500 at the time as well.

     

    *obviously there are edge cases that could not be the case but practically with hardware from the last half decade, it is highly unlikely

    Edited by TexasUnraid
    Link to comment
    On 5/15/2022 at 10:27 AM, mgutt said:

    There are different solutions to enhance performance (impact descending): 

    • enable SMB Multichannel + RSS (this enables multi-threading, which allows transferring multiple files simultaneously instead of only one by one, which is the default in Windows, but not with Linux)
    • use Disk Shares instead of User Shares (which avoids Unraid's "FUSE (sshfs) overhead", which can be massive)
    • enable case-sensitivity (this allows co-existence of "photo.jpg" and "Photo.jpg" in the same directory, but makes SMB much faster handling a huge amount of files)
    • upload to an SSD Cache Pool instead of the Array (>1Gbit/s vs ~0.5Gbit/s)
    • install more RAM and raise the Write-Cache with Tips & Tweaks Plugin to 50 - 80%
    • use a faster CPU
    • do not use encryption
    • do not use a CoW filesystem like BTRFS or ZFS (write amplification = slower than usual filesystems)

     

     

    Using Disk Shares was ultimately the solution. The CPU Should not be bottlenecking performance too much. I have two Intel Xeon E5649 CPUs paired with 72GB of RAM on an R710. The CPUs are older but are still capable of running 5 Windows 11 VMs simultaneously in my previous Windows Server 2022 setup. I am also using an SSD cache pool.

     

    One question. Is there risks when having both user shares and disk shares enabled? I know you should never do file operations between the two. Like copy a file from /user to /disk. Any other risks? Reason I ask is because I can't get the VM Manager to work without user shares.

    Link to comment
    1 hour ago, ncoolidg said:

    I know you should never do file operations between the two. Like copy a file from /user to /disk. Any other risks?

    Nope. As long as you stay cognizant of the fact that a file will appear in two locations, and the computer isn't smart enough to keep you from overwriting (and subsequently erasing) what appears to be a second copy but isn't, you are fine.

     

    In fact as long as you are careful and don't interact with the file's twin in the same operation, you can mix user and disk shares. *(shh, don't tell anyone)* It's just easier to make a blanket statement to never do it, because most people aren't careful enough or think through what seems to be a perfectly innocent operation that ends up nuking their data. Once you are thoroughly familiar with how user shares work and how disk shares are melded together to make the user shares it's pretty obvious what is and isn't ok to do.

    Link to comment

    ah interesting thread, ties in with a lot of what i've been seeing too. have you tried SFTP?

     

     

    Definitely an unraid implementation specific problem and nothing related to hardware, nor others software. 

    Link to comment
    2 hours ago, TexasUnraid said:

    I tried SFTP at one point and it didn't have the issues but it had other issues that made it impractical.

    oh interesting, can you mention what those were? (if you can remember off the top of your head)

    as it stands currently, the best solution i've come up with (for windows) is using a tool called SFTP Drive which allows you to mount the drive in windows just like an smb mount and copy / paste / file movements operate more or less just like SMB.

     

    fd33d1315c20f980a37880795fe870f6.gif

    • Like 1
    Link to comment

    Interesting option,

    13 minutes ago, mrpops2ko said:

    oh interesting, can you mention what those were? (if you can remember off the top of your head)

    as it stands currently, the best solution i've come up with (for windows) is using a tool called SFTP Drive which allows you to mount the drive in windows just like an smb mount and copy / paste / file movements operate more or less just like SMB.

     

    fd33d1315c20f980a37880795fe870f6.gif

    Interesting option.

     

    I forgot the issues I ran into, security was a big one IIRC but forgot the others. They were such that I did not feel it was a viable option long term.

    Link to comment



    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.
    Note: Your post will require moderator approval before it will be visible.

    Guest
    Add a comment...

    ×   Pasted as rich text.   Restore formatting

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.


  • Status Definitions

     

    Open = Under consideration.

     

    Solved = The issue has been resolved.

     

    Solved version = The issue has been resolved in the indicated release version.

     

    Closed = Feedback or opinion better posted on our forum for discussion. Also for reports we cannot reproduce or need more information. In this case just add a comment and we will review it again.

     

    Retest = Please retest in latest release.


    Priority Definitions

     

    Minor = Something not working correctly.

     

    Urgent = Server crash, data loss, or other showstopper.

     

    Annoyance = Doesn't affect functionality but should be fixed.

     

    Other = Announcement or other non-issue.