currupted files filling with zeros after power failure

Pascal GREGIS
2006-07-24T16:04:01Z

Hello everyone,

I'm working on power failures on some test machines in my company.
I volunteerly switch off my machine by pressing the power button and restart my machine to see how it behaves.

The problem I'm facing is that about once for two crashes the last file (or at least the last file) i which I wrote becomes corrupted and filled with \0 characters.

I didn't think XFS could be subject to this type of problem, however here isn't really the reason of my mail.

What I would like to know is what can I do to resolve this problem? Is XFS able to recover my file with its right content, at least a consistent content, not only \0 characters?
I made some tries with xfs_repair and it didn't repair it, once it put me some inodes in lost+found but id didn't repair my corrupted file.
Maybe xfs_db could help, I don't know.

I'm running a 2.6.11.11 kernel iwth xfsprogs-2.7.3 and xfsdump-2.2.30.
Maybe is a bug in that kernel.

Do you guys know if this problem has often been encountered or not,a dn if there is a way to proceed?

Thank you

Pascal