Whamcloud - gitweb
Add e2fsck regression test case f_extent_bad_node
authorTheodore Ts'o <tytso@mit.edu>
Fri, 26 Dec 2008 03:47:03 +0000 (22:47 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Fri, 26 Dec 2008 03:47:03 +0000 (22:47 -0500)
This test case is designed to test e2fsck's ability to deal with a
corrupted interior node in an extent tree.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
tests/f_extent_bad_node/expect.1 [new file with mode: 0644]
tests/f_extent_bad_node/expect.2 [new file with mode: 0644]
tests/f_extent_bad_node/image.gz [new file with mode: 0644]
tests/f_extent_bad_node/name [new file with mode: 0644]

diff --git a/tests/f_extent_bad_node/expect.1 b/tests/f_extent_bad_node/expect.1
new file mode 100644 (file)
index 0000000..0c0bc28
--- /dev/null
@@ -0,0 +1,23 @@
+Pass 1: Checking inodes, blocks, and sizes
+Inode 12 has an invalid extent node (blk 22, lblk 0)
+Clear? yes
+
+Inode 12, i_blocks is 16, should be 8.  Fix? yes
+
+Pass 2: Checking directory structure
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Pass 5: Checking group summary information
+Block bitmap differences:  -(21--23) -25
+Fix? yes
+
+Free blocks count wrong for group #0 (71, counted=75).
+Fix? yes
+
+Free blocks count wrong (71, counted=75).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 12/16 files (0.0% non-contiguous), 25/100 blocks
+Exit status is 1
diff --git a/tests/f_extent_bad_node/expect.2 b/tests/f_extent_bad_node/expect.2
new file mode 100644 (file)
index 0000000..568c792
--- /dev/null
@@ -0,0 +1,7 @@
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Pass 5: Checking group summary information
+test_filesys: 12/16 files (0.0% non-contiguous), 25/100 blocks
+Exit status is 0
diff --git a/tests/f_extent_bad_node/image.gz b/tests/f_extent_bad_node/image.gz
new file mode 100644 (file)
index 0000000..01d9b45
Binary files /dev/null and b/tests/f_extent_bad_node/image.gz differ
diff --git a/tests/f_extent_bad_node/name b/tests/f_extent_bad_node/name
new file mode 100644 (file)
index 0000000..9c9d79f
--- /dev/null
@@ -0,0 +1 @@
+bad interior node in extent tree