Linked by Rahul on Sat 18th Oct 2008 11:29 UTC
Thread beginning with comment 334181
To view parent comment, click here.
To read all comments associated with this story, please click here.
To view parent comment, click here.
To read all comments associated with this story, please click here.
You can't break the laws of physics though. If you are going to defragment then you have to have enough free space to move all your files around...
Anyone remember the DOS defrag util that moved around individual clusters? And it displayed a nice big map of the disk showing which sectors it was currenly moving. Free space requirements: one free cluster
RE[3]: Defragmentation
by Earl Colby pottinger on Sat 18th Oct 2008 20:55
in reply to "RE[2]: Defragmentation"
Yes, I remember it well, and this thread has got me stumped because of that. While a it is a *VERY SLOW* way to fragment a drive, it will do it as long as there is more than two(2) sectors free.
While newer fragmentation software is faster because they more entire file around, a followup using a sector by sector defrag would insure that the filesystem can reach 100%.







Member since:
2005-07-06
No too sure what you mean, as ext3 had no official defragmentation tool (I'm assuming you're comparing ext4 to something). It kept fragmentation to a minimum by allocating blocks that were closest to a file, but inevitably, this compromised other things and you still got fragmentation over time. This was alright in fairly static partitions such as /, /usr etc. but killed partitions with lots of file activity over time. ext4 has online defragmentation and also support for extents, which filesystems like XFS have provided for some time.
You can't break the laws of physics though. If you are going to defragment then you have to have enough free space to move all your files around, and if you don't then parts of your filesystem will simply stay fragmented with all the performance issues that entails.
However, defragmentation is merely a necessary evil with today's storage technology and you can only do so much. If SSDs kick on over the next few years and we get the same random read and write access no matter where in a storage device a file block is allocated, then fragmentation issues will start to disappear. There are actually many ways you can defragment and order data with today's mechanical disks with respect to performance. It really depends on the type of data and usage, and that's what is so difficult. Any person who tells you that a modern filesystem can solve all that is well wide of the mark.