SMB share not showing all files


Recommended Posts

As the title suggests, I have an SMB share that does not show all files. The same share exported by NFS is fine, however.

 

I have already checked file permissions etc. All I can think is that it may be files with invalid chars making SAMBA unhappy? This has been an issue for quite a few years now, but the files in that share aren't critical, so I've just lived with it. Now I would like to get to the bottom of it and fix it.

 

Please dont judge me on the files lol. I collected anything and everything.

NFS on the left. SMB on the right. Notice the total file count (bottom of each window).

Screenshot 2024-01-07 at 7.38.41 am.png

Link to comment

As an example.. if I run

 

ls -lah 2\ Unlimited\ -\ *

 

on my Mac via Terminal, I get the following:

 

wishie@Mac-Pro MP3s % ls -lah 2\ Unlimited\ -\ *
-rwx------  1 wishie  staff   5.0M  3 May  2008 2 Unlimited - Get Ready For 1This.mp3
-rwx------  1 wishie  staff   4.2M  3 May  2008 2 Unlimited - Never Surrender.mp3
-rwx------  1 wishie  staff   3.8M  3 May  2008 2 Unlimited - The Edge of Heaven.mp3
-rwx------  1 wishie  staff   3.4M  3 May  2008 2 Unlimited - Tribal Dance (Rap Edit).mp3

 

but the same command, issued in terminal on the unRAID machine itself gives the following:

 

root@wishie:/mnt/user/Music/MP3s# ls -lah 2\ Unlimited\ -\ *
-rw-rw-rw- 1 nobody users 3.2M May  3  2008 2\ Unlimited\ -\ Get\ Ready\ 4\ This\ (Hockey\ Mix).mp3
-rw-rw-rw- 1 nobody users 5.1M May  3  2008 2\ Unlimited\ -\ Get\ Ready\ For\ 1This.mp3
-rw-rw-rw- 1 nobody users 5.5M May  3  2008 2\ Unlimited\ -\ Get\ Ready\ For\ This\ (Wild\ Mix).mp3
-rw-rw-rw- 1 nobody users 4.2M May  3  2008 2\ Unlimited\ -\ Never\ Surrender.mp3
-rw-rw-rw- 1 nobody users 3.8M May  3  2008 2\ Unlimited\ -\ The\ Edge\ of\ Heaven.mp3
-rw-rw-rw- 1 nobody users 3.4M May  3  2008 2\ Unlimited\ -\ Tribal\ Dance\ (Rap\ Edit).mp3
-rw-rw-rw- 1 nobody users 3.9M May  3  2008 2\ Unlimited\ -\ Twilight\ Zone.mp3
-rw-rw-rw- 1 nobody users 3.9M May  3  2008 2\ Unlimited\ -\ Workaholic.mp3

 

Link to comment
13 minutes ago, trurl said:

I had good reasons for asking for this specifically

As run on the unRAID machine itself:

 

root@wishie:~# ls -lah /mnt/user/Music/
total 580K
drwxrwxrwx 1 nobody users    6 Jan  9 06:57 ./
drwxrwxrwx 1 nobody users   48 Jan  9 06:48 ../
-rw-rw-rw- 1 nobody users  250 Nov  5  2011 .apdisk
drwxrwxrwx 1 nobody users  36K Sep 16  2011 701\ Greatest\ 1980's\ Singles\ [FLAC]/
drwxrwxrwx 1 nobody users  68K Jan  9 06:35 Albums/
drwxrwxrwx 1 nobody users 356K Jan  9 06:35 MP3s/

 

Link to comment

That looks OK. I was just wondering if you had some files or folders with the same name except for upper/lower case. SMB is not case sensitive and will only show one. For example, if you had a folder named MP3 and also a folder named mp3, you would only see one of these folders and its contents.

Link to comment

I don't believe that anyone thinks that you don't have a problem.  It is just that no one has seen anything that you (and we) have looked at so far that might be the cause of what you are experiencing. 

 

I must admit that I have no experience in the MacOS arena.   Have you had a look at that SMB share using a Windows computer?  There is also a sub-forum on this Forum where MacOS problems are discussed.  (Apple SMB does not seem to behave like other versions of SMB from Samba Org and MS...)   There is also a single thread started by LimeTech on MacOS SMB solutions.  You can find them here:

 

      https://forums.unraid.net/forum/103-macossmb/

and

     https://forums.unraid.net/bug-reports/prereleases/macos-optimization-r2087/

 

I also seem to recall that there may be an issue with MacOS, SMB, and directories with large numbers of files in them...

Edited by Frank1940
Link to comment

When you run the following command on the Unraid GUI terminal

 

ls -lah /mnt/user/Music/MP3s | more

 

you can verify the 6000 files and all the permissions are correct and 'group' is "users".  (You do not have to look at all 6000 but two or three hundred should be enough.) 

 

----->    It will take a   <Control-C>  and then an  <Enter>  to exit from 'more'.    <----

 

My experience suggests that the owner is not that important if the client is logged in as a valid 'Share Access' user and the permissions on the directories is 777 and files is 666.

 

Link to comment

Exiting from 'more' is a simple 'q'. :)

 

Anyway, permissions for files and folders are perfectly fine.

 

Here is an excerpt 

 

-rw-rw-rw- 1 nobody users  2.0M May  3  2008 Dead\ Kennedys\ -\ Winnebego\ Warior.mp3
-rw-rw-rw- 1 nobody users  5.4M May  3  2008 Death\ In\ Vegas\ -\ Dirt.mp3
-rw-rw-rw- 1 nobody users  3.4M May  3  2008 Debelah\ Morgan_-_Dance\ With\ Me.mp3
-rw-rw-rw- 1 nobody users  3.9M May  3  2008 Deborah\ Cox\ -\ Nobody's\ Suppose\ to\ Be\ Here\ (Dance\ Mix).mp3
-rw-rw-rw- 1 nobody users  4.0M May  3  2008 Deborah\ Cox\ -\ Nobodys\ Supposed\ To\ Be\ Here.mp3
drwxrwxrwx 1 nobody users    90 Jan  5  2016 Decades/
-rw-rw-rw- 1 nobody users  3.6M May  3  2008 Dee\ Lite\ -\ groove\ is\ in\ the\ heart.mp3
-rw-rw-rw- 1 nobody users  3.6M May  3  2008 Dee\ Lite,\ Groove\ Is\ In\ The\ Heart.mp3
-rw-rw-rw- 1 nobody users  5.5M May  3  2008 Deep\ Forest\ -\ Sweet\ Lullaby\ [\ Round\ The\ World\ Mix\ ].mp3

 

Link to comment

OK.  Now make sure that you have installed the "Dynamix File Manager" plugin on your Unraid server. 

 

Then go to  'SHARES'.  You see see this Icon image.png.e5fd6db597e0706685addfffda10fd6a.png on the left side.  Click on the one for your 'Music' share.   Look for the 'MP3s' and then look for the disks that contain files for this share.  Write them down.  Then click on the 'MP3s' folder/directory and see how many files are listed. 

 

If you have only 59, then look to see what disk they are on.   

 

Otherwise, try and find one of those 59 files in that list and check to see what the disk number is.

 

Now do some exploring with the 'ls' command in the GUI terminal and Dynamix File Manager on the Disk Shares.  The ls command would looks like this:

 

ls -alh /mnt/diskX/

(replace the "X" with the number of the disk.)

 

Then just add on the Share--- Music  ---name.  Look at those shares.   Then add on the directory--- MP3s  ---and look at those files. 

 

What I am suspecting is that you may find those 59 files are on one disk...

 

image.png

Link to comment
Posted (edited)

I started to go through them, but 6000ish files are on 'Disk2'.. basically ~400GB of the 600GB of data. So its not like just those 59 files are on a different disk.

 

Besides, NFS is working fine.. it has to be some issue with SAMBA.

 

EDIT: The ENTIRE contents of the 'MP3s' folder, is on disk2.

Edited by wishie
Additional information
Link to comment

Now one more thing---  under SHARES, export disk 2 as a Disk Share.  Then look and what you see find there.  (I really don't care at this point as it should be a part of what I am suggesting you to do. I believe that 'User Shares'  are handled differently than 'Disk Shares' on the Unraid side...)

 

I think you need to create a 'Bug' report.  (There aren't many people with 6000 items in a single share so you have may uncovered a long latent one!) 

 

You can do this in this Sub-forum:

 

      https://forums.unraid.net/bug-reports/stable-releases/

 

Include the results of all the things you have tried and looked at in a coherent manner.  Reference this thread if you need to.

 

Link to comment
13 hours ago, trurl said:

I have a lot more than that in several of my shares.

 

Do you have any ideas of what is happening then? 

 

If you are not having a problem, I suspect that the OP must have an issue with some file parameter-- like a forbidden character in the file name.  But I don't know a way to find it.  I looked at the 'File Modified' date and May 3, 2008 showed up but there did not seem to be a complete correlation that as the times on the two lists didn't have a pattern.

 

@wishie, consider copying off all the files onto a Flash drive or a external HD (probably faster) using NFS and see if you have any problems with either the copy operation or file listing after that.   If you find nothing there then make a new share--- or a new directory in Music (like, BackMP3) ---and copy them back using SMB. 

Edited by Frank1940
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
Reply to this topic...

×   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.