总的block数量:262144
$ dumpe2fs /dev/vg01/test | grep "Block count"
dumpe2fs 1.42.9 (28-Dec-2013)
Block count: 262144
减去数据块数: 249830,剩下:12314
$ df -B 4k /mnt
Filesystem 4K-blocks Used Available Use% Mounted on
/dev/mapper/vg01-test 249830 641 231986 1% /mnt
总的Inode数量 * 每个Inode大小,计算得到block数:4096,相减剩下:8218
$ dumpe2fs /dev/vg01/test | grep "Inode count"
dumpe2fs 1.42.9 (28-Dec-2013)
Inode count: 65536
$ dumpe2fs /dev/vg01/test | grep "Inode size"
dumpe2fs 1.42.9 (28-Dec-2013)
Inode size: 256
8个块组,每个块组两个位图,使用block数:16,相减剩下:8202
$ dumpe2fs /dev/vg01/test | grep "Group" | grep Blocks
dumpe2fs 1.42.9 (28-Dec-2013)
Group 0: (Blocks 0-32767) [ITABLE_ZEROED]
Group 1: (Blocks 32768-65535) [INODE_UNINIT, ITABLE_ZEROED]
Group 2: (Blocks 65536-98303) [INODE_UNINIT, BLOCK_UNINIT, ITABLE_ZEROED]
Group 3: (Blocks 98304-131071) [INODE_UNINIT, ITABLE_ZEROED]
Group 4: (Blocks 131072-163839) [INODE_UNINIT, ITABLE_ZEROED]
Group 5: (Blocks 163840-196607) [INODE_UNINIT, ITABLE_ZEROED]
Group 6: (Blocks 196608-229375) [INODE_UNINIT, BLOCK_UNINIT, ITABLE_ZEROED]
Group 7: (Blocks 229376-262143) [INODE_UNINIT, ITABLE_ZEROED]
5个superblock(包括4个backup)+ 5个 Group descriptors:10,相减剩下:8192
$ dumpe2fs /dev/vg01/test | grep "superblock"
dumpe2fs 1.42.9 (28-Dec-2013)
Primary superblock at 0, Group descriptors at 1-1
Backup superblock at 32768, Group descriptors at 32769-32769
Backup superblock at 98304, Group descriptors at 98305-98305
Backup superblock at 163840, Group descriptors at 163841-163841
Backup superblock at 229376, Group descriptors at 229377-229377
ext4的日志系统使用block数:8192,计算完毕。
$ dumpe2fs /dev/vg01/test | grep Journal
dumpe2fs 1.42.9 (28-Dec-2013)
Journal inode: 8
Journal backup: inode blocks
Journal features: journal_64bit
Journal size: 32M
Journal length: 8192
Journal sequence: 0x00000002
Journal start: 1
标签:ext4,Group,为例,UNINIT,ZEROED,1G,ITABLE,Blocks,dumpe2fs
From: https://www.cnblogs.com/dewan/p/16829524.html