lkml.org 
[lkml]   [1996]   [Nov]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: IS there a tool to un-stupid a deleted file ?
From

James W. Laferriere <babydr@filesrv1.baby-dragons.com> wrote:

> Subject: IS there a tool to un-stupid a deleted file ?

> Actually It's I who need un-stupidifying.
>
> My other tars are a few weeks old now & many BIG changes
> in between...
>
> I tar'd off my /home tree to a disk drive & while attempting
> to tar it back forgot to replace the 'c' with 'x' in the
> tar statement, thus low & behold NO more /home filesystem.
>
> IE: tar --same-owner -cPpf /mnt/home-filesystem.tar /home

Oh man, did you do a booboo. I've done something similar before in
the past - never again:)

> mnt has been umount'd since the incedent, & not re-mount'd
> since.

Smart move.

> Is there anywhere that I can find a tool to peice it back
> together again ? I Know, I Know, Humpty Dumpty.....

It's tricky. There is debugfs (that somes with thee2fsprogs package)
that will allow you list deleted inodes and copy them elsewhere. But
the user interface to that is really ugly and attempting to restore
lots of files is a real pain. And, unless you really know what you
are doing, it's difficult to recover more than around the first 12k of
the files.

Midnight commander has an undelete/file recover feature. Go grab the
lastest production version from:

ftp://ftp.nuclecu.unam.mx/linux/local/

and ./configure it with the --with-ext2undel option.

You'll need to have the e2fsprogs package libraries installed on your
system. Read the docs on how to use it to access an unmounted
filesystem's undeleted files.

You'll still get a bunch of inode numbers, but at least it's a simple
matter of using a very nice point'n'click to view and save off copies
of the files onto other partitions under real filenames. It may still
only give you access to the first 12k of each file... but I think the
logic to follow the inode pointers should have been added in the more
recent versions of mc.

Good luck. You'll need it :)

Cheers
Tony

\
 
 \ /
  Last update: 2005-03-22 13:37    [W:0.028 / U:2.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site