Skip to contentSkip to conversation

xfstests 068: Add mmap load

PATCH In review Eric Sandeen 4 participants 4 messages Sep 28, 2012 – Oct 1, 2012

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 xfstests 068: Add mmap load

Test 068 is the go-to test for freeze deadlock coverage; unfortunately it only uses fsstress, which doesn't do any mmap IO.

Using the existing fstest binary gets us a cheap mmap exerciser as well.

---

I think it's fair to modify this test vs. making a new one - it's never passed yet, and will only start passing in kernel 3.6, so it shouldn't cause new test regressions to add mmap ops.

And I can verify that this finds mmap bugs; I had a backport which messed up ext4's freeze vs. mmap handling, and this exposes it. :)

068 +15 -0
index 617420c..a0bf425 100755
@@ -90,6 +90,21 @@ touch $tmp.running
     rmdir $STRESS_DIR
 } &
 
+# start fstest -m loop in a background block; this gets us mmap coverage
+{
+    FSTEST_DIR="$SCRATCH_MNT/fstest_test_dir"
+    mkdir "$FSTEST_DIR"
+
+    procs=2
+    while [ -f "$tmp.running" ]
+      do
+      src/fstest -m -p $FSTEST_DIR  -n $procs -f 4 > /dev/null 2>&1
+    done
+
+    rm -rf $FSTEST_DIR/*
+    rmdir $FSTEST_DIR
+} &
+
 i=0
 let ITERATIONS=$ITERATIONS-1
 

_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs

Reviewed-by on v1 1/1
#1 lore raw
Quoted 31 lines · Eric Sandeen

Test 068 is the go-to test for freeze deadlock coverage; unfortunately it only uses fsstress, which doesn't do any mmap IO.

Using the existing fstest binary gets us a cheap mmap exerciser as well.

---

I think it's fair to modify this test vs. making a new one - it's never passed yet, and will only start passing in kernel 3.6, so it shouldn't cause new test regressions to add mmap ops.

And I can verify that this finds mmap bugs; I had a backport which messed up ext4's freeze vs. mmap handling, and this exposes it. :)

068 +4 -0
index 617420c..a0bf425 100755
@@ -90,6 +90,21 @@ touch $tmp.running
     rmdir $STRESS_DIR
 } &
 
+# start fstest -m loop in a background block; this gets us mmap coverage
+{
+    FSTEST_DIR="$SCRATCH_MNT/fstest_test_dir"
+    mkdir "$FSTEST_DIR"

068 touch $tmp.running · line 106

Quoted 10 lines
068 +10 -0
+
+    procs=2
+    while [ -f "$tmp.running" ]
+      do
+      src/fstest -m -p $FSTEST_DIR  -n $procs -f 4 > /dev/null 2>&1
+    done
+
+    rm -rf $FSTEST_DIR/*
+    rmdir $FSTEST_DIR
+} &

Looks good.

Signature · 7 lines
Dave Chinner
[email protected]

_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
Reviewed-by on v1 1/1
#2 lore raw
In reply to Eric Sandeen
Quoted 8 lines · Eric Sandeen

Test 068 is the go-to test for freeze deadlock coverage; unfortunately it only uses fsstress, which doesn't do any mmap IO.

Using the existing fstest binary gets us a cheap mmap exerciser as well.

Looks good,

_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs

#3 lore raw
In reply to Eric Sandeen
Quoted 10 lines · Eric Sandeen

Test 068 is the go-to test for freeze deadlock coverage; unfortunately it only uses fsstress, which doesn't do any mmap IO.

Using the existing fstest binary gets us a cheap mmap exerciser as well.

---

Quoted 8 lines

I think it's fair to modify this test vs. making a new one - it's never passed yet, and will only start passing in kernel 3.6, so it shouldn't cause new test regressions to add mmap ops.

And I can verify that this finds mmap bugs; I had a backport which messed up ext4's freeze vs. mmap handling, and this exposes it. :)

Committed to git://oss.sgi.com/xfs/cmds/xfs.git, master branch.

--Mark.

_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs