From a558d5dc226efd23f7f5c8e7a3ec044239ed292d Mon Sep 17 00:00:00 2001 From: Theodore Ts'o Date: Thu, 25 Dec 2008 22:47:03 -0500 Subject: [PATCH] Add e2fsck regression test case f_extent_bad_node 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" --- tests/f_extent_bad_node/expect.1 | 23 +++++++++++++++++++++++ tests/f_extent_bad_node/expect.2 | 7 +++++++ tests/f_extent_bad_node/image.gz | Bin 0 -> 1254 bytes tests/f_extent_bad_node/name | 1 + 4 files changed, 31 insertions(+) create mode 100644 tests/f_extent_bad_node/expect.1 create mode 100644 tests/f_extent_bad_node/expect.2 create mode 100644 tests/f_extent_bad_node/image.gz create mode 100644 tests/f_extent_bad_node/name diff --git a/tests/f_extent_bad_node/expect.1 b/tests/f_extent_bad_node/expect.1 new file mode 100644 index 0000000..0c0bc28 --- /dev/null +++ b/tests/f_extent_bad_node/expect.1 @@ -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 index 0000000..568c792 --- /dev/null +++ b/tests/f_extent_bad_node/expect.2 @@ -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 index 0000000000000000000000000000000000000000..01d9b45f1e7e42acac0a469e2410615338ea2a4a GIT binary patch literal 1254 zcmci0{X5eM008js@;o)2)SYTx>RGts+zb(_9h$Vr%UUsWXLga1mq^OXVUp!-;c8(R zcXmw9%QLgKlYXkb~I zonR8Z@6ih1;=s0}`E;ja%5RHqbU!q5o@bU@o{#GwtT}c2a>LT&KdH^ z&Y6&Qy_-u0Oj~gSaLCk(gTr+i#pt(MAvm8NbjX&#p=nbEJZpK756Q<==P9V(qYMjlbRbIj+A9~E z=cR$Y@&Xo+fNE#%`nF?QgI{&9(|Vwp2K?86Q7jK<)#np?Y2*|)l^}0Vt_%&rU)VF! z7m-9y$_!S~dtGA0yKZMi)WZiU2lg(UBgD9seA+(ECd?{BMD_^f7A!%oB5vn2{N+u^ zJ4pWeEcH;MTi9dY*p*b$!@JM^jCx$*=$il15QA2d%z5^ z&Ms<^SS66I3gL~3PXgdS;s@TI7-SBIpoxNVk7K0nLy{os!LL~RihqGyh;WD7`cFJ9 zTx4B@V`bcr`Cx059>%!VcKJP7y_e|Mg48Zjq6alyYGGG#m=he zF72bWtIzqoYuBY;a6&lo#%g0SVKpap>SyAFM2@gQD|$WtsmfX^*g%3@4i#dKR-mK& z!P;a+`(<~wl$dcrcKjQQu{U@JeVh!HJwYSdVk$i^*{kGtr*?Ykk`;B;{solk(;*Vg z;6hP>&0^V2&zE;dJ;E%VQbSqVclCE@{9)%3HZ4YrxrXtUQlIxox%CmqkWh3pEpE1{ zalhs4Fg*~xqpX#bJ+7Z**H31q$~7*Ds|H;bYFZ}5u`L7n6Ev#6vM!8vKSc)2g)eCmPfRA2UEo~MIW-OR Ks_{TM4EPtl`%)kP literal 0 HcmV?d00001 diff --git a/tests/f_extent_bad_node/name b/tests/f_extent_bad_node/name new file mode 100644 index 0000000..9c9d79f --- /dev/null +++ b/tests/f_extent_bad_node/name @@ -0,0 +1 @@ +bad interior node in extent tree -- 1.8.3.1