Author: h2appy
Indicate the source for reprinting.
I. Do I need disk fragmentation in Linux?
First of all, the file system we will discuss below will produce disk fragments. The difference lies in the number of fragments produced by different policies. For example, ext3 uses reserved space to reduce fragments, and XFS uses delayed writing to reduce fragments.
Do I need to fragment? If fragments affect normal use and cannot be tolerated, they should be sorted out.
Ii. ext2 File System
Offline fragment toolsE2defrag.
Iii. ext3 File System
Ext3 does not have a defragmentation tool. As mentioned in [1], the reserved space is used by ext3, so it can better solve the fragmentation problem. Because of the reserved space, of course it will waste some space. My two 1 TB hard disks, with ext3 available space of 961.4 GB; XFS available space of 976.6 GB. In addition, if you copy the same file to the two hard disks, the occupied space ext3 will be larger because it requires reserved space.
It is not a good way to convert ext3 to ext2 and then perform fragment.
User space fragment tools: Shake and defrag.
Iv. ext4 File System
The disk fragment tool will be provided. For details, refer to [5].
V. XFS File System
Xfs_fsr: participate in "disk fragmentation in Linux (1 )".
Vi. reiferfs File System
Reiser3 does not have a defragmentation tool, and reiser4 will provide a repacker. Reiser4 is currently under development stagnation. In the future... who knows?
VII. JFS File System
Defgrafs of IBM.
Improving...
Refer:
[1] http://geekblog.oneandoneis2.org/index.php/2006/08/17/why_doesn_t_linux_need_defragmenting
[2] http://en.wikipedia.org/wiki/Defragmentation
[3] http://en.wikipedia.org/wiki/Reiserfs
[4] http://en.wikipedia.org/wiki/Xfs
[5] http://en.wikipedia.org/wiki/Ext4
[6] http://en.wikipedia.org/wiki/Ext3
[7] http://blog.csdn.net/zhangjianying/archive/2007/05/04/1596401.aspx