Package: linux-2.6
Version: 2.6.32-30
Severity: normal

Hi,

We initially experied this bug on a RHEL6 server and CentOS 5.5 clients. See also my Red Hat bugzilla report: https://bugzilla.redhat.com/show_bug.cgi?id=683372

I can reproduce this with:
 - Debian Lenny clients against the RHEL6 server
 - Debian Squeeze clients against the RHEL6 server
 - RHEL 5.5 and 5.6 clients against the RHEL6 server
 - all these clients against a squeeze server
 - all these clients against a squeeze server running 2.6.38-rc6-amd64

We basically have a ksh script that appends a line to a world-writable file. This world-writable file lives on an (automounted, but this doesn't seem to be relevant) NFSv4 mount. Very frequently this script fails with the error that it has no permissions to create the file.

Rerunning the script triggers the same error condition. When we run a stat against the world-writable file and then rerun the script, the script works and appends the line.

After waiting a while, the same error appears when running the script. Executing a
stat (or ls -l ) always "fixes" it for a while.

To reproduce I've set up the test server like this:

mkdir -p /srv/temp /srv/export /srv/export/freeware
dd if=/dev/zero of=/srv/test.ext4 bs=1M count=256
mkfs.ext4 /srv/test.ext4
mount -t ext4 -o loop,relatime,nosuid,nodev,acl,jqfmt=vfsv0,usrjquota=aquota.user,grpjquota=aquota.group /srv/test.ext4 /srv/temp
quotacheck -vug /srv/temp
quotaon -vug /srv/temp
mount -t none -o bind /srv/temp /srv/export/freeware
mkdir -p /srv/temp/bin/linux-x86_64/
touch /srv/temp/bin/linux-x86_64/accountlog
chmod 666 /srv/temp/bin/linux-x86_64/accountlog
chown -Rh gcc:freeware /srv/temp/bin (this is a normal user and group)

/etc/exports has the following lines:
/srv/export     *(rw,async,no_subtree_check,fsid=0)
/srv/export/freeware       *(rw,async,no_subtree_check)

/etc/default/nfs-kernel-server has:
RPCMOUNTDOPTS=--manage-gids -p 892 --no-nfs-version 1 --no-nfs-version 2 --no-nfs-version 3

/etc/idmapd.conf is configured with the same domain as the client.

service nfs-kernel-server restart

On the client:
mount -t nfs4 -o nodev,nosuid,intr server:/freeware/bin /test

run the following ksh script on the client:

#! /bin/ksh -p
printf "%s\t%s\t%s\t%s\t%s\t%s\n" ${HOSTNAME:-$(hostname)} ${USER:-$(whoami)} $version ${0##*/} $(date +'%d/%m/%y%t%T') >> /test/linux-x86_64/accountlog

Very frequently we get an error stating that the file can not be created.
Running a stat or ls -l on the file will show the correct permissions and owner/group. After running the stat, the script will work OK. After a while, the error will return.

I'm not sure this is an NFSv4 client or server bug.

I also tried it with linux-image-2.6.38-rc6-amd64, 2.6.38~rc6-1~experimental.1 on the server but no change.


Regards,

Rik



--
To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/4d7787b8.8010...@esat.kuleuven.be

Reply via email to