7 CHECKSTAT=${CHECKSTAT:-"checkstat -v"}
8 MOUNT1=${MOUNT1:-/mnt/lustre1}
9 MOUNT2=${MOUNT2:-/mnt/lustre2}
10 export NAME=${NAME:-mount2}
14 sh llmountcleanup.sh > /dev/null
20 sh llrmount.sh > /dev/null
35 mount | grep $MOUNT1 || sh llmount.sh
37 echo -n "test 1: check create on 2 mtpt's..."
39 [ -f $MOUNT2/f1 ] || error
42 echo "test 2: check attribute updates on 2 mtpt's..."
44 $CHECKSTAT -t file -p 0777 $MOUNT1/f1 || error
47 echo "test 2b: check cached attribute updates on 2 mtpt's..."
51 $CHECKSTAT -t file -p 0777 $MOUNT1/f2b || error
54 echo "test 2c: check cached attribute updates on 2 mtpt's..."
58 $CHECKSTAT -t file -p 0777 $MOUNT2/f2c || error
61 echo "test 3: check after remount attribute updates on 2 mtpt's..."
65 $CHECKSTAT -t file -p 0666 $MOUNT1/f1 || error
68 echo "test 4: unlink on one mountpoint removes file on other..."
70 $CHECKSTAT -a $MOUNT1/f1 || error
73 echo -n "test 5: symlink on one mtpt, readlink on another..."
74 ( cd $MOUNT1 ; ln -s this/is/good lnk )
76 [ "this/is/good" = "`perl -e 'print readlink("/mnt/lustre2/lnk");'`" ] || error
79 echo -n "test 6: fstat validation on multiple mount points..."
80 ./multifstat $MOUNT1/f6 $MOUNT2/f6
83 echo "test 9: remove of open file on other node..."
84 ./openunlink $MOUNT1/f9 $MOUNT2/f9 || error
87 echo -n "test 10: append of file with sub-page size on multiple mounts..."
90 for C in a b c d e f g h i j k l; do
91 MOUNT=`eval echo \\$MOUNT$MTPT`
92 echo -n $C >> $MOUNT/f10
93 [ "$MTPT" -eq 1 ] && MTPT=2 || MTPT=1
95 [ "`cat $MOUNT1/f10`" = "abcdefghijkl" ] && pass || error
97 echo -n "test 11: write of file with sub-page size on multiple mounts..."
101 for C in a b c d e f g h i j k l; do
102 MOUNT=`eval echo \\$MOUNT$MTPT`
103 echo -n $C | dd of=$MOUNT/f11 bs=1 seek=$OFFSET count=1
104 [ "$MTPT" -eq 1 ] && MTPT=2 || MTPT=1
105 OFFSET=`expr $OFFSET + 1`
107 [ "`cat $MOUNT1/f11`" = "abcdefghijkl" ] && pass || error
109 rm -f $MOUNT1/f[0-9]* $MOUNT1/lnk