xfs
[Top] [All Lists]

Defragging XFS File Systems

To: xfs@xxxxxxxxxxx
Subject: Defragging XFS File Systems
From: Kenneth Emerson <kenneth.emerson@xxxxxxxxx>
Date: Mon, 6 Jun 2011 22:52:48 -0500
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=hrjVfAudA1TPw8MxB5TIYXOxatafiJHwT5Pe2/tkqEA=; b=p5E3UxfAYuphEy3oz2ucrxWa3a9ctv9vWr3r7dmmZMQ/xrzFu7SSnDzF+cgVNHZeIf 0HeKyDfpdbHZncUWieL8+gi8PSiz4goHX3MPkkFB24xS2j83NbA5m1FIRk8j4dOXRn+v Js/Ml9LdE4tiuYO92TG92Ym7YcFecZt1uX+ew=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=JSmwS3s29cSf8MLDjfTC4sR3xYfuMvinVyTxsvuLh1mG9+0A7HQJX+lMsmTQ4wT7lM M4ujjSLcc2GZbQH9yPRLJ8qoVAdAq5Hh4Y8kTJZjF+T/kVbghudbFEwi98TmEMbIrKLQ ePcDKqrwclA4SeK9ZZkLcUhUbmaI9GERPI3Xw=
I hadn't given much thought to fragmentation of my TV recordings volume (XFS) until reading through some MythTV-users threads recently that mentioned how fragmented an XFS file system could become.  After running xfs_db, I found out that my fs appeared to be quite bad:

$ sudo xfs_db -c frag -r /dev/mapper/appl_vg-appl_lv
 actual 1138668, ideal 11023, fragmentation factor 99.03%

I then ran xfs_fsr with all defaults (ran for two hours) and then re-ran xfs_db and got the following results:

$ sudo xfs_db -c frag -r /dev/mapper/appl_vg-appl_lv
invalid numrecs (27111) in bmapbtd block
invalid numrecs (4716) in bmapbtd block
invalid numrecs (58978) in bmapbtd block
actual 1034793, ideal 11024, fragmentation factor 98.93%

The fragmentation level was reduced, but I was concerned about the error messages.  Before I go any further, am I corrupting my file system with the defragging or are these "invalid numrecs" messages unimportant?

Google didn't offer much help.

Regards,

Ken E.
<Prev in Thread] Current Thread [Next in Thread>