e2fsprogs/SOURCES/e2fsprogs-1.44.4-tests-e2fs...

121 lines
3.6 KiB
Diff

From 0c1b709edb72f100965045627f17365dbeeedb9e Mon Sep 17 00:00:00 2001
From: Lukas Czerner <lczerner@redhat.com>
Date: Mon, 13 Aug 2018 15:17:05 +0200
Subject: [PATCH] tests: e2fsck must be able fix fs with resize_inode and
meta_bg
Test if the e2fsck can fix file system with resize_inode and meta_bg
features enabled simultaneously.
Signed-off-by: Lukas Czerner <lczerner@redhat.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
---
tests/f_resize_inode_meta_bg/expect.1 | 71 +++++++++++++++++++++++++++
tests/f_resize_inode_meta_bg/expect.2 | 7 +++
tests/f_resize_inode_meta_bg/name | 1 +
3 files changed, 79 insertions(+)
create mode 100644 tests/f_resize_inode_meta_bg/expect.1
create mode 100644 tests/f_resize_inode_meta_bg/expect.2
create mode 100644 tests/f_resize_inode_meta_bg/name
diff --git a/tests/f_resize_inode_meta_bg/expect.1 b/tests/f_resize_inode_meta_bg/expect.1
new file mode 100644
index 00000000..12055fc7
--- /dev/null
+++ b/tests/f_resize_inode_meta_bg/expect.1
@@ -0,0 +1,71 @@
+Resize_inode and meta_bg features are enabled. Those features are
+not compatible. Resize inode should be disabled. Fix? yes
+
+Resize_inode not enabled, but the resize inode is non-zero. Clear? yes
+
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Directory inode 2, block #0, offset 0: directory has no checksum.
+Fix? yes
+
+First entry '' (inode=348) in directory inode 2 (???) should be '.'
+Fix? yes
+
+Setting filetype for entry '.' in ??? (2) to 2.
+Missing '..' in directory inode 2.
+Fix? yes
+
+Setting filetype for entry '..' in ??? (2) to 2.
+Directory inode 2, block #0, offset 860: directory corrupted
+Salvage? yes
+
+Directory inode 11, block #0, offset 0: directory corrupted
+Salvage? yes
+
+Missing '.' in directory inode 11.
+Fix? yes
+
+Setting filetype for entry '.' in ??? (11) to 2.
+Missing '..' in directory inode 11.
+Fix? yes
+
+Setting filetype for entry '..' in ??? (11) to 2.
+Directory inode 11, block #1, offset 0: directory corrupted
+Salvage? yes
+
+Directory inode 11, block #2, offset 0: directory corrupted
+Salvage? yes
+
+Entry '' in ??? (11) has a zero-length name.
+Clear? yes
+
+Directory inode 11, block #3, offset 864: directory corrupted
+Salvage? yes
+
+Pass 3: Checking directory connectivity
+'..' in / (2) is <The NULL inode> (0), should be / (2).
+Fix? yes
+
+Unconnected directory inode 11 (/???)
+Connect to /lost+found? yes
+
+/lost+found not found. Create? yes
+
+Pass 3A: Optimizing directories
+Pass 4: Checking reference counts
+Inode 11 ref count is 3, should be 2. Fix? yes
+
+Pass 5: Checking group summary information
+Block bitmap differences: -246
+Fix? yes
+
+Free blocks count wrong for group #0 (160, counted=161).
+Fix? yes
+
+Free blocks count wrong (2714, counted=2715).
+Fix? yes
+
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 12/960 files (0.0% non-contiguous), 1125/3840 blocks
+Exit status is 1
diff --git a/tests/f_resize_inode_meta_bg/expect.2 b/tests/f_resize_inode_meta_bg/expect.2
new file mode 100644
index 00000000..0df9a40a
--- /dev/null
+++ b/tests/f_resize_inode_meta_bg/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/960 files (0.0% non-contiguous), 1125/3840 blocks
+Exit status is 0
diff --git a/tests/f_resize_inode_meta_bg/name b/tests/f_resize_inode_meta_bg/name
new file mode 100644
index 00000000..94936549
--- /dev/null
+++ b/tests/f_resize_inode_meta_bg/name
@@ -0,0 +1 @@
+conflicting features resize_inode and meta_bg
--
2.17.2