]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
qa: add snaptest-estale.sh
authorSage Weil <sage@newdream.net>
Tue, 17 Aug 2010 18:37:42 +0000 (11:37 -0700)
committerSage Weil <sage@newdream.net>
Tue, 17 Aug 2010 19:00:07 +0000 (12:00 -0700)
Verify requests withing snapped namespace are directed to the proper
MDS.  We should never get ESTALE, only ENOENT.

qa/workunits/snaptest-estale.sh [new file with mode: 0755]

diff --git a/qa/workunits/snaptest-estale.sh b/qa/workunits/snaptest-estale.sh
new file mode 100755 (executable)
index 0000000..29699fc
--- /dev/null
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+mkdir .snap/foo
+
+echo "We want ENOENT, not ESTALE, here."
+for f in `seq 1 100`
+do
+    stat .snap/foo/$f 2>&1 | grep 'No such file'
+done
+echo "Pass!"
+
+rmdir .snap/foo
\ No newline at end of file