[PATCH 2/5] test: nfs: don't require a locking daemon
Nick Alcock <[email protected]>
| Newsgroups | dev.linux.lists.dtrace |
|---|---|
| Message-ID | <[email protected]> |
On modern (NFSv4) systems, there is no guarantee that statd is running, and indeed it has probably been explicitly turned off (unless writable NFSv3 exports exist). This causes mount-time warnings that trigger test failures unless we disable locking. No DTrace NFS tests need locking, so disable it. Signed-off-by: Nick Alcock <[email protected]> --- test/triggers/io-mount-nfs.sh | 2 +- test/unittest/io/tst.nfs2.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/test/triggers/io-mount-nfs.sh b/test/triggers/io-mount-nfs.sh index 338443eb72240..71c83103075b8 100755 --- a/test/triggers/io-mount-nfs.sh +++ b/test/triggers/io-mount-nfs.sh @@ -18,4 +18,4 @@ fi mountdir=$1 serverpath=$2 -mount -t nfs -o nfsvers=3 127.0.0.1:$serverpath $mountdir +mount -t nfs -o nfsvers=3,nolock 127.0.0.1:$serverpath $mountdir diff --git a/test/unittest/io/tst.nfs2.sh b/test/unittest/io/tst.nfs2.sh index 41a7a465868f9..87452d3a3be10 100755 --- a/test/unittest/io/tst.nfs2.sh +++ b/test/unittest/io/tst.nfs2.sh @@ -31,13 +31,13 @@ systemctl enable --now nfs-server > /dev/null 2>&1 mkdir $exdir exportfs -i -v -o "rw,sync,no_root_squash,insecure,fsid=8434437288" 127.0.0.1:$exdir > /dev/null mkdir $iodir - mount -t nfs -o nfsvers=3 127.0.0.1:$exdir $iodir + mount -t nfs -o nolock,nfsvers=3 127.0.0.1:$exdir $iodir $rundt "dd if=/dev/urandom of=$tempfile count=$filesize bs=1 status=none" -o log.write myinode=`stat $tempfile | gawk '/ Inode: / {print $4}'` umount $iodir # flush caches and remount to force IO echo 3 > /proc/sys/vm/drop_caches - mount -t nfs -o nfsvers=3 127.0.0.1:$exdir $iodir + mount -t nfs -o nolock,nfsvers=3 127.0.0.1:$exdir $iodir $rundt "sum $tempfile" -o log.read rm -f $tempfile umount $iodir -- 2.51.0.284.g117bcb8de7