Bug#1130122: [Pkg-utopia-maintainers] Bug#1130122: libblockdev: autopkgtest regression with e2fsprogs 1.47.4-1

2026-03-09 Thread Michael Biebl

Control: forwarded -1 
https://github.com/storaged-project/libblockdev/issues/1179

Hi Ted,

thanks for your reply.

I've forwarded this issue upstream.


OpenPGP_signature.asc
Description: OpenPGP digital signature


Bug#1130122: libblockdev: autopkgtest regression with e2fsprogs 1.47.4-1

2026-03-08 Thread Theodore Tso
On Mon, Mar 09, 2026 at 12:00:49AM +0200, Adrian Bunk wrote:
> Source: libblockdev
> Version: 3.4.0-1
> 
> My gut feeling is that the comment
>   "at least 90 % should be available, so it should be reported"
> in the libblockdev tests makes an assumption that might sometimes
> be marginally incorrect, but I do not know why the new e2fsprogs
> version makes a difference here.

The new e2fsprogs version uses a different way calculating the size of
the orphan inode.  Older versions of mke2fs has a orphan inode with 33
blocks.  (num_blocks / 4096 == 138240 / 4096 == 33).  But in the newer
version of mke2fs, we're now using an orphan inode with 135 blocks
(num_blocks / fs->blocksize == 138240 / 1024 == 135).  The intent of
the commit 6f03c698ef53 ("libext2fs: fix orphan file size > kernel
limit with large blocksize") was to fix issues when the blocksize is
64k.  We assumed that nothing would change when the block size was 4k
--- but what we didn't consider what might happen when the block size
is 1k.

Having an orphan inode which is sized to 135k isn't really insane, but
it's just enough to push overhead over 10%.  On the other hand, is it
likely that we need to scale a file system with 138240k (135
megabytes) scale to the point that over 128 CPU's simultaneously
trying to delete or truncate inodes?  Probably not.  Scaling to 32
CPU's is probably plenty.

Obviously, the user can override the orphan inode size; but given that
most users won't, the defaults are important.  I'll have to take a
closer look at that, but I would request that libblockdev be a bit
more relaxed in its tests.


But there also seems to be something else weird going on with the ext2
and ext3 file systems:

> 2577s ==
> 2577s FAIL: test_ext2_get_info 
> (fs_tests.ext_test.ExtGetInfo.test_ext2_get_info)
> 2577s Verify that it is possible to get info about an ext2 file system
> 2577s --
> ...
> 2577s AssertionError: 138133 not greater than 138240.0
> 2577s 
> 2577s ==
> 2577s FAIL: test_ext3_get_info 
> (fs_tests.ext_test.ExtGetInfo.test_ext3_get_info)
> 2577s Verify that it is possible to get info about an ext3 file system
> 2577s --
> ...
> 2577s AssertionError: 138133 not greater than 138240.0

So this makes no sense.  There should be more free blocks for ext2
over ext3, since ext2 doesn't have a journal.

> 2577s ==
> 2577s FAIL: test_ext4_get_info 
> (fs_tests.ext_test.ExtGetInfo.test_ext4_get_info)
> 2577s Verify that it is possible to get info about an ext4 file system
> 2577s --
> ...
> 2577s AssertionError: 138133 not greater than 138240.0

And there should be more free blocks for ext3 when compared to ext4,
because ext4 has the orphan inode, when ext3 doesn't.

So I *think* there is something going on which is weird with how the
Blockdev is setting up the fs_ext[234]_mkfs.  It appears that for all
of these tests, it's creating an ext4 file system, which I don't think
is what the test is trying to get at.

- Ted



Bug#1130122: libblockdev: autopkgtest regression with e2fsprogs 1.47.4-1

2026-03-08 Thread Adrian Bunk
Source: libblockdev
Version: 3.4.0-1
Severity: serious
X-Debbugs-Cc: Theodore Y. Ts'o , [email protected]

https://ci.debian.net/packages/libb/libblockdev/testing/amd64/69358068/

...
2577s ==
2577s FAIL: test_ext2_get_info (fs_tests.ext_test.ExtGetInfo.test_ext2_get_info)
2577s Verify that it is possible to get info about an ext2 file system
2577s --
2577s Traceback (most recent call last):
2577s   File 
"/tmp/autopkgtest.T0NkLu/build.d48/src/tests/fs_tests/ext_test.py", line 267, 
in test_ext2_get_info
2577s self._test_ext_get_info(mkfs_function=BlockDev.fs_ext2_mkfs,
2577s ~~~^
2577s info_function=BlockDev.fs_ext2_get_info)
2577s 
2577s   File 
"/tmp/autopkgtest.T0NkLu/build.d48/src/tests/fs_tests/ext_test.py", line 247, 
in _test_ext_get_info
2577s self.assertGreater(fi.free_blocks, 0.90 * self.loop_size / 1024)
2577s ~~^^
2577s AssertionError: 138133 not greater than 138240.0
2577s 
2577s ==
2577s FAIL: test_ext3_get_info (fs_tests.ext_test.ExtGetInfo.test_ext3_get_info)
2577s Verify that it is possible to get info about an ext3 file system
2577s --
2577s Traceback (most recent call last):
2577s   File 
"/tmp/autopkgtest.T0NkLu/build.d48/src/tests/fs_tests/ext_test.py", line 273, 
in test_ext3_get_info
2577s self._test_ext_get_info(mkfs_function=BlockDev.fs_ext3_mkfs,
2577s ~~~^
2577s info_function=BlockDev.fs_ext3_get_info)
2577s 
2577s   File 
"/tmp/autopkgtest.T0NkLu/build.d48/src/tests/fs_tests/ext_test.py", line 247, 
in _test_ext_get_info
2577s self.assertGreater(fi.free_blocks, 0.90 * self.loop_size / 1024)
2577s ~~^^
2577s AssertionError: 138133 not greater than 138240.0
2577s 
2577s ==
2577s FAIL: test_ext4_get_info (fs_tests.ext_test.ExtGetInfo.test_ext4_get_info)
2577s Verify that it is possible to get info about an ext4 file system
2577s --
2577s Traceback (most recent call last):
2577s   File 
"/tmp/autopkgtest.T0NkLu/build.d48/src/tests/fs_tests/ext_test.py", line 279, 
in test_ext4_get_info
2577s self._test_ext_get_info(mkfs_function=BlockDev.fs_ext4_mkfs,
2577s ~~~^
2577s info_function=BlockDev.fs_ext4_get_info)
2577s 
2577s   File 
"/tmp/autopkgtest.T0NkLu/build.d48/src/tests/fs_tests/ext_test.py", line 247, 
in _test_ext_get_info
2577s self.assertGreater(fi.free_blocks, 0.90 * self.loop_size / 1024)
2577s ~~^^
2577s AssertionError: 138133 not greater than 138240.0
2577s 
2577s ==
2577s FAIL: test_ext4_resize (fs_tests.ext_test.ExtResize.test_ext4_resize)
2577s Verify that it is possible to resize an ext4 file system
2577s --
2577s Traceback (most recent call last):
2577s   File 
"/tmp/autopkgtest.T0NkLu/build.d48/src/tests/fs_tests/ext_test.py", line 408, 
in test_ext4_resize
2577s self._test_ext_resize(mkfs_function=BlockDev.fs_ext4_mkfs,
2577s ~^
2577s   info_function=BlockDev.fs_ext4_get_info,
2577s   
2577s   resize_function=BlockDev.fs_ext4_resize,
2577s   
2577s   minsize_function=BlockDev.fs_ext4_get_min_size)
2577s   ^^^
2577s   File 
"/tmp/autopkgtest.T0NkLu/build.d48/src/tests/fs_tests/ext_test.py", line 348, 
in _test_ext_resize
2577s self.assertGreater(fi.free_blocks, 0.90 * self.loop_size / 1024)
2577s ~~^^
2577s AssertionError: 138133 not greater than 138240.0
2577s 
2577s --
2577s Ran 512 tests in 2409.241s
2577s 
2577s FAILED (failures=4, skipped=18)
2577s autopkgtest [21:46:34]: test upstre