fsarchiver may help to reduce fragmentation on ext3 ?

Please ask questions here if you are not familiar with fsarchiver
Post Reply
bobbysch
Posts: 26
Joined: Mon Jun 15, 2009 8:46 pm

fsarchiver may help to reduce fragmentation on ext3 ?

Post by bobbysch » Wed Feb 24, 2010 10:35 am

Hello,

I'd know fsarchiver may help to reduce fragmentation of ext3 or other FS in Linux, like tar can do ?

Thanks.

admin
Site Admin
Posts: 550
Joined: Sat Feb 21, 2004 12:12 pm

Re: fsarchiver may help to reduce fragmentation on ext3 ?

Post by admin » Wed Feb 24, 2010 2:45 pm

Yes, we can expect a filesystem which has been restored recently to have less fragmentation. But the real solution will be the online defragmentation which is planned for ext4. I don't think it's alreadly available in 2.6.32.
Also it has been observed that ntfs filesystem just restored with fsarchiver are very fragmented for some reason. I don't really think there is something to do about that.

psusi
Posts: 4
Joined: Mon Mar 22, 2010 6:57 pm

Re: fsarchiver may help to reduce fragmentation on ext3 ?

Post by psusi » Mon Mar 22, 2010 8:13 pm

This is one of the things that I really liked about Norton Ghost, and dislike about partimage. I hope fsarchiver can behave more like Ghost. Since partimage puts all of the disk blocks back exactly as they were, any fragmentation present in the disk before is preserved, but Ghost unpacked the files from the archive storing the on the disk filling it from the first block up in order, thus packing all of the restored files at the start of the disk with no fragmentation.

It sounds like fsarchiver uses an external library to format a filesystem on a raw block device and write files to it. How does the library allocate blocks? Does it try to allocate them all over the place like the kernel does, or does it try to pack them like Ghost? What library is used for ext2/3/4 and where can I find some good documentation on it?

Also how is the backup done? Does it walk the directory tree backing up files it finds, or does it copy out the used inodes, then their data blocks, the way dump does? Dump seems very fast backing up because it works this way, but its corresponding restore utility works more like an archive extractor; it wants to write out normal files to a mounted filesystem rather than unpack the dump file into a new filesystem on a raw disk.

Also why does it have to have a seekable output?

admin
Site Admin
Posts: 550
Joined: Sat Feb 21, 2004 12:12 pm

Re: fsarchiver may help to reduce fragmentation on ext3 ?

Post by admin » Sun Apr 11, 2010 8:03 am

fsarchiver uses the standard fstools (e2fsprogs, xfsprogs, ...) and runs mkfs to create the filesystem. Then the filesystem is mounted and files are just written normally. You can think it's just a sort of tar.gz that runs mkfs for you, but there are a lot of other improvements that make a big difference (checksumming, multi-threaded compression, preserve filesystem properties, ...)

Post Reply