xfs
[Top] [All Lists]

Undelete Functions

To: linux-xfs@xxxxxxxxxxx
Subject: Undelete Functions
From: David Lloyd <lloy0076@xxxxxxxxxxxx>
Date: Mon, 25 Jun 2001 19:07:04 +0930
Sender: owner-linux-xfs@xxxxxxxxxxx
Hmmmm...

It strikes me that it would be easier to implement an undelete function
using a journalling filesystem than not. I theorise that if you logged
what you'd deleted, then a [relatively speaking] simple reverse run of
the relevant log entries _might_ get you your file back.

Pseudo Code would be:

1) extract from the log where foo file actually was
2) forcibly lock all those blocks/cylinders or whatever
3) put it back together
4) write foo_file somewhere else

Naturally because of the nature of the cached writing system and such
it's not a guaranteed thing, but it would be better than having to
wander around the file system following inodes etc manually...

DSL
-- 
"And the winner is
   InUnifiedCanadianAboriginalSyllabics"
- Larry Wall et al in Programming Perl

<Prev in Thread] Current Thread [Next in Thread>