[Fwd: Re: [linux-cifs-client] Latency after a cifs mount]
Benjamin Pavie
benjamin.pavie at utsouthwestern.edu
Fri May 15 11:35:35 GMT 2009
On Fri, 2009-05-15 at 13:32 -0400, Jeff Layton wrote:
> On Fri, 15 May 2009 00:24:15 -0500
> Benjamin Pavie <benjamin.pavie at utsouthwestern.edu> wrote:
>
> > On Fri, 2009-05-15 at 13:13 -0400, Jeff Layton wrote:
> > > On Fri, 15 May 2009 03:38:16 +0000
> > > Benjamin Pavie <benjamin.pavie at utsouthwestern.edu> wrote:
> > >
> > > > Hi everybody,
> > > >
> > > > I have a problem of latency after mounting my partion using
cifs :
> > > >
> > > > sudo mount -t
cifs //my.server.com/lab_share /home/bpavie/lab_share -o
> > > >
credentials=/etc/samba/user,iocharset=utf8,file_mode=0777,dir_mode=0777,uid=bpavie
> > > >
> > > > When I run the following bash script,
> > > > #!/bin/bash
> > > > mkdir /home/bpavie/lab_share/test2
> > > > mkdir /home/bpavie/lab_share/test2/subTest
> > > > touch /home/bpavie/lab_share/test2/subTest/toto.txt
> > > >
> > > > I have the following output :
> > > > bpavie at computer:~$ ./test.sh
> > > > mkdir: cannot create directory
`/home/bpavie/lab_share/test2/subTest':
> > > > Permission denied
> > > > touch: cannot touch
`/home/bpavie/lab_share/test2/subTest/toto.txt':
> > > > Permission denied
> > > >
> > > > So the first directory is created but not the sub-directory.
> > > > When I add a sleep between the creation of the directory test2
and the
> > > > subdirectory subTest, the first error vanish.
> > > >
> > > > #!/bin/bash
> > > > mkdir /home/bpavie/lab_share/test2
> > > > sleep 1
> > > > mkdir /home/bpavie/lab_share/test2/subTest
> > > > touch /home/bpavie/lab_share/test2/subTest/toto.txt
> > > >
> > > > bpavie at computer:~$ ./test.sh
> > > > touch: cannot touch
`/home/bpavie/lab_share/test2/subTest/toto.txt':
> > > > Permission denied
> > > >
> > > >
> > > > It seems there is a kind of delay, how to fix that ?
> > > >
> > >
> > > What kernel are you using?
> > >
> > bpavie at computer:~$ uname -r
> > 2.6.28-11-generic
> >
> > Actually, I just made some progress :
> > I discover that if I execute this script as root and/or using sudo,
> > everything works fine, all the sub-directory and the .txt file are
> > created without warning.
> >
> > How to have the same behavior for the normal user ? And is this
behavior
> > normal?
> >
>
> No, it's clearly broken if it changes after an amount of time. It
> sounds like a problem with inode attribute revalidation. That said,
> 2.6.28 is pretty old. You might want to check 2.6.29 and see if it
> fares better. Seems like we fixed some problems like that a while
back.
>
I installed the kernel 2.6.29 but I still have the same problem :
bpavie at computer:~$ ./test.sh
mkdir: cannot create directory `/home/bpavie/lab_share/test2/subTest':
Permission denied
touch: cannot touch `/home/bpavie/lab_share/test2/subTest/toto.txt':
Permission denied
bpavie at computer:~$ uname -r
2.6.29-02062903-generic
However, if I'm root, everything works :
bpavie at computer:~$ sudo ./test.sh
Where test is :
#!/bin/bash
mkdir /home/bpavie/lab_share/test2
mkdir /home/bpavie/lab_share/test2/subTest
touch /home/bpavie/lab_share/test2/subTest/toto.txt
and /home/bpavie/lab_share/ is my cifs partition mounted.
Here is my configuration :
bpavie at computer:~$ modinfo cifs
filename: /lib/modules/2.6.29-02062903-generic/kernel/fs/cifs/cifs.ko
version: 1.57
description: VFS to access servers complying with the SNIA CIFS
Specification e.g. Samba and Windows
license: GPL
author: Steve French <sfrench at us.ibm.com>
srcversion: 408B6A950DD913C5337FD8A
depends:
vermagic: 2.6.29-02062903-generic SMP mod_unload modversions 586
parm: CIFSMaxBufSize:Network buffer size (not including
header). Default: 16384 Range: 8192 to 130048 (int)
parm: cifs_min_rcv:Network buffers in pool. Default: 4 Range:
1 to 64 (int)
parm: cifs_min_small:Small network buffers in pool. Default:
30 Range: 2 to 256 (int)
parm: cifs_max_pending:Simultaneous requests to server.
Default: 50 Range: 2 to 256 (int)
Benjamin
-------------- next part --------------
An embedded message was scrubbed...
From: Benjamin Pavie <benjamin.pavie at utsouthwestern.edu>
Subject: Re: [linux-cifs-client] Latency after a cifs mount
Date: Fri, 15 May 2009 04:27:07 -0500
Size: 3765
Url: http://lists.samba.org/archive/linux-cifs-client/attachments/20090515/01ac264a/attachment.eml
More information about the linux-cifs-client
mailing list