I am having an issue with Ubuntu Natty (32 bit version) trying to access a directory on a FreeNAS server (set up to share files using samba) that is also on the local network. It seems that if there are under a certain number of files (just under 500, maybe 497 or 498) it can access the directory just fine. Add one more file, and Ubuntu refuses to show anything in the directory. However if I change the filename of the last added file to something very short (like 1.ext) then it will sometimes display it.
There is no such limit on files on local hard drives connected to the Ubuntu system. Also, all non-Ubuntu computers on the network have no problem accessing the directory on the FreeNAS server, so that pretty well seems to narrow it down to being an issue with Ubuntu accessing files over a network (and maybe only when samba is being used, though I don't know that). This is just a plain local network connection using samba; I am not using any sort of "tunnel" or VPN or anything like that, and I haven't played around with any settings that would change the way packets are sent or received.
So my question is, when accessing a directory on a remote share (using samba) is there any limit in Ubuntu on the number of files in a directory, or the number of characters in the combined filenames within the directory, or any other limit that might explain this strange behavior? If anyone even thinks they might have an explanation for this issue I'd like to hear it because so far nothing about this has made any sense. But if I can't get it resolved I may wind up having to install some other operating system on this computer, just so I can access my files on the FreeNAS share.
Basically I am wondering if there might be some value in some configuration file (maybe sysctl.conf?) that could be changed to avoid this problem. Please note that I am not a Linux or Ubuntu expert (just because I know what sysctl.conf is, don't assume I have been playing around with it — in fact I only learned about that file earlier today).
lscommand? Are you sure the problem is on Ubuntu and on the FreeNAS server? – Gilles Apr 28 '12 at 23:21