public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
* How to damage a XFS-Filesystem?
@ 2008-01-02 13:16 Carsten Aulbert
  2008-01-02 17:48 ` Chris Wedgwood
  0 siblings, 1 reply; 2+ messages in thread
From: Carsten Aulbert @ 2008-01-02 13:16 UTC (permalink / raw)
  To: xfs

Hi,

I have the following scenario:

A file server with a 10 TB large xfs file system running on a RAID6 SATA
array, the server has 16 GB of memory. I want to test how long it would
take to run xfs_repair on it and if the amount of memory is enough for that.

Thus I think I would need to:

(1) Fill the disk with files
(2) Damage the file sytem
(3) Run xfs_repair

My questions:

(1) Is there a nice tool which fills up a disk? I.e. I want to write
files with varying size and want to be able to check the validity
(md5,sha1...) of the files before and after the damage. I don't know if
it matters, but the number of entries per directory should also vary
greatly ;)

(2) I don't know if xfs_repair cares if the file system was damaged or
not. If it uses the same amount of time and memory on a fully intact
file system, I guess I don't have a question anymore. Otherwise: How can
a damage a xfs file system to make the job harder for xfs_repair. I
guess a simple dd if=/dev/random of=/dev/sdb1 with some offsets will not
be very effective, right?

(3) Anything else I need to be aware of?

Thanks for your patience (and yes, I have tried the archives for answers)

Cheers

Carsten

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: How to damage a XFS-Filesystem?
  2008-01-02 13:16 How to damage a XFS-Filesystem? Carsten Aulbert
@ 2008-01-02 17:48 ` Chris Wedgwood
  0 siblings, 0 replies; 2+ messages in thread
From: Chris Wedgwood @ 2008-01-02 17:48 UTC (permalink / raw)
  To: Carsten Aulbert; +Cc: xfs

On Wed, Jan 02, 2008 at 02:16:27PM +0100, Carsten Aulbert wrote:

> A file server with a 10 TB large xfs file system running on a RAID6
> SATA array, the server has 16 GB of memory. I want to test how long
> it would take to run xfs_repair on it and if the amount of memory is
> enough for that.

It depends on how fast the IO is and also how many files there are.

If you have a small number of really large files it's fairly fast, if
you have a large number of really small files (ie. email maildir) then
it tends to be much slower.

> (2) Damage the file sytem
> (3) Run xfs_repair

xfs_repair will run without having to damage the filesystem (though
if/when damaged it will probably be a little slower).

> Otherwise: How can a damage a xfs file system to make the job harder
> for xfs_repair.

Google for fsfuzzer.

> I guess a simple dd if=/dev/random of=/dev/sdb1 with some offsets
> will not be very effective, right?

If it misses the metadata, xfs_repair won't even notice.  If you whack
large chunks of metadata you might see considerable data loss.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-01-02 17:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-01-02 13:16 How to damage a XFS-Filesystem? Carsten Aulbert
2008-01-02 17:48 ` Chris Wedgwood

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox