Dixi quod…

>= /dev/dm-8
>dumpe2fs 1.46.2 (28-Feb-2021)
>Inode count:              65536
>Inodes per group:         8192
>Inode blocks per group:   256
>Inode size:               128

Let’s look at the superblock, first here, for orienting.

00000430  fe 6b 25 67 02 00 ff ff  53 ef 01 00 01 00 00 00  |.k%g....S.......|
00000440  89 6b 25 67 00 00 00 00  00 00 00 00 01 00 00 00  |.k%g............|
00000450  00 00 00 00 0b 00 00 00  80 00 00 00 3c 00 00 00  |............<...|

438h has, for orientation, e2fs_magic. Going forward…
458h has u_int16_t e2fs_inode_size. 0080h = 128, fits.

>= /dev/dm-5
>dumpe2fs 1.46.2 (28-Feb-2021)
>Inode count:              262144
>Inodes per group:         8192
>Inode blocks per group:   256

00000430  ea 62 25 67 02 00 ff ff  53 ef 00 00 01 00 00 00  |.b%g....S.......|
00000440  80 4e 25 67 00 00 00 00  00 00 00 00 00 00 00 00  |.N%g............|
00000450  00 00 00 00 0b 00 00 00  80 00 00 00 00 00 00 00  |................|

Huh, 0080h as well. (Maybe I did explicitly use -I 256 when
creating the root filesystem, after all?)

But why is it not reported? I’d have half expected 0000h…

In addition, if I umount and remount it, the kernel does not
complain about the too-small inode size being a Y2038 problem,
unlike for dm-8… what is happening here?

Let’s look at a 256-sized one…

>= /dev/dm-2
>dumpe2fs 1.46.2 (28-Feb-2021)
>Inode count:              327680
>Inodes per group:         8192
>Inode blocks per group:   512
>Inode size:               256

00000430  e4 62 25 67 01 00 ff ff  53 ef 01 00 01 00 00 00  |.b%g....S.......|
00000440  e3 62 25 67 00 00 00 00  00 00 00 00 01 00 00 00  |.b%g............|
00000450  00 00 00 00 0b 00 00 00  00 01 00 00 3c 00 00 00  |............<...|

0100h, as expected. So I have reasonable ground to assume that
/dev/dm-5 indeed has 128-byte inodes… except:

[defaults]
        inode_size = 256
[fs_types]
        ext4 = {
                features = 
has_journal,extent,huge_file,flex_bg,metadata_csum,64bit,dir_nlink,extra_isize
                inode_size = 256
        }

What am I missing? Did I found another bug in mke2fs in that it
creates filesystems sometimes with smaller inode sizes after all
and/or a bug in the kernel that it does not report for some fs
with 128-byte inodes?

Confused,
//mirabilos
-- 
> Hi, does anyone sell openbsd stickers by themselves and not packaged
> with other products?
No, the only way I've seen them sold is for $40 with a free OpenBSD CD.
        -- Haroon Khalid and Steve Shockley in gmane.os.openbsd.misc

Reply via email to