First you'll need to install some packages.
On your ubuntu/debian/suse whatever if you use the apt-get utility, say this.
# apt-get install xfsdump
Under Gentoo, this
# emerge xfsprogs xfsdump
Then you'll need to check if your partition needs a defragmentation in really
# xfs_db -r /dev/sda5
xfs_db> frag
actual 22222222, ideal 2342342, fragmentation factor 99.9%
xfs_db> quit
Once you see a scary fragmentation factor, run the command for the optimization
# xfs_fsr -v /dev/sda5
.......
That's it, now you may go have a drink, lift something heavy, play the guitar or pay an attention to your girlfriend. This whill take some time.
7 comments:
Thanks! Fast and simple, as I needed:)
Ok, you don't type emerge install on gentoo.
# emerge xfsprogs xfsdump
is the right command for installing the packages needed.
Good point, thanks
I would point out that on Gentoo systems, you need to emerge xfsprogs just to run.
Also what would you call scary? My Movies partition is at 49.52% that seems high to me.
gus3's comment on
this story has me somewhat nervous about using xfs_fsr. Has anyone tried this recently? I've got a severely fragmented 1TB drive on my media center box and it's giving a very noticeable impact hit. I foolishly don't have backups of everything at the moment since I lack the storage and am too lazy to burn a few hundred gigs of data to DVD's, hence the timidness.
Hey Mike,
I used it in June to defrag my 750G storage, everything went without problems. Maybe that guy had some mechanical problems with his hdd or used some unstable build.
But anyway. You should use the situation as an excuse to buy a new bigger HDD ;)
Many thanks for the quick reply. This is very good to know. Nice blog, by the way.
Post a Comment