PDA

View Full Version : Defragger: What do you think....



Perfect Storm
April 8th, 2005, 07:45 AM
http://www.oo-software.com/en/products/oodlinux/index.html

Though I know linux doesn't use defrag, so why build a defragger for linux?

TjaBBe
April 8th, 2005, 07:57 AM
http://www.oo-software.com/en/products/oodlinux/index.html

Though I know linux doesn't use defrag, so why build a defragger for linux?
As far as I know Linux filesystems don't even NEED to be defragged. Obviously this is someone with too much spare time ;).

bigzak
April 8th, 2005, 08:30 AM
Looks like a commercial (paid) product. I guess they'll be relying on the fact that defragmentation of drives is ingrained into the public consience that people will buy it because "disks need to be defragmented to speed them up".

It's basically cashing in on MS's failings :(

Ubunted
April 8th, 2005, 08:41 AM
Kinda reminds me of all the "RAM Defrag" placebo programs out there. Useless, but you can bet someone's going to sink their dough into it.

seven
April 8th, 2005, 09:06 AM
Defrag is not needed at all for linux AFAIK, just bored people with free time :roll:

bigzak
April 8th, 2005, 12:51 PM
Kinda reminds me of all the "RAM Defrag" placebo programs out there. Useless, but you can bet someone's going to sink their dough into it.

Yes. A mate of mine actually paid good money for a 'RAM doubler' that was supposed to compress RAM on the fly, drivespace style. I'm not sure if it was a total fraud (which was raised as a possiblity) but the machine benchmarked significantly slower than without it, and available RAM was, well, almost exactly the same as before.

Of course, he swore blind that it made a VAST improvement, far more than just spending the same amount on actual RAM would have provided.

Perfect Storm
April 8th, 2005, 03:52 PM
I think I'm gonna E-mail them and hear what they have to say.... I really like to know their reason why linux users should invest money in it, though the beta version is free.

Sam
April 8th, 2005, 04:57 PM
I've heard somewhere that an almost-full disc could start being fragged.

HungSquirrel
April 8th, 2005, 05:56 PM
I've never understood why Linux partitions don't need to be defragged. How exactly does it work?

TravisNewman
April 8th, 2005, 06:50 PM
I'd love to know that myself! I know the filesystem is a lot more robust and everything, but you'd THINK there'd be some fragmentation.

mike998
April 8th, 2005, 06:57 PM
I'm not 100% sure and could be completely wrong, but I belive it's something to do with the fact that the filesystem is a journalled filesystem, and information is written to disk to a type of scratchpad area, sorted and then written to disk "permanently".

Having said that, old non-journalled ext3 filesystems didnt need to be defragged either.

Hmmm... I wonder if there is a utility to see my file allocation? I have some really big files on my HDD at home...

HungSquirrel
April 8th, 2005, 07:14 PM
Ext3 is journaled.

NTFS is journaled IIRC and it needs monthly defragging.

Glanz
April 8th, 2005, 07:14 PM
I'm not 100% sure and could be completely wrong, but I belive it's something to do with the fact that the filesystem is a journalled filesystem, and information is written to disk to a type of scratchpad area, sorted and then written to disk "permanently".

Having said that, old non-journalled ext3 filesystems didnt need to be defragged either.

Hmmm... I wonder if there is a utility to see my file allocation? I have some really big files on my HDD at home...
In general, the allocation policy for JFS tries to maximize contiguous allocation by allocating a minimum number of extents, with each extent as large and contiguous as possible. This allows for large I/O transfer, resulting in improved performance. However, in special cases this is not always possible. For example, copy-on-write clones of a segment will cause a contiguous extent to be partitioned into a sequence of smaller contiguous extents. Another case is restriction of extent size. For example, the extent size is restricted for compressed files since JFS must read the entire extent into memory and decompress it. JFS has a limited amount of memory available, so it must ensure that it will have enough room for the decompressed extent.

A defragmentation utility is provided to reduce external fragmentation, which occurs from dynamic allocation/deallocation of variable-size extents. This allocation and deallocation can result in disconnected variable size free extents all over the aggregate. The defragmentation utility will coalesce multiple small free extents into single larger extents.

jdong
April 8th, 2005, 10:06 PM
It's been 2 weeks or so since I've defragged my 200GB XFS partition:



jdong@delta:~$ time sudo xfs_fsr
xfs_fsr -m /etc/mtab -t 7200 -f /var/tmp/.fsrlast_xfs ...
/ start inode=0
/ start inode=0
/ start inode=0
/ start inode=0
/ start inode=0
/ start inode=0
/ start inode=0
/ start inode=0
/ start inode=0
/ start inode=0
Completed all 10 passes

real 0m18.332s
user 0m0.503s
sys 0m1.788s
jdong@delta:~$



WOW, that took a whopping 18 seconds to defrag.... (BTW, XFS also resists fragmentation)

az
April 8th, 2005, 10:41 PM
Right, EXT2 is not journaled and resists fragmentation as well as Ext3. The journaling in Ext3 is just a reconrd-keeping practice added on top. You can mount your ext3 filesystem as ext2, if you want. Fragmentation is minimized on these filesystems, but not non-existant.

It does not lead to lock-ups or instability like it does on Windows systems.

So, as far as I know, it is present to a lesser degree, and is a lot less of a problem for ext2 and ext3 filesystems.

The everyday linux user does not have to worry about it.

jdong
April 8th, 2005, 10:43 PM
If you fill your disk to the 95%+ mark, performance will degrade rapidly, and fragmentation will also get out of control like in Windows.

It's generally NOT a good idea to fill hard disks to the brim, anyway.

mike998
April 9th, 2005, 02:21 AM
I stand corrected.
As to the above about drives becoming more than 95% filled...

[root@ariadne root]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/hda3 18G 15G 2.4G 86% /
/dev/hda1 99M 14M 79M 15% /boot
none 89M 0 89M 0% /dev/shm
I guess I gotta worry about my poor server....

jdong
April 9th, 2005, 02:25 AM
I'd recommend separating the user data from the system files. It's OK if /home gets a bit fragged up. When /var and /usr get fragged, you'll suffer a huge performance hit.

DJ_Max
April 9th, 2005, 02:41 AM
To pretty much reiterate what azz said, disk fragmentation is a common problem with the DOS FAT file system(s). Reason being a number of issues, mainly how it handles files, and uses the registery.

Most Unix(including OS X) won't have a problem. For the rare ocasions, do something similar to what jdong did.

jerome bettis
April 9th, 2005, 06:54 AM
well i was going to explain this whole internal / external fragmentation thing. but i'm getting a little too drunk and it's getting a little too complicated. i'll post that sometime tommorow.

for now i'll leave you with a quote from the book that explains all of this stuff:

"In an experiment to see if Windows NT file usage was appreciably different from UNIX file usage, [some smart guy] made measurements on files at Cornell University. He observed that NT file usage is more complicated than on UNIX. He wrote:


When we type a few characters in the notepad text editor, saving this to a file will trigger 26 system calls, including three failed open attempts, 1 file overwrite, and 4 additional open and close sequences."

LOL

Ubunted
April 9th, 2005, 07:42 AM
The innards of MS at their best I suppose. Amazing.

jdong
April 11th, 2005, 02:46 AM
WOW, that's gonna be my new sig.

poofyhairguy
April 11th, 2005, 02:57 AM
If you fill your disk to the 95%+ mark, performance will degrade rapidly, and fragmentation will also get out of control like in Windows.




Oooops. time to buy a new hard disk...

bigzak
April 11th, 2005, 08:47 AM
I'd love to know that myself! I know the filesystem is a lot more robust and everything, but you'd THINK there'd be some fragmentation.

The output of fsck will tell you how fragmented, or 'non-contiguous', the file system is. When I obliterated my Slackware ext3 filesystem of 2 years+ to put Ubuntu on, the last fsck said it was 1.01% non-contigous. A FAT partition gets more fragmented that than in 2 days!

jdong
April 11th, 2005, 04:03 PM
As I've said before, the only case where ext3/XFS get fragmented is when you fill the disk up to the brim.