Folder with many subfolders not showing using SMB in TN13

EtienneB

Explorer
Joined
Feb 19, 2018
Messages
78
Hello,
I have upgraded TN from 12.8.1 to 13.0. I have one folder in a dataset that has around 13,000 subfolders in it.
When I mount this folder using SMB on MacOS Monterey, it just won't load the list of folders. Mac keeps telling "loading" in Finder. I also tried the app Forklift, but that program says after a while that the folder is not available. (With SSH into the server I can see all the files).

A folder with 1,300 files loaded fine, other folders load fine too using SMB. With TN12 I never had that issue.

I have (still from previous installations) the following SMB settings:
vfs objects = fruit catia streams_xattr
fruit:encoding = native

(I entered those a few years ago as I needed them for TimeMachine for a macbook 2011 and 2018 models, so they are still there; and probably also for some strange characters in filenames I sometimes run into)

Probably totally unrelated, one thing I had before under TN 12 is that that specific folder of 13,000 files/subfolders sometimes suddenly showed everything in duplicate, so showing 26,000 files.

Any ideas or is that something known to be resolved in U1?

Thanks.
 

EtienneB

Explorer
Joined
Feb 19, 2018
Messages
78
Overriding VFS objects is not supported in the product. You lack an ACL module there and so undefined behavior is expected.
Thanks for replying, I removed all the VFS Objects, so back to defaults. All seems to work fine (except the large folder), incl Time Machine. I guess I don't need them anymore.

Anyway, after restarting SMB service and then even rebooting the server, the problem remained.
I also tried using another MacBook running High Sierra as this macbook using Monterey was updated yesterday as Apple released a new version (Monterey 12.4).

So both macbooks have the same issue with TN 13 of not displaying the contents of the large folder.
I now reverted back to TN 12U8.1 and now my folder lists normal again.
It must be something with TN13 then or the latest SMB.
I also noticed with TN13 after the SMB share failed to load, the whole Macbook slows down to a crawl and I need to reboot my mac too. Even normal eject of that Volume from the Mac remains unresponsive. So somehow SMB (4.15?) is a bottleneck here.
 
Last edited:

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
Thanks for replying, I removed all the VFS Objects, so back to defaults. All seems to work fine (except the large folder), incl Time Machine. I guess I don't need them anymore.

Anyway, after restarting SMB service and then even rebooting the server, the problem remained.
I also tried using another MacBook running High Sierra as this macbook using Monterey was updated yesterday as Apple released a new version (Monterey 12.4).

So both macbooks have the same issue with TN 13 of not displaying the contents of the large folder.
I now reverted back to TN 12U8.1 and now my folder lists normal again.
It must be something with TN13 then or the latest SMB.
I also noticed with TN13 after the SMB share failed to load, the whole Macbook slows down to a crawl and I need to reboot my mac too. Even normal eject of that Volume from the Mac remains unresponsive. So somehow SMB (4.15?) is a bottleneck here.
Might be one of the bugs I already fixed in 4.15 branch that's not in 13.0-release. Hard to say without seeing debugs and things.
 

EtienneB

Explorer
Joined
Feb 19, 2018
Messages
78
Might be one of the bugs I already fixed in 4.15 branch that's not in 13.0-release. Hard to say without seeing debugs and things.
I sent you my debug save as a dm. Hopefully it can help you.
Thank you for your help and work on SMB
 

EtienneB

Explorer
Joined
Feb 19, 2018
Messages
78
The issue remains with TN 13 U1, so I revert back to 12U8 once again.
I sent you a debug as a dm.
 

EtienneB

Explorer
Joined
Feb 19, 2018
Messages
78
I have tested it again today with TN 13 U1.1. But somehow, when I mount a SMB folder and then try to go into a folder with 13.000 entries, the SMB on my macbook locks up the SMB, I can't eject the share/folder. With TN 12U8 it still works fine.
 

EtienneB

Explorer
Joined
Feb 19, 2018
Messages
78
Today I installed TN Core 13 U2 but I still have issues with accessing a Dataset with 13,000 folders under its root from my macbook.
It just states "loading" on the mac and sort of hangs the macbook SMB shares until I turn SMB off in Truenas and wait for a "disconnect"on my macbook before turning it back on in TN.

In TrueNAS 12 U8 it works fine and it loads the folder pretty quickly too.

I think I have the default SMB settings in Truenas, see screenshots. Nothing special there.
For testing purposes, I also tried it with SMB 1 and NTLMv1 turned off, but to no avail.

Once it loaded the folder to exactly 8,000 folders/files but that was just before I disconnected the SMB and rebooted Truenas as the system became unresponsive due to connecting to this dataset.

Any thoughts how to solve this?

Would Truenas Scale handle SMB better or does it have the same underlying SMB engine?
I did read that I can't switch to Scale to test it and then move back to 12U8 core, correct?

Thanks!
 

Attachments

  • Screenshot 2022-09-01 at 16.06.03.png
    Screenshot 2022-09-01 at 16.06.03.png
    425.9 KB · Views: 94
  • Screenshot 2022-09-01 at 16.06.46.png
    Screenshot 2022-09-01 at 16.06.46.png
    324.6 KB · Views: 108
Top