[oclug] Partial directory listing on SMB mounted share
hdc at fs.ca
Tue Jun 1 05:44:42 EDT 2004
I am not able to read the full directory contents of an SMB mounted
share from my Linux computer.
We have a very large directory in my office which is located on an SMB
server - ie not Samba running on Linux, but just a normal, native SMB
server. It is fully accessible from other SMB clients - this problem
only occurs on my Linux client.
I want to back the directory up to my Linux PC by mounting it locally
as an smb mounted share - for example:
mount //serverpc/bigdirectory -t smbfs /mnt/serverpc
The problem is that when I do a directory listing (or anything else) of
the mounted share, the listing only goes about as far as directories
starting with the letter N before it terminates normally. In other
words, it will list all files a through z in the root directory, and
then list the directories until it gets to somewhere in the N's.
The same effect occurs when using the cp command to do backups - no
errors, but the cp process will terminate 'normally' abnormally early.
If I request a listing of a specific "invisible" directory, Linux will
get it, but if I try to do a wildcard search, Linux returns an
input/output error. For example, I have a directory on the SMB server
named OCLUG which doesn't show up just doing an 'ls /mnt/serverpc'.
However, if I type "ls /mnt/serverpc/OCLUG", I will get the listing of
the OCLUG subdirectory.
On the other hand, if I type the following wildcard request:
"ls /mnt/serverpc/O*", I get the following:
ls: /mnt/serverpc/O*: Input/output error
The mounted share is quite large (about 8 Gigs in about 170, 000
files), and it seems clear that I am just running into an smbmount
configuration issue - it is just running out of room to process my 'ls'
request in full because of the size of the drive in question. I need
to increase something somewhere, but what is it?
As an aside, note that the 170k files are not all in one big root
directory, but are probably in several thousand subdir's, sub-subdir's,
etc. However, Linux does seem to "look ahead" a lot when doing
directory-related commands, which is an intense irritation when using
Open Office, for example.
I'm running Mandrake 9.0 at the moment. Sorry to be so wordy.
More information about the OCLUG