Bug 212123 - Error reading directory through CIFS
Error reading directory through CIFS
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Dave Jones
Brian Brock
: 214735 (view as bug list)
Depends On:
  Show dependency treegraph
Reported: 2006-10-25 04:04 EDT by Lukas Slansky
Modified: 2015-01-04 17:29 EST (History)
8 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2006-11-12 00:47:12 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
dmesg output (21.84 KB, text/plain)
2006-10-31 17:07 EST, Steve Chupack
no flags Details

  None (edit)
Description Lukas Slansky 2006-10-25 04:04:01 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; cs; rv: Gecko/20061011 Fedora/ Firefox/

Description of problem:
I noticed this while reading longer directories (+300 files). The `ls` gives:
ls: reading directory .: Invalid argument

Accessing files is OK.

It seems to be file name length (or sum) dependent.

fstab line:
//storage/home /home/lukas/storage cifs                domain=W2KDOMAIN,user=XXXXX,password=XXXXX,uid=lukas,gid=lukas,file_mode=0644,dir_mode=0755,rw,user,auto

In FC5 2.6.18-2200 kernel is same result.
In FC5 pre 2200 kernels this was OK.

Version-Release number of selected component (if applicable):
kernel-2.6.18-1.2798.fc6 samba-client-3.0.23c-2

How reproducible:

Steps to Reproduce:
1. Mount CIFS share (from Win 2003 server).
2. Make files: for f in `seq -f '%05g' 1 127 `; do touch $f; done (126 files works OK)
3. ls directory

Actual Results:
ls: reading directory .: Invalid argument

Expected Results:
List of files

Additional info:
Comment 1 Jay Fenlason 2006-10-25 08:43:22 EDT
Once the mount succeeds, the mount.cifs program is out of the picture.  Any 
subsequent failures are entirely in the kernel.  I'm redirecting this bug to 
the correct component. 
Comment 2 Dave Jones 2006-10-28 02:08:42 EDT
This is fixed in CVS, will be in an update soon.
Comment 3 Steve Chupack 2006-10-31 17:07:25 EST
Created attachment 139907 [details]
dmesg output
Comment 4 Steve Chupack 2006-10-31 17:12:45 EST
Sorry, forgot to add a comment for attachment 139907 [details]. :-(  Just confirming that
I'm having the same issue with kernel-2.6.18-1.2798.fc6 and
samba-client-3.0.23c-2. Directory listings containing approx 100+ entries return
"ls: reading directory .: Invalid argument". This is happening when connecting
to various Samba servers of differing versions. 
Comment 5 Dave Jones 2006-11-12 00:47:12 EST
should be fixed in 2.6.18-1.2849.fc6 now in updates
Comment 6 Steve Bergman 2006-11-12 11:15:07 EST
(In reply to comment #5)
> should be fixed in 2.6.18-1.2849.fc6 now in updates

I'm not finding 2849.fc6.  But I did try .2835.fc6 from testing, and bonnie++
run on a CIFS mount still gives intermittent "Drastic I/O" errors, complaining
that the directory it is trying to remove is not empty.  It creates 16384 files
in a directory and then deletes them and removes the directory.  Apparently, it
thinks it deleted everything but really didn't.  This seems like it would be

Again, though, that is in 2835 which is the latest I have been able to find.
Comment 7 Ross Stubbs 2006-11-12 16:03:30 EST
(In reply to comment #6)
> (In reply to comment #5)
> > should be fixed in 2.6.18-1.2849.fc6 now in updates
> Again, though, that is in 2835 which is the latest I have been able to find.

Looks like many of the mirrors are yet to update.. I'm grabbing 2835 from here:
http://mirror.linux.duke.edu/pub/fedora/linux/core/updates/6/i386/ right now.
Hopefully that't fix the prob.

Comment 8 Steve Bergman 2006-11-12 17:37:26 EST
I'm testing with 2849 now and it looks like it does, indeed, resolve the problem.

I'm not sure if it is just luck of the draw or if there has really been a badly
needed change, but I am finding that the bugs that I have run into with FC6 are
getting developer attention, and are getting resolved, in a way that my FC5 bugs
did not.

Two of the significant bugs that I have been dealing with were resolved today. 
And on a Sunday, no less.

Comment 9 Lukas Slansky 2006-11-13 02:56:26 EST
Seems resolved in kernel-2.6.18-1.2849.fc6
Comment 10 Mark J. Cox 2006-11-13 05:53:18 EST
verified, now works for me in kernel-2.6.18-1.2849.fc6
Comment 11 Jeff Layton 2007-11-18 07:47:25 EST
*** Bug 214735 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.