📜 ⬆️ ⬇️

New fast resize interface EXT4 file system

Yesterday a request to add changes to the Linux 3.3 kernel from Theodore Ts'o was published. Among the many bug fixes and other changes in the current de facto standard Linux file system, EXT4, a new interface for resizing file systems on the fly has appeared, which was first publicly introduced several months ago. New interface for EXT4 developed by Yongqiang Yang.

What does the author himself write on this topic? “This is a new resize on the fly interface for ext4. It can be used by ioctl with EXT4_IOC_RESIZE_FS and a 64-bit number that stores the size of the file system in a block. "

The implementation of Yongqiang differs in that the resizing of the EXT4 on the fly now occurs in the kernel. The tests presented by Yongqiang show that resizing the file system with the new code is much faster: resizing from 20GB to 230GB used to take more than five minutes, but now he has shown that this can be done in just 3.35 seconds. Resizing from 100GB to 230GB takes less than half a second. Detailed tests can be viewed in the mailing list .

In addition to the fact that resizing the file system has become much faster, other useful features have been added in the new code, such as bigalloc and simple exclusion of the bitmap (exclude bitmap easily).
')
The new implementation added about 1000 lines of code to the kernel file system module. Pull request in 3.3 kernel, which includes the implementation described above plus other changes in EXT4, can be found in Theodore Ts'o .

This improvement in EXT4 is just one of many improvements in kernel 3.3, which was only started on, and which will be officially released in about two months.

Source: https://habr.com/ru/post/136026/


All Articles