Whamcloud - gitweb
LU-16750 mke2fs: add "-E iops" to set IOPS storage group
authorBobi Jam <bobijam@whamcloud.com>
Wed, 19 Jul 2023 10:07:05 +0000 (18:07 +0800)
committerLi Dongyang <dongyangli@ddn.com>
Tue, 28 May 2024 05:53:20 +0000 (15:53 +1000)
commitb29702b5a696765cdfcc57ffcf7c69e5fa07fc53
tree1703327779f444c432388baae475a3554c87817f
parent22dd0392953aa669d93c5fab5884410f21ecd813
LU-16750 mke2fs: add "-E iops" to set IOPS storage group

With LVM it is possible to create an LV with SSD storage at the
beginning of the LV and HDD storage at the end of the LV, and use that
to separate ext4 metadata allocations (that need small random IOs)
from data allocations (that are better suited for large sequential
IOs) depending on the type of underlying storage.  Between 0.5-1.0% of
the filesystem capacity would need to be high-IOPS storage in order to
hold all of the internal metadata.

This would improve performance for inode and other metadata access,
such as ls, find, e2fsck, and in general improve file access latency,
modification, truncate, unlink, transaction commit, etc.

For mke2fs, using the sparse_super2 and packed_meta_blocks options
places all of the static metadata (group descriptors, block/inode
bitmaps, inode tables, journal) at the start of the device in the
(IOPS) flash region.

Add an option to mark which blocks are in the IOPS region of storage
at format time:

  -E iops=0-1024G,4096-8192G

so the ext4 mballoc code can then use the EXT4_BG_IOPS flag in the
group descriptors to decide which groups to allocate dynamic
filesystem metadata.

Change-Id: I13cc2820c71737848eab8a2d6e246748258a64df
Signed-off-by: Bobi Jam <bobijam@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/c/tools/e2fsprogs/+/51735
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
debugfs/debugfs.c
lib/e2p/ls.c
lib/ext2fs/ext2_fs.h
misc/dumpe2fs.c
misc/mke2fs.8.in
misc/mke2fs.c