On Tue, 2007-07-31 at 18:24 +0100, Laurie Brown wrote:
WHAT??!!!!!!!!!
Sorry, massive disagreement from here... NTFS fragments dreadfully, take a look after a defrag, then say, install MS Office, then take another look.
Warning..long answer ahead
NTFS does still suffer from fragmentation problems, not as badly as FAT as the filesystem logic is a bit cleverer about block allocation. Part of the illusion of NTFS coping better is that modern disks cope better..but there is an improvement over FAT for sure
ext2/3 also suffer (it is the non contiguous value you get when you run fsck) however the problem is far less rampant and usually only happens on really old (and heavily modified when full) partitions. There are no stable tools I know of to fix fragmentation on ext2/3 and given how small the problem is there are unlikely to ever be any. ext suffers a lot less than FAT as it pre-allocates blocks beyond a given file length to allow for future growth. This however does not deal with the fragmentation problems you get on a nearly full filesystem which is why for optimum performance it is good to run ext2/3 with some free space.
If you do get into a problem with fragmentation (which is highly unlikely as generally the non contiguous value stays below say 5%) then the only completely safe fix I am aware of is to copy the data off and reformat.
Even in the cases of heavy fragmentation on Linux the performance impact is almost negligible compared to the days of MSDOS due to the way that modern kernels access information on a drive. MSDOS and old versions of Windows assumed single user, single process, single file, disk access. and so only retrieved what it needed from the disk. Linux on the other hand retrieves pretty much whatever passes under the drive head and it can hold in cache (using spare memory) whether it thinks it needs it or not..given that most file fragmentation happens over a small block of clusters there is a very reasonable chance that the rest of the fragmented file is already in cache as the heads made their way to what was requested.
Most if not all of this is also done in NTFS and modern NT kernels, so although NTFS does become fragmented (and generally more so than Linux filesystems) the actual performance benefit of correcting it is not as obvious as in the days of FAT