aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/f_bad_encryption/expect.1125
-rw-r--r--tests/f_bad_encryption/expect.27
-rw-r--r--tests/f_bad_encryption/image.gzbin0 -> 2265 bytes
-rwxr-xr-xtests/f_bad_encryption/mkimage.sh169
-rw-r--r--tests/f_bad_encryption/name1
-rw-r--r--tests/f_bb_in_bb/expect.12
-rw-r--r--tests/f_many_subdirs/expect.145
-rw-r--r--tests/f_many_subdirs/expect.27
-rw-r--r--tests/f_many_subdirs/image.gzbin0 -> 1816025 bytes
-rw-r--r--tests/f_many_subdirs/name1
-rw-r--r--tests/f_opt_extent/expect6
-rw-r--r--tests/f_short_encrypted_dirent/expect.12
-rw-r--r--tests/f_short_encrypted_dirent/expect.22
-rw-r--r--tests/f_short_encrypted_dirent/image.gzbin925 -> 1008 bytes
-rw-r--r--tests/f_uninit_bad_free_inodes/expect.125
-rw-r--r--tests/f_uninit_bad_free_inodes/expect.27
-rw-r--r--tests/f_uninit_bad_free_inodes/image.gzbin0 -> 114234 bytes
-rw-r--r--tests/f_uninit_bad_free_inodes/name1
-rw-r--r--tests/f_uninit_blk_used_not_set/expect.134
-rw-r--r--tests/f_uninit_blk_used_not_set/expect.27
-rw-r--r--tests/f_uninit_blk_used_not_set/image.gzbin0 -> 56712 bytes
-rw-r--r--tests/f_uninit_blk_used_not_set/name1
-rw-r--r--tests/f_uninit_checksum_bad/expect.129
-rw-r--r--tests/f_uninit_checksum_bad/expect.27
-rw-r--r--tests/f_uninit_checksum_bad/image.gzbin0 -> 42374 bytes
-rw-r--r--tests/f_uninit_checksum_bad/name1
-rw-r--r--tests/f_uninit_disable/expect.110
-rw-r--r--tests/f_uninit_disable/expect.27
-rw-r--r--tests/f_uninit_disable/image.gzbin0 -> 10792 bytes
-rw-r--r--tests/f_uninit_disable/name1
-rw-r--r--tests/f_uninit_enable/expect.110
-rw-r--r--tests/f_uninit_enable/expect.27
-rw-r--r--tests/f_uninit_enable/image.gzbin0 -> 10787 bytes
-rw-r--r--tests/f_uninit_enable/name1
-rw-r--r--tests/f_uninit_inode_past_unused/expect.127
-rw-r--r--tests/f_uninit_inode_past_unused/expect.27
-rw-r--r--tests/f_uninit_inode_past_unused/image.gzbin0 -> 10929 bytes
-rw-r--r--tests/f_uninit_inode_past_unused/name1
-rw-r--r--tests/f_uninit_restart_fsck/expect.136
-rw-r--r--tests/f_uninit_restart_fsck/expect.27
-rw-r--r--tests/f_uninit_restart_fsck/image.gzbin0 -> 91233 bytes
-rw-r--r--tests/f_uninit_restart_fsck/name1
-rw-r--r--tests/f_uninit_set_inode_not_set/expect.125
-rw-r--r--tests/f_uninit_set_inode_not_set/expect.27
-rw-r--r--tests/f_uninit_set_inode_not_set/image.gzbin0 -> 115285 bytes
-rw-r--r--tests/f_uninit_set_inode_not_set/name1
-rw-r--r--tests/j_corrupt_journal_block/expect2
-rw-r--r--tests/m_64bit_flexbg/expect.11
-rw-r--r--tests/m_bigjournal/expect.11
-rw-r--r--tests/m_dasd_bs/expect.11
-rw-r--r--tests/m_desc_size_128/expect.11
-rw-r--r--tests/m_extent_journal/expect.11
-rw-r--r--tests/m_large_file/expect.11
-rw-r--r--tests/m_meta_bg/expect.11
-rw-r--r--tests/m_minrootdir/expect1
-rw-r--r--tests/m_mmp/expect.11
-rw-r--r--tests/m_no_opt/expect.11
-rw-r--r--tests/m_quota/expect.11
-rw-r--r--tests/m_raid_opt/expect.11
-rw-r--r--tests/m_resize_inode_meta_bg/expect.11
-rw-r--r--tests/m_root_owner/expect.11
-rw-r--r--tests/m_rootdir/expect1
-rw-r--r--tests/m_std/expect.11
-rw-r--r--tests/m_uninit/expect.11
-rw-r--r--tests/r_32to64bit/expect14
-rw-r--r--tests/r_32to64bit_meta/expect7
-rw-r--r--tests/r_32to64bit_move_itable/expect11
-rw-r--r--tests/r_64to32bit/expect9
-rw-r--r--tests/r_64to32bit_meta/expect7
-rw-r--r--tests/t_disable_mcsum/expect2
-rw-r--r--tests/t_disable_mcsum_noinitbg/expect4
-rw-r--r--tests/t_disable_mcsum_yesinitbg/expect2
-rw-r--r--tests/t_enable_mcsum/expect8
-rw-r--r--tests/t_enable_mcsum_ext3/expect8
-rw-r--r--tests/t_enable_mcsum_initbg/expect8
-rw-r--r--tests/t_iexpand_full/expect6
-rw-r--r--tests/t_iexpand_mcsum/expect6
77 files changed, 691 insertions, 47 deletions
diff --git a/tests/f_bad_encryption/expect.1 b/tests/f_bad_encryption/expect.1
new file mode 100644
index 00000000..d743e66f
--- /dev/null
+++ b/tests/f_bad_encryption/expect.1
@@ -0,0 +1,125 @@
+Pass 1: Checking inodes, blocks, and sizes
+Inode 17 has encrypt flag but no encryption extended attribute.
+Clear flag? yes
+
+Inode 18 has encrypt flag but no encryption extended attribute.
+Clear flag? yes
+
+Encrypted inode 19 has corrupt encryption extended attribute.
+Clear inode? yes
+
+Encrypted inode 20 has corrupt encryption extended attribute.
+Clear inode? yes
+
+Encrypted inode 21 has corrupt encryption extended attribute.
+Clear inode? yes
+
+Encrypted inode 22 has corrupt encryption extended attribute.
+Clear inode? yes
+
+Pass 2: Checking directory structure
+Encrypted entry 'd6M->'M-#I^VM-^KM-F~^WSJ+M-uM-zM-zXM-^' in /edir (12) references unencrypted inode 17.
+Clear? yes
+
+Encrypted entry '\M-!M-Y%DhM-OM-VM-zM-CM-gVM-R3M-^RM-IkE^JM-^S' in /edir (12) references unencrypted inode 18.
+Clear? yes
+
+Entry 'M-{^Qp-M-sM-U7eM-^C^L^PG^ZM-FM-,M-B' in /edir (12) has deleted/unused inode 19. Clear? yes
+
+Entry 'M-f0M-f3/M-NM-GM-:M-^YM-jM-XM-91DM-^_M-V' in /edir (12) has deleted/unused inode 20. Clear? yes
+
+Entry '^M-R"M-^K^P7M-'M-EM-C}^MM-yM-^LwM-^N^Z' in /edir (12) has deleted/unused inode 21. Clear? yes
+
+Entry 'M-s^J_;uIvM-^Z[M-nIM-5vM-^AcM-o' in /edir (12) has deleted/unused inode 22. Clear? yes
+
+Encrypted entry 'kK=,M-bM-^AM-{M-YM-^J6M-hM-y^XM-^W}M-M' in /edir (12) references unencrypted inode 23.
+Clear? yes
+
+Encrypted entry 'M-VM-cxM-jM-zM-b^WM-o*M-jM-uM-,R^PM-hM-2' in /edir (12) references unencrypted inode 24.
+Clear? yes
+
+Encrypted entry 'UqM-AM-#KM-^PM-_^kM-9P0M-^FM-_^@;A^J"R' in /edir (12) references unencrypted inode 25.
+Clear? yes
+
+Encrypted entry 'M-TM-N8^[M-3M-( M-[A^FR}^ZhkM-^?=M-c^Mo' in /edir (12) references inode 26, which has a different encryption policy.
+Clear? yes
+
+Encrypted entry 'M--aM-^?~M-^\M-u^FM-/!^YM-OZM-^LM-)M-p1' in /edir (12) references inode 27, which has a different encryption policy.
+Clear? yes
+
+Encrypted entry '(M-8RKM-LM-eM-^W^[M-'M-SM-@uM-^VM-|M-GiM-^JbM-nM-z' in /edir (12) references inode 28, which has a different encryption policy.
+Clear? yes
+
+Encrypted entry '\M-ggCeM-/?M-^BM-{(M-^OM-9M-^QQAM-^N=M-c^Mo' in /edir (12) references inode 29, which has a different encryption policy.
+Clear? yes
+
+Pass 3: Checking directory connectivity
+Unconnected directory inode 18 (/edir/???)
+Connect to /lost+found? yes
+
+Unconnected directory inode 24 (/edir/???)
+Connect to /lost+found? yes
+
+Unconnected directory inode 27 (/edir/???)
+Connect to /lost+found? yes
+
+Pass 4: Checking reference counts
+Unattached inode 17
+Connect to /lost+found? yes
+
+Inode 17 ref count is 2, should be 1. Fix? yes
+
+Inode 18 ref count is 3, should be 2. Fix? yes
+
+Unattached inode 23
+Connect to /lost+found? yes
+
+Inode 23 ref count is 2, should be 1. Fix? yes
+
+Inode 24 ref count is 3, should be 2. Fix? yes
+
+Unattached inode 25
+Connect to /lost+found? yes
+
+Inode 25 ref count is 2, should be 1. Fix? yes
+
+Unattached inode 26
+Connect to /lost+found? yes
+
+Inode 26 ref count is 2, should be 1. Fix? yes
+
+Inode 27 ref count is 3, should be 2. Fix? yes
+
+Unattached inode 28
+Connect to /lost+found? yes
+
+Inode 28 ref count is 2, should be 1. Fix? yes
+
+Unattached inode 29
+Connect to /lost+found? yes
+
+Inode 29 ref count is 2, should be 1. Fix? yes
+
+Pass 5: Checking group summary information
+Block bitmap differences: -(25--32)
+Fix? yes
+
+Free blocks count wrong for group #0 (75, counted=83).
+Fix? yes
+
+Free blocks count wrong (75, counted=83).
+Fix? yes
+
+Inode bitmap differences: -(19--22)
+Fix? yes
+
+Free inodes count wrong for group #0 (95, counted=99).
+Fix? yes
+
+Free inodes count wrong (95, counted=99).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 29/128 files (0.0% non-contiguous), 45/128 blocks
+Exit status is 1
diff --git a/tests/f_bad_encryption/expect.2 b/tests/f_bad_encryption/expect.2
new file mode 100644
index 00000000..fcfabdbd
--- /dev/null
+++ b/tests/f_bad_encryption/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: 29/128 files (0.0% non-contiguous), 45/128 blocks
+Exit status is 0
diff --git a/tests/f_bad_encryption/image.gz b/tests/f_bad_encryption/image.gz
new file mode 100644
index 00000000..64b59b78
--- /dev/null
+++ b/tests/f_bad_encryption/image.gz
Binary files differ
diff --git a/tests/f_bad_encryption/mkimage.sh b/tests/f_bad_encryption/mkimage.sh
new file mode 100755
index 00000000..e58395df
--- /dev/null
+++ b/tests/f_bad_encryption/mkimage.sh
@@ -0,0 +1,169 @@
+#!/bin/bash
+#
+# This is the script that was used to create the image.gz in this directory.
+#
+# This requires a patched version of debugfs that understands the "fscrypt."
+# xattr name prefix, so that the encryption xattrs can be manipulated.
+
+set -e -u
+umask 0022
+
+do_debugfs() {
+ umount mnt
+ debugfs -w "$@" image
+ mount image mnt
+}
+
+create_encrypted_file() {
+ local file=$1
+ local ino
+
+ echo foo > "$file"
+
+ # not needed, but makes image more compressible
+ ino=$(stat -c %i "$file")
+ do_debugfs -R "zap_block -f <$ino> 0"
+}
+
+set_encryption_xattr() {
+ local file=$1
+ local value=$2
+ local ino
+
+ ino=$(stat -c %i "$file")
+ do_debugfs -R "ea_set <$ino> fscrypt.c $value"
+}
+
+rm_encryption_xattr() {
+ local file=$1
+ local ino
+
+ ino=$(stat -c %i "$file")
+ do_debugfs -R "ea_rm <$ino> fscrypt.c"
+}
+
+clear_encrypt_flag() {
+ local file=$1
+ local ino
+
+ ino=$(stat -c %i "$file")
+ do_debugfs -R "set_inode_field <$ino> flags 0"
+}
+
+clear_encryption() {
+ local file=$1
+ local ino
+ local is_symlink=false
+
+ if [ -L "$file" ]; then
+ is_symlink=true
+ fi
+ ino=$(stat -c %i "$file")
+
+ do_debugfs -R "ea_rm <$ino> fscrypt.c"
+ do_debugfs -R "set_inode_field <$ino> flags 0"
+ if $is_symlink; then
+ do_debugfs -R "set_inode_field <$ino> block[0] 0xAAAAAAAA"
+ do_debugfs -R "set_inode_field <$ino> block[1] 0"
+ do_debugfs -R "set_inode_field <$ino> size 4"
+ fi
+}
+
+mkdir -p mnt
+umount mnt &> /dev/null || true
+
+dd if=/dev/zero of=image bs=4096 count=128
+mke2fs -O encrypt -b 4096 -N 128 image
+mount image mnt
+
+# Create an encrypted directory (ino 12)
+dir=mnt/edir
+mkdir $dir
+echo password | e4crypt add_key $dir
+
+# Control cases: valid encrypted regular file, dir, and symlink (ino 13-15)
+create_encrypted_file $dir/encrypted_file
+mkdir $dir/encrypted_dir
+ln -s target $dir/encrypted_symlink
+
+# Control case: file type that is never encrypted (ino 16)
+mkfifo $dir/fifo
+
+# Inodes with missing encryption xattr (ino 17-18).
+# e2fsck should offer to clear the encrypt flag on these inodes.
+
+create_encrypted_file $dir/missing_xattr_file
+rm_encryption_xattr $dir/missing_xattr_file
+
+mkdir $dir/missing_xattr_dir
+rm_encryption_xattr $dir/missing_xattr_dir
+
+# Inodes with corrupt encryption xattr (ino 19-22).
+# e2fsck should offer to clear these inodes.
+
+create_encrypted_file $dir/corrupt_xattr_1
+set_encryption_xattr $dir/corrupt_xattr_1 '\0'
+
+create_encrypted_file $dir/corrupt_xattr_2
+set_encryption_xattr $dir/corrupt_xattr_2 \
+ '\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0'
+
+create_encrypted_file $dir/corrupt_xattr_3
+set_encryption_xattr $dir/corrupt_xattr_3 '\1'
+
+create_encrypted_file $dir/corrupt_xattr_4
+set_encryption_xattr $dir/corrupt_xattr_4 '\2'
+
+# Unencrypted inodes in encrypted directory (ino 23-25).
+# e2fsck should offer to clear these directory entries.
+
+create_encrypted_file $dir/unencrypted_file
+clear_encryption $dir/unencrypted_file
+
+mkdir $dir/unencrypted_dir
+clear_encryption $dir/unencrypted_dir
+
+ln -s target $dir/unencrypted_symlink
+clear_encryption $dir/unencrypted_symlink
+
+# Inodes with different encryption policy in encrypted directory (ino 26-29).
+# e2fsck should offer to clear these directory entries.
+
+xattr='\1\1\4\0AAAAAAAABBBBBBBBBBBBBBBB'
+
+create_encrypted_file $dir/inconsistent_file_1
+set_encryption_xattr $dir/inconsistent_file_1 $xattr
+
+mkdir $dir/inconsistent_dir
+set_encryption_xattr $dir/inconsistent_dir $xattr
+
+ln -s target $dir/inconsistent_symlink
+set_encryption_xattr $dir/inconsistent_symlink $xattr
+
+xattr='\2\1\4\0\0\0\0\0AAAAAAAAAAAAAAAABBBBBBBBBBBBBBBB'
+create_encrypted_file $dir/inconsistent_file_2
+set_encryption_xattr $dir/inconsistent_file_2 $xattr
+
+# Encrypted file and directory with valid v2 encryption policy (ino 30-31).
+# e2fsck shouldn't change these.
+dir2=mnt/edir2
+mkdir $dir2
+echo password | e4crypt add_key $dir2
+xattr='\2\1\4\0\0\0\0\0AAAAAAAAAAAAAAAABBBBBBBBBBBBBBBB'
+create_encrypted_file $dir2/file
+set_encryption_xattr $dir2/file $xattr
+set_encryption_xattr $dir2 $xattr
+
+# Encrypted file and directory with unrecognized encryption policy version
+# (ino 32-33). e2fsck shouldn't change these.
+dir3=mnt/edir3
+mkdir $dir3
+echo password | e4crypt add_key $dir3
+xattr='\3'
+create_encrypted_file $dir3/file
+set_encryption_xattr $dir3/file $xattr
+set_encryption_xattr $dir3 $xattr
+
+umount mnt
+rmdir mnt
+gzip -9 -f image
diff --git a/tests/f_bad_encryption/name b/tests/f_bad_encryption/name
new file mode 100644
index 00000000..85b19eda
--- /dev/null
+++ b/tests/f_bad_encryption/name
@@ -0,0 +1 @@
+missing, corrupt, and inconsistent encryption policies
diff --git a/tests/f_bb_in_bb/expect.1 b/tests/f_bb_in_bb/expect.1
index 1d719e51..1bd697ec 100644
--- a/tests/f_bb_in_bb/expect.1
+++ b/tests/f_bb_in_bb/expect.1
@@ -1,6 +1,8 @@
Pass 1: Checking inodes, blocks, and sizes
Bad block list says the bad block list inode is bad. Clear inode? yes
+Restarting e2fsck from the beginning...
+Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
diff --git a/tests/f_many_subdirs/expect.1 b/tests/f_many_subdirs/expect.1
new file mode 100644
index 00000000..f2fd78f7
--- /dev/null
+++ b/tests/f_many_subdirs/expect.1
@@ -0,0 +1,45 @@
+Pass 1: Checking inodes, blocks, and sizes
+Deleted inode 26363 has zero dtime. Fix? yes
+
+Pass 2: Checking directory structure
+Entry 'nlink_eq_0' in / (2) has deleted/unused inode 26363. Clear? yes
+
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Inode 2 ref count is 9, should be 8. Fix? yes
+
+Inode 13201 ref count is 1, should be 2. Fix? yes
+
+Inode 19763 ref count is 65535, should be 2. Fix? yes
+
+Directory exceeds max links, but no DIR_NLINK feature in superblock.
+Fix? yes
+
+Inode 32963 ref count is 65000, should be 2. Fix? yes
+
+Pass 5: Checking group summary information
+Block bitmap differences: -73383
+Fix? yes
+
+Free blocks count wrong for group #8 (0, counted=1).
+Fix? yes
+
+Free blocks count wrong (5388, counted=5389).
+Fix? yes
+
+Inode bitmap differences: -26363
+Fix? yes
+
+Free inodes count wrong for group #3 (37, counted=38).
+Fix? yes
+
+Directories count wrong for group #3 (6563, counted=6562).
+Fix? yes
+
+Free inodes count wrong (382, counted=383).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 65617/66000 files (0.0% non-contiguous), 76531/81920 blocks
+Exit status is 1
diff --git a/tests/f_many_subdirs/expect.2 b/tests/f_many_subdirs/expect.2
new file mode 100644
index 00000000..bb0d8291
--- /dev/null
+++ b/tests/f_many_subdirs/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: 65617/66000 files (0.0% non-contiguous), 76531/81920 blocks
+Exit status is 0
diff --git a/tests/f_many_subdirs/image.gz b/tests/f_many_subdirs/image.gz
new file mode 100644
index 00000000..7f60fffc
--- /dev/null
+++ b/tests/f_many_subdirs/image.gz
Binary files differ
diff --git a/tests/f_many_subdirs/name b/tests/f_many_subdirs/name
new file mode 100644
index 00000000..6264a60e
--- /dev/null
+++ b/tests/f_many_subdirs/name
@@ -0,0 +1 @@
+directory with more than 65000 sub-directories
diff --git a/tests/f_opt_extent/expect b/tests/f_opt_extent/expect
index 6d4863b5..6d1f9d11 100644
--- a/tests/f_opt_extent/expect
+++ b/tests/f_opt_extent/expect
@@ -26,16 +26,16 @@ Pass 5: Checking group summary information
Change in FS metadata:
-@@ -10,7 +10,7 @@
- Inode count: 65536
+@@ -11,7 +11,7 @@
Block count: 524288
Reserved block count: 26214
+ Overhead clusters: 35246
-Free blocks: 570
+Free blocks: 567
Free inodes: 65047
First block: 1
Block size: 1024
-@@ -47,8 +47,8 @@
+@@ -48,8 +48,8 @@
Block bitmap at 262 (+261)
Inode bitmap at 278 (+277)
Inode table at 294-549 (+293)
diff --git a/tests/f_short_encrypted_dirent/expect.1 b/tests/f_short_encrypted_dirent/expect.1
index bc649222..29e1625c 100644
--- a/tests/f_short_encrypted_dirent/expect.1
+++ b/tests/f_short_encrypted_dirent/expect.1
@@ -13,5 +13,5 @@ Inode 13 ref count is 2, should be 1. Fix? yes
Pass 5: Checking group summary information
test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
-test_filesys: 13/16 files (0.0% non-contiguous), 23/100 blocks
+test_filesys: 13/16 files (0.0% non-contiguous), 24/100 blocks
Exit status is 1
diff --git a/tests/f_short_encrypted_dirent/expect.2 b/tests/f_short_encrypted_dirent/expect.2
index 636c6e9e..1ebd598e 100644
--- a/tests/f_short_encrypted_dirent/expect.2
+++ b/tests/f_short_encrypted_dirent/expect.2
@@ -3,5 +3,5 @@ Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
-test_filesys: 13/16 files (0.0% non-contiguous), 23/100 blocks
+test_filesys: 13/16 files (0.0% non-contiguous), 24/100 blocks
Exit status is 0
diff --git a/tests/f_short_encrypted_dirent/image.gz b/tests/f_short_encrypted_dirent/image.gz
index a35bfb23..7eb1c951 100644
--- a/tests/f_short_encrypted_dirent/image.gz
+++ b/tests/f_short_encrypted_dirent/image.gz
Binary files differ
diff --git a/tests/f_uninit_bad_free_inodes/expect.1 b/tests/f_uninit_bad_free_inodes/expect.1
new file mode 100644
index 00000000..23d7b1f6
--- /dev/null
+++ b/tests/f_uninit_bad_free_inodes/expect.1
@@ -0,0 +1,25 @@
+Group descriptor 1 has invalid unused inodes count 2048. Fix? yes
+
+Group descriptor 2 has invalid unused inodes count 1344. Fix? yes
+
+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
+Free inodes count wrong for group #1 (490, counted=2048).
+Fix? yes
+
+Free inodes count wrong for group #2 (250, counted=1344).
+Fix? yes
+
+Free inodes count wrong for group #3 (1967, counted=1969).
+Fix? yes
+
+Free inodes count wrong (4744, counted=7398).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 794/8192 files (0.4% non-contiguous), 8473/32768 blocks
+Exit status is 1
diff --git a/tests/f_uninit_bad_free_inodes/expect.2 b/tests/f_uninit_bad_free_inodes/expect.2
new file mode 100644
index 00000000..431227b2
--- /dev/null
+++ b/tests/f_uninit_bad_free_inodes/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: 794/8192 files (0.4% non-contiguous), 8473/32768 blocks
+Exit status is 0
diff --git a/tests/f_uninit_bad_free_inodes/image.gz b/tests/f_uninit_bad_free_inodes/image.gz
new file mode 100644
index 00000000..3e6218b5
--- /dev/null
+++ b/tests/f_uninit_bad_free_inodes/image.gz
Binary files differ
diff --git a/tests/f_uninit_bad_free_inodes/name b/tests/f_uninit_bad_free_inodes/name
new file mode 100644
index 00000000..8bd31800
--- /dev/null
+++ b/tests/f_uninit_bad_free_inodes/name
@@ -0,0 +1 @@
+bad free inode count, but good checksum
diff --git a/tests/f_uninit_blk_used_not_set/expect.1 b/tests/f_uninit_blk_used_not_set/expect.1
new file mode 100644
index 00000000..9e473f87
--- /dev/null
+++ b/tests/f_uninit_blk_used_not_set/expect.1
@@ -0,0 +1,34 @@
+Group descriptor 1 has invalid unused inodes count 2048. Fix? yes
+
+Group descriptor 2 has invalid unused inodes count 2048. Fix? yes
+
+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
+Group 1 block(s) in use but group is marked BLOCK_UNINIT
+Fix? yes
+
+Block bitmap differences: +(8585--8777)
+Fix? yes
+
+Free blocks count wrong for group #2 (0, counted=7934).
+Fix? yes
+
+Free blocks count wrong (19530, counted=27464).
+Fix? yes
+
+Free inodes count wrong for group #1 (0, counted=2048).
+Fix? yes
+
+Free inodes count wrong for group #2 (0, counted=2048).
+Fix? yes
+
+Free inodes count wrong (4084, counted=8180).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 12/8192 files (8.3% non-contiguous), 5304/32768 blocks
+Exit status is 1
diff --git a/tests/f_uninit_blk_used_not_set/expect.2 b/tests/f_uninit_blk_used_not_set/expect.2
new file mode 100644
index 00000000..17d0cfa0
--- /dev/null
+++ b/tests/f_uninit_blk_used_not_set/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/8192 files (8.3% non-contiguous), 5304/32768 blocks
+Exit status is 0
diff --git a/tests/f_uninit_blk_used_not_set/image.gz b/tests/f_uninit_blk_used_not_set/image.gz
new file mode 100644
index 00000000..63162859
--- /dev/null
+++ b/tests/f_uninit_blk_used_not_set/image.gz
Binary files differ
diff --git a/tests/f_uninit_blk_used_not_set/name b/tests/f_uninit_blk_used_not_set/name
new file mode 100644
index 00000000..e6ee718a
--- /dev/null
+++ b/tests/f_uninit_blk_used_not_set/name
@@ -0,0 +1 @@
+blocks used but block uninit set
diff --git a/tests/f_uninit_checksum_bad/expect.1 b/tests/f_uninit_checksum_bad/expect.1
new file mode 100644
index 00000000..4ff8a8bf
--- /dev/null
+++ b/tests/f_uninit_checksum_bad/expect.1
@@ -0,0 +1,29 @@
+One or more block group descriptor checksums are invalid. Fix? yes
+
+Group descriptor 1 checksum is 0xbbaa, should be 0xff0b. FIXED.
+Group descriptor 2 has invalid unused inodes count 2048. Fix? yes
+
+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
+Free blocks count wrong for group #2 (0, counted=7934).
+Fix? yes
+
+Free blocks count wrong (19286, counted=27220).
+Fix? yes
+
+Free inodes count wrong for group #1 (0, counted=2048).
+Fix? yes
+
+Free inodes count wrong for group #2 (0, counted=2048).
+Fix? yes
+
+Free inodes count wrong (4085, counted=8181).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 11/8192 files (0.0% non-contiguous), 5548/32768 blocks
+Exit status is 1
diff --git a/tests/f_uninit_checksum_bad/expect.2 b/tests/f_uninit_checksum_bad/expect.2
new file mode 100644
index 00000000..38f23347
--- /dev/null
+++ b/tests/f_uninit_checksum_bad/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: 11/8192 files (0.0% non-contiguous), 5548/32768 blocks
+Exit status is 0
diff --git a/tests/f_uninit_checksum_bad/image.gz b/tests/f_uninit_checksum_bad/image.gz
new file mode 100644
index 00000000..8e91e014
--- /dev/null
+++ b/tests/f_uninit_checksum_bad/image.gz
Binary files differ
diff --git a/tests/f_uninit_checksum_bad/name b/tests/f_uninit_checksum_bad/name
new file mode 100644
index 00000000..b9e4a31e
--- /dev/null
+++ b/tests/f_uninit_checksum_bad/name
@@ -0,0 +1 @@
+invalid group descriptor checksum
diff --git a/tests/f_uninit_disable/expect.1 b/tests/f_uninit_disable/expect.1
new file mode 100644
index 00000000..f568bec4
--- /dev/null
+++ b/tests/f_uninit_disable/expect.1
@@ -0,0 +1,10 @@
+Group descriptor 0 marked uninitialized without feature set.
+Fix? yes
+
+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: 11/2048 files (0.0% non-contiguous), 306/8192 blocks
+Exit status is 1
diff --git a/tests/f_uninit_disable/expect.2 b/tests/f_uninit_disable/expect.2
new file mode 100644
index 00000000..4cd9aa98
--- /dev/null
+++ b/tests/f_uninit_disable/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: 11/2048 files (0.0% non-contiguous), 306/8192 blocks
+Exit status is 0
diff --git a/tests/f_uninit_disable/image.gz b/tests/f_uninit_disable/image.gz
new file mode 100644
index 00000000..38c74556
--- /dev/null
+++ b/tests/f_uninit_disable/image.gz
Binary files differ
diff --git a/tests/f_uninit_disable/name b/tests/f_uninit_disable/name
new file mode 100644
index 00000000..494b4720
--- /dev/null
+++ b/tests/f_uninit_disable/name
@@ -0,0 +1 @@
+disable uninit_bg feature
diff --git a/tests/f_uninit_enable/expect.1 b/tests/f_uninit_enable/expect.1
new file mode 100644
index 00000000..02801bf9
--- /dev/null
+++ b/tests/f_uninit_enable/expect.1
@@ -0,0 +1,10 @@
+One or more block group descriptor checksums are invalid. Fix? yes
+
+Group descriptor 0 checksum is 0x0000, should be 0x13f6. FIXED.
+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: 11/2048 files (0.0% non-contiguous), 306/8192 blocks
+Exit status is 1
diff --git a/tests/f_uninit_enable/expect.2 b/tests/f_uninit_enable/expect.2
new file mode 100644
index 00000000..4cd9aa98
--- /dev/null
+++ b/tests/f_uninit_enable/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: 11/2048 files (0.0% non-contiguous), 306/8192 blocks
+Exit status is 0
diff --git a/tests/f_uninit_enable/image.gz b/tests/f_uninit_enable/image.gz
new file mode 100644
index 00000000..4da79c96
--- /dev/null
+++ b/tests/f_uninit_enable/image.gz
Binary files differ
diff --git a/tests/f_uninit_enable/name b/tests/f_uninit_enable/name
new file mode 100644
index 00000000..a818f5c0
--- /dev/null
+++ b/tests/f_uninit_enable/name
@@ -0,0 +1 @@
+enable uninit_bg feature
diff --git a/tests/f_uninit_inode_past_unused/expect.1 b/tests/f_uninit_inode_past_unused/expect.1
new file mode 100644
index 00000000..1cf5c85c
--- /dev/null
+++ b/tests/f_uninit_inode_past_unused/expect.1
@@ -0,0 +1,27 @@
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Entry 'foo' in / (2) references inode 14 found in group 0's unused inodes area.
+Fix? yes
+
+Restarting e2fsck from the beginning...
+One or more block group descriptor checksums are invalid. Fix? yes
+
+Group descriptor 0 checksum is 0x4c72, should be 0xde74. FIXED.
+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
+Inode bitmap differences: -12
+Fix? yes
+
+Free inodes count wrong for group #0 (2037, counted=2035).
+Fix? yes
+
+Free inodes count wrong (4073, counted=2035).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 13/2048 files (0.0% non-contiguous), 1336/8192 blocks
+Exit status is 1
diff --git a/tests/f_uninit_inode_past_unused/expect.2 b/tests/f_uninit_inode_past_unused/expect.2
new file mode 100644
index 00000000..bdb029ee
--- /dev/null
+++ b/tests/f_uninit_inode_past_unused/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: 13/2048 files (0.0% non-contiguous), 1336/8192 blocks
+Exit status is 0
diff --git a/tests/f_uninit_inode_past_unused/image.gz b/tests/f_uninit_inode_past_unused/image.gz
new file mode 100644
index 00000000..9104a70c
--- /dev/null
+++ b/tests/f_uninit_inode_past_unused/image.gz
Binary files differ
diff --git a/tests/f_uninit_inode_past_unused/name b/tests/f_uninit_inode_past_unused/name
new file mode 100644
index 00000000..95d07f19
--- /dev/null
+++ b/tests/f_uninit_inode_past_unused/name
@@ -0,0 +1 @@
+inode in use beyond bg_itable_unused
diff --git a/tests/f_uninit_restart_fsck/expect.1 b/tests/f_uninit_restart_fsck/expect.1
new file mode 100644
index 00000000..d396beb3
--- /dev/null
+++ b/tests/f_uninit_restart_fsck/expect.1
@@ -0,0 +1,36 @@
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Entry 'foo2' in /d1 (1881) references inode 500 found in group 0's unused inodes area.
+Fix? yes
+
+Entry 'foo2' in /d1 (1881) has an incorrect filetype (was 1, should be 0).
+Fix? yes
+
+Entry 'bar2' in /d2 (3761) references inode 2100 found in group 1's unused inodes area.
+Fix? yes
+
+Entry 'bar2' in /d2 (3761) has an incorrect filetype (was 1, should be 0).
+Fix? yes
+
+Restarting e2fsck from the beginning...
+One or more block group descriptor checksums are invalid. Fix? yes
+
+Group descriptor 0 checksum is 0xb92b, should be 0x2b5f. FIXED.
+Group descriptor 1 checksum is 0x2f53, should be 0x8d2f. FIXED.
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Entry 'foo2' in /d1 (1881) has deleted/unused inode 500. Clear? yes
+
+Entry 'bar2' in /d2 (3761) has deleted/unused inode 2100. Clear? yes
+
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Unattached zero-length inode 1883. Clear? yes
+
+Unattached zero-length inode 3763. Clear? yes
+
+Pass 5: Checking group summary information
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 21/7520 files (0.0% non-contiguous), 2352/30000 blocks
+Exit status is 1
diff --git a/tests/f_uninit_restart_fsck/expect.2 b/tests/f_uninit_restart_fsck/expect.2
new file mode 100644
index 00000000..156eb07f
--- /dev/null
+++ b/tests/f_uninit_restart_fsck/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: 21/7520 files (0.0% non-contiguous), 2352/30000 blocks
+Exit status is 0
diff --git a/tests/f_uninit_restart_fsck/image.gz b/tests/f_uninit_restart_fsck/image.gz
new file mode 100644
index 00000000..f073186e
--- /dev/null
+++ b/tests/f_uninit_restart_fsck/image.gz
Binary files differ
diff --git a/tests/f_uninit_restart_fsck/name b/tests/f_uninit_restart_fsck/name
new file mode 100644
index 00000000..def2234f
--- /dev/null
+++ b/tests/f_uninit_restart_fsck/name
@@ -0,0 +1 @@
+re-start e2fsck only once for inodes in uninit space
diff --git a/tests/f_uninit_set_inode_not_set/expect.1 b/tests/f_uninit_set_inode_not_set/expect.1
new file mode 100644
index 00000000..4ea3f10a
--- /dev/null
+++ b/tests/f_uninit_set_inode_not_set/expect.1
@@ -0,0 +1,25 @@
+Group descriptor 1 has invalid unused inodes count 1464. Fix? yes
+
+Group descriptor 2 has invalid unused inodes count 1849. Fix? yes
+
+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
+Group 1 block(s) in use but group is marked BLOCK_UNINIT
+Fix? yes
+
+Block bitmap differences: +(9729--14621)
+Fix? yes
+
+Free inodes count wrong for group #1 (0, counted=1464).
+Fix? yes
+
+Free inodes count wrong for group #2 (0, counted=1849).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 794/8192 files (0.3% non-contiguous), 8473/32768 blocks
+Exit status is 1
diff --git a/tests/f_uninit_set_inode_not_set/expect.2 b/tests/f_uninit_set_inode_not_set/expect.2
new file mode 100644
index 00000000..846c5582
--- /dev/null
+++ b/tests/f_uninit_set_inode_not_set/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: 794/8192 files (0.3% non-contiguous), 8473/32768 blocks
+Exit status is 0
diff --git a/tests/f_uninit_set_inode_not_set/image.gz b/tests/f_uninit_set_inode_not_set/image.gz
new file mode 100644
index 00000000..cd38e279
--- /dev/null
+++ b/tests/f_uninit_set_inode_not_set/image.gz
Binary files differ
diff --git a/tests/f_uninit_set_inode_not_set/name b/tests/f_uninit_set_inode_not_set/name
new file mode 100644
index 00000000..42b9c534
--- /dev/null
+++ b/tests/f_uninit_set_inode_not_set/name
@@ -0,0 +1 @@
+block uninit set but inode uninit not set
diff --git a/tests/j_corrupt_journal_block/expect b/tests/j_corrupt_journal_block/expect
index 36a76990..8b6545ae 100644
--- a/tests/j_corrupt_journal_block/expect
+++ b/tests/j_corrupt_journal_block/expect
@@ -1,5 +1,5 @@
test_filesys: recovering journal
-JBD2: Invalid checksum recovering block 1090 in log
+JBD2: Invalid checksum recovering data block 1090 in log
Journal checksum error found in test_filesys
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
diff --git a/tests/m_64bit_flexbg/expect.1 b/tests/m_64bit_flexbg/expect.1
index cfa3bc9b..956d2485 100644
--- a/tests/m_64bit_flexbg/expect.1
+++ b/tests/m_64bit_flexbg/expect.1
@@ -24,6 +24,7 @@ Filesystem OS type: Linux
Inode count: 128
Block count: 1024
Reserved block count: 51
+Overhead clusters: 28
Free blocks: 982
Free inodes: 117
First block: 1
diff --git a/tests/m_bigjournal/expect.1 b/tests/m_bigjournal/expect.1
index 89005966..80f71d1f 100644
--- a/tests/m_bigjournal/expect.1
+++ b/tests/m_bigjournal/expect.1
@@ -18,6 +18,7 @@ Filesystem OS type: Linux
Inode count: 1344
Block count: 2750000
Reserved block count: 137500
+Overhead clusters: 1286982
Free blocks: 1463011
Free inodes: 1333
First block: 0
diff --git a/tests/m_dasd_bs/expect.1 b/tests/m_dasd_bs/expect.1
index 0e55e8f7..970d556d 100644
--- a/tests/m_dasd_bs/expect.1
+++ b/tests/m_dasd_bs/expect.1
@@ -26,6 +26,7 @@ Filesystem OS type: Linux
Inode count: 16384
Block count: 32768
Reserved block count: 1638
+Overhead clusters: 1094
Free blocks: 31664
Free inodes: 16373
First block: 0
diff --git a/tests/m_desc_size_128/expect.1 b/tests/m_desc_size_128/expect.1
index 5a7da87b..1cd9758f 100644
--- a/tests/m_desc_size_128/expect.1
+++ b/tests/m_desc_size_128/expect.1
@@ -26,6 +26,7 @@ Filesystem OS type: Linux
Inode count: 8192
Block count: 131072
Reserved block count: 6553
+Overhead clusters: 4284
Free blocks: 126774
Free inodes: 8181
First block: 1
diff --git a/tests/m_extent_journal/expect.1 b/tests/m_extent_journal/expect.1
index 34e8a80d..cfc052a8 100644
--- a/tests/m_extent_journal/expect.1
+++ b/tests/m_extent_journal/expect.1
@@ -27,6 +27,7 @@ Filesystem OS type: Linux
Inode count: 16384
Block count: 65536
Reserved block count: 3276
+Overhead clusters: 7446
Free blocks: 58076
Free inodes: 16373
First block: 1
diff --git a/tests/m_large_file/expect.1 b/tests/m_large_file/expect.1
index 06c82574..955ba77d 100644
--- a/tests/m_large_file/expect.1
+++ b/tests/m_large_file/expect.1
@@ -24,6 +24,7 @@ Filesystem OS type: Linux
Inode count: 64
Block count: 16384
Reserved block count: 819
+Overhead clusters: 11
Free blocks: 16367
Free inodes: 53
First block: 0
diff --git a/tests/m_meta_bg/expect.1 b/tests/m_meta_bg/expect.1
index 7df4230c..1b90b554 100644
--- a/tests/m_meta_bg/expect.1
+++ b/tests/m_meta_bg/expect.1
@@ -26,6 +26,7 @@ Filesystem OS type: Linux
Inode count: 32768
Block count: 131072
Reserved block count: 6553
+Overhead clusters: 4376
Free blocks: 126683
Free inodes: 32757
First block: 1
diff --git a/tests/m_minrootdir/expect b/tests/m_minrootdir/expect
index 90158da0..d2e9a9e2 100644
--- a/tests/m_minrootdir/expect
+++ b/tests/m_minrootdir/expect
@@ -11,6 +11,7 @@ Filesystem OS type: Linux
Inode count: 1024
Block count: 16384
Reserved block count: 819
+Overhead clusters: 265
Free blocks: 16065
Free inodes: 1006
First block: 1
diff --git a/tests/m_mmp/expect.1 b/tests/m_mmp/expect.1
index 9d8a5a3c..475cd1d0 100644
--- a/tests/m_mmp/expect.1
+++ b/tests/m_mmp/expect.1
@@ -27,6 +27,7 @@ Filesystem OS type: Linux
Inode count: 65536
Block count: 65536
Reserved block count: 3276
+Overhead clusters: 2086
Free blocks: 63443
Free inodes: 65525
First block: 0
diff --git a/tests/m_no_opt/expect.1 b/tests/m_no_opt/expect.1
index 58b311c4..deaf22ef 100644
--- a/tests/m_no_opt/expect.1
+++ b/tests/m_no_opt/expect.1
@@ -26,6 +26,7 @@ Filesystem OS type: Linux
Inode count: 16384
Block count: 65536
Reserved block count: 3276
+Overhead clusters: 2081
Free blocks: 63442
Free inodes: 16373
First block: 1
diff --git a/tests/m_quota/expect.1 b/tests/m_quota/expect.1
index 8cdad301..74e38ca3 100644
--- a/tests/m_quota/expect.1
+++ b/tests/m_quota/expect.1
@@ -26,6 +26,7 @@ Filesystem OS type: Linux
Inode count: 32768
Block count: 131072
Reserved block count: 6553
+Overhead clusters: 9773
Free blocks: 121267
Free inodes: 32756
First block: 1
diff --git a/tests/m_raid_opt/expect.1 b/tests/m_raid_opt/expect.1
index 0fccb7ca..75366312 100644
--- a/tests/m_raid_opt/expect.1
+++ b/tests/m_raid_opt/expect.1
@@ -26,6 +26,7 @@ Filesystem OS type: Linux
Inode count: 32768
Block count: 131072
Reserved block count: 6553
+Overhead clusters: 7224
Free blocks: 123834
Free inodes: 32757
First block: 1
diff --git a/tests/m_resize_inode_meta_bg/expect.1 b/tests/m_resize_inode_meta_bg/expect.1
index d36f9730..6a7f3993 100644
--- a/tests/m_resize_inode_meta_bg/expect.1
+++ b/tests/m_resize_inode_meta_bg/expect.1
@@ -27,6 +27,7 @@ Filesystem OS type: Linux
Inode count: 960
Block count: 3840
Reserved block count: 192
+Overhead clusters: 1122
Free blocks: 2713
Free inodes: 949
First block: 0
diff --git a/tests/m_root_owner/expect.1 b/tests/m_root_owner/expect.1
index 30d119e2..9c978b02 100644
--- a/tests/m_root_owner/expect.1
+++ b/tests/m_root_owner/expect.1
@@ -24,6 +24,7 @@ Filesystem OS type: Linux
Inode count: 128
Block count: 1024
Reserved block count: 51
+Overhead clusters: 24
Free blocks: 986
Free inodes: 117
First block: 1
diff --git a/tests/m_rootdir/expect b/tests/m_rootdir/expect
index 7b5c18d2..113ffc64 100644
--- a/tests/m_rootdir/expect
+++ b/tests/m_rootdir/expect
@@ -10,6 +10,7 @@ Filesystem OS type: Linux
Inode count: 1024
Block count: 16384
Reserved block count: 819
+Overhead clusters: 1543
Free blocks: 14786
Free inodes: 1005
First block: 1
diff --git a/tests/m_std/expect.1 b/tests/m_std/expect.1
index b05031f8..a11cb9bc 100644
--- a/tests/m_std/expect.1
+++ b/tests/m_std/expect.1
@@ -26,6 +26,7 @@ Filesystem OS type: Linux
Inode count: 16384
Block count: 65536
Reserved block count: 3276
+Overhead clusters: 3350
Free blocks: 62172
Free inodes: 16373
First block: 1
diff --git a/tests/m_uninit/expect.1 b/tests/m_uninit/expect.1
index e886dfbf..b60e8cc8 100644
--- a/tests/m_uninit/expect.1
+++ b/tests/m_uninit/expect.1
@@ -26,6 +26,7 @@ Filesystem OS type: Linux
Inode count: 32768
Block count: 131072
Reserved block count: 6553
+Overhead clusters: 5677
Free blocks: 125381
Free inodes: 32757
First block: 1
diff --git a/tests/r_32to64bit/expect b/tests/r_32to64bit/expect
index f5fa56bc..c6816b7f 100644
--- a/tests/r_32to64bit/expect
+++ b/tests/r_32to64bit/expect
@@ -31,7 +31,13 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -15,7 +15,8 @@
+@@ -10,13 +10,13 @@
+ Inode count: 65536
+ Block count: 524288
+ Reserved block count: 26214
+-Overhead clusters: 35228
+ Free blocks: 589
+ Free inodes: 65048
First block: 1
Block size: 1024
Fragment size: 1024
@@ -41,7 +47,7 @@ Change in FS metadata:
Blocks per group: 8192
Fragments per group: 8192
Inodes per group: 1024
-@@ -40,16 +41,16 @@
+@@ -41,16 +41,16 @@
group:block:super:gdt:bbitmap:ibitmap:itable
@@ -64,7 +70,7 @@ Change in FS metadata:
10:81921:-1:-1:270:286:2852
11:90113:-1:-1:271:287:3108
12:98305:-1:-1:272:288:3364
-@@ -65,9 +66,9 @@
+@@ -66,9 +66,9 @@
22:180225:-1:-1:131079:131095:132641
23:188417:-1:-1:131080:131096:132897
24:196609:-1:-1:131081:131097:133153
@@ -76,7 +82,7 @@ Change in FS metadata:
28:229377:-1:-1:131085:131101:134177
29:237569:-1:-1:131086:131102:134433
30:245761:-1:-1:131087:131103:134689
-@@ -89,7 +90,7 @@
+@@ -90,7 +90,7 @@
46:376833:-1:-1:262159:262175:265761
47:385025:-1:-1:262160:262176:266017
48:393217:-1:-1:393217:393233:393249
diff --git a/tests/r_32to64bit_meta/expect b/tests/r_32to64bit_meta/expect
index 0eacd450..c4f39266 100644
--- a/tests/r_32to64bit_meta/expect
+++ b/tests/r_32to64bit_meta/expect
@@ -31,10 +31,11 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -10,11 +10,12 @@
+@@ -10,12 +10,12 @@
Inode count: 65536
Block count: 524288
Reserved block count: 26214
+-Overhead clusters: 32912
-Free blocks: 858
+Free blocks: 852
Free inodes: 65046
@@ -45,7 +46,7 @@ Change in FS metadata:
Blocks per group: 8192
Fragments per group: 8192
Inodes per group: 1024
-@@ -54,9 +55,9 @@
+@@ -55,9 +55,9 @@
12:98305:-1:-1:15:31:3107
13:106497:-1:-1:16:32:3363
14:114689:-1:-1:17:33:3619
@@ -58,7 +59,7 @@ Change in FS metadata:
18:147457:-1:-1:131075:131091:131617
19:155649:-1:-1:131076:131092:131873
20:163841:-1:-1:131077:131093:132129
-@@ -86,9 +87,9 @@
+@@ -87,9 +87,9 @@
44:360449:-1:-1:262158:262174:265250
45:368641:-1:-1:262159:262175:265506
46:376833:-1:-1:262160:262176:265762
diff --git a/tests/r_32to64bit_move_itable/expect b/tests/r_32to64bit_move_itable/expect
index b51663d5..0a3b78e7 100644
--- a/tests/r_32to64bit_move_itable/expect
+++ b/tests/r_32to64bit_move_itable/expect
@@ -31,10 +31,11 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -10,11 +10,12 @@
+@@ -10,12 +10,12 @@
Inode count: 98304
Block count: 786432
Reserved block count: 39321
+-Overhead clusters: 41193
-Free blocks: 764
+Free blocks: 734
Free inodes: 97566
@@ -45,7 +46,7 @@ Change in FS metadata:
Blocks per group: 8192
Fragments per group: 8192
Inodes per group: 1024
-@@ -38,16 +39,16 @@
+@@ -39,16 +39,16 @@
group:block:super:gdt:bbitmap:ibitmap:itable
@@ -68,7 +69,7 @@ Change in FS metadata:
10:81921:-1:-1:81921:81922:81923
11:90113:-1:-1:90113:90114:90115
12:98305:-1:-1:98305:98306:98307
-@@ -63,9 +64,9 @@
+@@ -64,9 +64,9 @@
22:180225:-1:-1:180225:180226:180227
23:188417:-1:-1:188417:188418:188419
24:196609:-1:-1:196609:196610:196611
@@ -80,7 +81,7 @@ Change in FS metadata:
28:229377:-1:-1:229377:229378:229379
29:237569:-1:-1:237569:237570:237571
30:245761:-1:-1:245761:245762:245763
-@@ -87,7 +88,7 @@
+@@ -88,7 +88,7 @@
46:376833:-1:-1:376833:376834:376835
47:385025:-1:-1:385025:385026:385027
48:393217:-1:-1:393217:393218:393219
@@ -89,7 +90,7 @@ Change in FS metadata:
50:409601:-1:-1:409601:409602:409603
51:417793:-1:-1:417793:417794:417795
52:425985:-1:-1:425985:425986:425987
-@@ -119,7 +120,7 @@
+@@ -120,7 +120,7 @@
78:638977:-1:-1:638977:638978:638979
79:647169:-1:-1:647169:647170:647171
80:655361:-1:-1:655361:655362:655363
diff --git a/tests/r_64to32bit/expect b/tests/r_64to32bit/expect
index 13e94a2d..7dff2a05 100644
--- a/tests/r_64to32bit/expect
+++ b/tests/r_64to32bit/expect
@@ -31,10 +31,11 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -10,12 +10,11 @@
+@@ -10,13 +10,11 @@
Inode count: 65536
Block count: 524288
Reserved block count: 26214
+-Overhead clusters: 35246
-Free blocks: 571
+Free blocks: 589
Free inodes: 65048
@@ -45,7 +46,7 @@ Change in FS metadata:
Reserved GDT blocks: 256
Blocks per group: 8192
Fragments per group: 8192
-@@ -41,16 +40,16 @@
+@@ -42,16 +40,16 @@
group:block:super:gdt:bbitmap:ibitmap:itable
@@ -68,7 +69,7 @@ Change in FS metadata:
10:81921:-1:-1:272:288:2854
11:90113:-1:-1:273:289:3110
12:98305:-1:-1:274:290:3366
-@@ -66,9 +65,9 @@
+@@ -67,9 +65,9 @@
22:180225:-1:-1:131079:131095:132641
23:188417:-1:-1:131080:131096:132897
24:196609:-1:-1:131081:131097:133153
@@ -80,7 +81,7 @@ Change in FS metadata:
28:229377:-1:-1:131085:131101:134177
29:237569:-1:-1:131086:131102:134433
30:245761:-1:-1:131087:131103:134689
-@@ -90,7 +89,7 @@
+@@ -91,7 +89,7 @@
46:376833:-1:-1:262159:262175:265761
47:385025:-1:-1:262160:262176:266017
48:393217:-1:-1:393217:393233:393249
diff --git a/tests/r_64to32bit_meta/expect b/tests/r_64to32bit_meta/expect
index d6e2dccc..b17a8784 100644
--- a/tests/r_64to32bit_meta/expect
+++ b/tests/r_64to32bit_meta/expect
@@ -31,10 +31,11 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -10,12 +10,11 @@
+@@ -10,13 +10,11 @@
Inode count: 65536
Block count: 524288
Reserved block count: 26214
+-Overhead clusters: 32918
-Free blocks: 852
+Free blocks: 858
Free inodes: 65046
@@ -45,7 +46,7 @@ Change in FS metadata:
Blocks per group: 8192
Fragments per group: 8192
Inodes per group: 1024
-@@ -55,9 +54,9 @@
+@@ -56,9 +54,9 @@
12:98305:-1:-1:15:31:3107
13:106497:-1:-1:16:32:3363
14:114689:-1:-1:17:33:3619
@@ -58,7 +59,7 @@ Change in FS metadata:
18:147457:-1:-1:131076:131092:131618
19:155649:-1:-1:131077:131093:131874
20:163841:-1:-1:131078:131094:132130
-@@ -87,9 +86,9 @@
+@@ -88,9 +86,9 @@
44:360449:-1:-1:262158:262174:265250
45:368641:-1:-1:262159:262175:265506
46:376833:-1:-1:262160:262176:265762
diff --git a/tests/t_disable_mcsum/expect b/tests/t_disable_mcsum/expect
index e04f26ad..3341ad71 100644
--- a/tests/t_disable_mcsum/expect
+++ b/tests/t_disable_mcsum/expect
@@ -28,7 +28,7 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -33,7 +33,6 @@
+@@ -34,7 +34,6 @@
Journal inode: 8
Default directory hash: half_md4
Journal backup: inode blocks
diff --git a/tests/t_disable_mcsum_noinitbg/expect b/tests/t_disable_mcsum_noinitbg/expect
index a022631d..62eca4e9 100644
--- a/tests/t_disable_mcsum_noinitbg/expect
+++ b/tests/t_disable_mcsum_noinitbg/expect
@@ -28,7 +28,7 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -33,7 +33,6 @@
+@@ -34,7 +34,6 @@
Journal inode: 8
Default directory hash: half_md4
Journal backup: inode blocks
@@ -36,7 +36,7 @@ Change in FS metadata:
Journal features: (none)
Journal size: 16M
Journal length: 16384
-@@ -47,18 +46,18 @@
+@@ -48,18 +47,18 @@
Block bitmap at 262 (+261)
Inode bitmap at 278 (+277)
Inode table at 294-549 (+293)
diff --git a/tests/t_disable_mcsum_yesinitbg/expect b/tests/t_disable_mcsum_yesinitbg/expect
index df3d6c0b..7e3485fe 100644
--- a/tests/t_disable_mcsum_yesinitbg/expect
+++ b/tests/t_disable_mcsum_yesinitbg/expect
@@ -28,7 +28,7 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -33,7 +33,6 @@
+@@ -34,7 +34,6 @@
Journal inode: 8
Default directory hash: half_md4
Journal backup: inode blocks
diff --git a/tests/t_enable_mcsum/expect b/tests/t_enable_mcsum/expect
index c8a2674b..cb0aef62 100644
--- a/tests/t_enable_mcsum/expect
+++ b/tests/t_enable_mcsum/expect
@@ -43,16 +43,16 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -10,7 +10,7 @@
- Inode count: 65536
+@@ -11,7 +11,7 @@
Block count: 524288
Reserved block count: 26214
+ Overhead clusters: 35246
-Free blocks: 571
+Free blocks: 568
Free inodes: 65048
First block: 1
Block size: 1024
-@@ -33,6 +33,7 @@
+@@ -34,6 +34,7 @@
Journal inode: 8
Default directory hash: half_md4
Journal backup: inode blocks
@@ -60,7 +60,7 @@ Change in FS metadata:
Journal features: (none)
Journal size: 16M
Journal length: 16384
-@@ -46,8 +47,8 @@
+@@ -47,8 +48,8 @@
Block bitmap at 262 (+261)
Inode bitmap at 278 (+277)
Inode table at 294-549 (+293)
diff --git a/tests/t_enable_mcsum_ext3/expect b/tests/t_enable_mcsum_ext3/expect
index 0f761a97..11c5a26d 100644
--- a/tests/t_enable_mcsum_ext3/expect
+++ b/tests/t_enable_mcsum_ext3/expect
@@ -31,7 +31,7 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -29,6 +29,7 @@
+@@ -30,6 +30,7 @@
Journal inode: 8
Default directory hash: half_md4
Journal backup: inode blocks
@@ -39,7 +39,7 @@ Change in FS metadata:
Journal features: (none)
Journal size: 16M
Journal length: 16384
-@@ -36,7 +37,7 @@
+@@ -37,7 +38,7 @@
Journal start: 0
@@ -48,7 +48,7 @@ Change in FS metadata:
Primary superblock at 1, Group descriptors at 2-3
Reserved GDT blocks at 4-259
Block bitmap at 260 (+259)
-@@ -45,7 +46,7 @@
+@@ -46,7 +47,7 @@
0 free blocks, 1013 free inodes, 2 directories
Free blocks:
Free inodes: 12-1024
@@ -57,7 +57,7 @@ Change in FS metadata:
Backup superblock at 8193, Group descriptors at 8194-8195
Reserved GDT blocks at 8196-8451
Block bitmap at 8452 (+259)
-@@ -54,6 +55,6 @@
+@@ -55,6 +56,6 @@
0 free blocks, 1024 free inodes, 0 directories
Free blocks:
Free inodes: 1025-2048
diff --git a/tests/t_enable_mcsum_initbg/expect b/tests/t_enable_mcsum_initbg/expect
index e05dd603..a37648bf 100644
--- a/tests/t_enable_mcsum_initbg/expect
+++ b/tests/t_enable_mcsum_initbg/expect
@@ -43,16 +43,16 @@ Change in FS metadata:
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
-@@ -10,7 +10,7 @@
- Inode count: 65536
+@@ -11,7 +11,7 @@
Block count: 524288
Reserved block count: 26214
+ Overhead clusters: 35246
-Free blocks: 571
+Free blocks: 568
Free inodes: 65048
First block: 1
Block size: 1024
-@@ -33,6 +33,7 @@
+@@ -34,6 +34,7 @@
Journal inode: 8
Default directory hash: half_md4
Journal backup: inode blocks
@@ -60,7 +60,7 @@ Change in FS metadata:
Journal features: (none)
Journal size: 16M
Journal length: 16384
-@@ -40,24 +41,24 @@
+@@ -41,24 +42,24 @@
Journal start: 0
diff --git a/tests/t_iexpand_full/expect b/tests/t_iexpand_full/expect
index 3eb17151..354818e2 100644
--- a/tests/t_iexpand_full/expect
+++ b/tests/t_iexpand_full/expect
@@ -20,13 +20,13 @@ tune2fs -I 256 test.img
Setting inode size 256
Exit status is 0
Change in FS metadata:
-@@ -13 +13 @@
+@@ -14 +14 @@
-Free blocks: 12301
+Free blocks: 12
-@@ -22 +22 @@
+@@ -23 +23 @@
-Inode blocks per group: 128
+Inode blocks per group: 256
-@@ -28 +28 @@
+@@ -29 +29 @@
-Inode size: 128
+Inode size: 256
Pass 1: Checking inodes, blocks, and sizes
diff --git a/tests/t_iexpand_mcsum/expect b/tests/t_iexpand_mcsum/expect
index 772bd623..c24a2456 100644
--- a/tests/t_iexpand_mcsum/expect
+++ b/tests/t_iexpand_mcsum/expect
@@ -39,13 +39,13 @@ Change in FS metadata:
@@ -5 +5 @@
-Filesystem features: has_journal ext_attr dir_index filetype extent 64bit sparse_super large_file huge_file uninit_bg dir_nlink extra_isize
+Filesystem features: has_journal ext_attr dir_index filetype extent 64bit sparse_super large_file huge_file dir_nlink extra_isize metadata_csum
-@@ -21 +21 @@
+@@ -22 +22 @@
-Inode blocks per group: 128
+Inode blocks per group: 256
-@@ -27 +27 @@
+@@ -28 +28 @@
-Inode size: 128
+Inode size: 256
-@@ -30,0 +31 @@
+@@ -31,0 +32 @@
+Checksum type: crc32c
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure