aleksey-hoffman / sigma-file-manager

"Sigma File Manager" is a free, open-source, quickly evolving, modern file manager (explorer / browser) app for Windows and Linux.
https://sigma-file-manager.vercel.app
Other
3.84k stars 145 forks source link

Can not open smb shares, either directly or as mounted drives #292

Open forkicks opened 11 months ago

forkicks commented 11 months ago

Is there an existing issue for this?

Problem description

I have a network share on my network that contains +-350TB/34 million files. The root listing is only 20 directories. I don't know if SFM is trying to automatically get the size of each directory (which I have turned off in settings), or what type of operation is happening, but when I try to access the share it just stays there as if loading but never finishes (I've waited quite a while). This happens even as a mounted network drive, so that I access it as a local letter. SFM does not hang, but never shows anything. For comparison, Windows Explorer and xplorer2 have no issues at all on it.

Steps to reproduce

  1. Open SFM
  2. Click on mounted drive
  3. Wait forever

Environment

forkicks commented 11 months ago

After some digging, I can add a few more details on this. Watching SFM activy with process monitor while this problem is happening, I see that it is repeatedly trying to get information on all the directories present at the root of the share. It just so happens that all of those are reparse points on the remote system, not regular directories. Again, sigma doesn't hang, it simply loops over all the entries on destination, over and over again. These are the operations that are happening (as shown in process monitor): IRP_MJ_QUERY_VOLUME_INFORMATION IRP_MJ_QUERY_INFORMATION IRP_MJ_CLEANUP

I assume those are operations triggered by whatever syscalls you're using to obtain information about the destination directories, and since they are not quite simple directories but reparse points, something is failing along the way.

Also, there is another related issue. SFM tries to create an entry (or the calls you're making try to create this) for the share under c:\Windows\CSC\v2.0.6\namespace\<ip address of remote server\ The original permissions there are wrong, and SFM can not do that. After manually adding permissions for SFM to do this, it still hangs, but those entries get created for each visited share. I have never seen this behavior before.