[linux-cifs-client] Problems with rename to open file and
open/unlink/create
Jeff Layton
jlayton at redhat.com
Wed Apr 8 11:06:33 GMT 2009
On Wed, 8 Apr 2009 07:07:48 +0200
Wilhelm Meier <wilhelm.meier at fh-kl.de> wrote:
> Am Dienstag 07 April 2009 schrieb Jeff Layton:
> > On Tue, 7 Apr 2009 08:03:56 +0200
> >
> > Wilhelm Meier <wilhelm.meier at fh-kl.de> wrote:
> > > Am Montag 06 April 2009 schrieb Jeff Layton:
> > > > On Mon, 6 Apr 2009 17:18:30 +0200
> > > >
> > > > Wilhelm Meier <wilhelm.meier at fh-kl.de> wrote:
> > > > > Hi all,
> > > > >
> > > > > we use a cifs-1.56 (the backported sources from Steve French)
> > > > > together with a 2.6.27-kernel. As we encounter some weired
> > > > > problems with kmail, I took my cifs-test-programs (see
> > > > > attchements) and I got strange results.
> > > > >
> > > > > 1) t_byterangelocking: all fine
> > > > >
> > > > > 2) t_rename: test ok, but leaves around cifsXXXX-files
> > > > >
> > > > > 3) t_openunlinkclose: test ok, but leaves also around
> > > > > cifsXXX-files
> > > > >
> > > > > Below you find the /proc/mounts and DebugData.
> > > > >
> > > > > I think the cifsXXXX files are the cause of problems to
> > > > > kmail. Do you have any ideas?
> > > > >
> > > > > Thx,
> > > > >
> > > > > Wilhelm
> > > > >
> > > > > //kmux-svc/kmux.admin /home/kmux.admin cifs
> > > > > rw,unc=\\kmux-svc\kmux.admin,username=kmux.admin,domain=kmux,
> > > > >addr
> > > > > =192.168.32.12,uid=999,gid=999,posixpaths,serverino,nobrl,acl
> > > > >,rsiz e=16384,wsize=57344 0 0
> > > > >
> > > > > kmux.admin at rich00018061EBDD:~$ cat /proc/fs/cifs/DebugData
> > > > > Display Internal CIFS Data Structures for Debugging
> > > > > ---------------------------------------------------
> > > > > CIFS Version 1.56
> > > > > Active VFS Requests: 0
> > > > > Servers:
> > > > > 1) Name: 192.168.32.12 Domain: KMUX Uses: 4 OS: Unix
> > > > > NOS: Samba 3.0.28a Capability: 0x80e3fd
> > > >
> > > > ^^^^^^^^^^^
> > > > I think that this version of samba may not handle the
> > > > delete_on_close bit properly. I ran across this when trying to
> > > > fix this code and left some comments to that effect:
> > >
> > > Well, I tested also will samba-3.3.2 (ubuntu package) and
> > > samba-3.3.3 (compiled).
> > >
> > > Now the t_rename succeeds, but t_openunlinkclose still produces
> > > cifsXXXX files. Yes, and kmail keeps crashing.
> > >
> > > I read something about the readdir implementation in cifs >=
> > > 1.56, but this seems not to the case in the
> > >
> > > http://pserver.samba.org/samba/ftp/cifs-cvs/cifs-1.56-backport-fo
> > >r-2.6.25-2.6.28.tar.gz
> > >
> > > backport I used here for the 2.6.27-kernel. Are there any
> > > cifs-1.57 versions backported to linux-2.6.27?
> >
> > You may want to test a more recent kernel as well. It's possible
> > the backported cifs module you're using doesn't handle this
> > properly. Deleting and renaming open files with CIFS is extremely
> > tricky and we went through several iterations before we got to the
> > current state in upstream code. I'm not convinced that it's quite
> > correct yet (a spurious reconnect in the middle of operations could
> > lead to the file getting deleted on the server), but it works well
> > enough to pass the connectathon tests now.
> >
> > If you can reproduce on a recent kernel (2.6.29-ish, ideally) then
> > please open a samba.org BZ, cc me on it and detail how you're
> > reproducing it.
>
> using 2.6.29 and samba>=3.2 is ok now!
>
Glad to hear it. I think we need more work in this area, but it seems
to work well enough for now.
--
Jeff Layton <jlayton at redhat.com>
More information about the linux-cifs-client
mailing list