public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: Jack <ostroffjh@users.sourceforge.net>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] data recovery advice needed
Date: Mon, 17 Dec 2018 14:32:14 -0500	[thread overview]
Message-ID: <KFMBYXLF.3UHKMZMB.RDWOC4VF@MUUTOSOU.SXRN5UN5.DBVRFK2R> (raw)
In-Reply-To: <CAGfcS_=RSLMoKvUqXFyfzZ4+5kYJ+sE16rQ0O-bx0zNUDHeuCg@mail.gmail.com> (from rich0@gentoo.org on Sat Dec 15 19:19:32 2018)

Thanks to both Rich and Grant for suggestions.  Part of my issue is  
that I currently have two different failing/failed HDDs to deal with,  
and one of them has two different problems.  At this point, although  
there are files I would really love to recover from each of them, it's  
not critical, so I'm taking my time.  I'll post more details or at  
least status upste later, depending on how things work out.

On 2018.12.15 19:19, Rich Freeman wrote:
> On Sat, Dec 15, 2018 at 6:33 PM Jack  
> <ostroffjh@users.sourceforge.net> wrote:
> >
>> So, I removed that HDD for safekeeping (completely reinstalled the  
>> laptop on a new drive) and now I'm trying to recover data from an  
>> intact partition on the old drive, the problem being that the drive  
>> is giving some read errors, so I want to minimize access, lest it  
>> die completely.
> 
> Ok, step 1 - make a copy of the drive before you go messing with it.  
> I suggest using ddrescue for this.  Basically it works like dd  
> (creates an image of the drive), but it is persistent in the face of  
> read errors.
ddrescue has now been running for almost 22 hours, and it's been 47  
seconds less than that since its last successful read.   The odd thing  
(to me, although it probably should not be) is that the first issue  
with this drive was my own stupidity for trying to move a partition in  
a way I should have known would not work.  (Simplified if inaccurate  
description is a 300GB drive with 100GB free and then a 200GB  
partition, which I tried to move to the beginning of the drive.)  That  
garbled the partition, but the drive itself still worked fine.  Since  
then, the drive itself has started giving lots of read errors, thus the  
slow progress of ddrescue.)  The other drive failed over a shorter  
period of time, even though SMART testing said all was OK.  One of the  
failures led to fsck "fixing"lots of stuff, but truncating or otherwise  
effectively destroying lots of files.  It's a SATA drive, now connected  
to a laptop (only place I have enough recovery space on a good drive)  
by a SAS to USB adaptor.
> 
> Once you have a copy of the drive you can now start experimenting.  
> Obviously keep that copy safe and if you want to write to it create  
> another copy.
understood and agreed.
> 
> As far as fixing dates goes - the touch suggestion might work but  
> honestly unless you're in a super hurry I'd just do another copy.
once the ddrescue works, any approach will work.  However, neither is  
likely to be very helpful with the number of read failures I'm getting.
> 
> If you've lost any kind of drive metadata such that files are missing  
> completely there are utilities that can scan disk blocks looking for  
> things like text files, or jpegs.  That is going to be a massive  
> headache but if you've lost something indispensible it is an option.
I did one run of testdisk on one partition on the drive months ago.   
One problem is that the extension on the recovered files is not  
necessarily the original extension (even if the file is actually  
recoverable) and there seem to be some file types is doesn't (or didn't  
then) know about.  I may well try it again after much more reading on  
tuning its behavior.
> 
> Ultimately your goal is going to be to get the files you care about  
> off the drive.  Then you can just copy/rsync them to a completely  
> fresh filesystem - I wouldn't go trying to copy the old filesystem  
> using dd if it has been subject to read errors or especially partial  
> overwrites of metadata.  You want the metadata to be clean.
right.
> 
> And then once you have your data back on a disk give some thought to  
> your backup strategy.  If you care about data enough to be going  
> through trouble to rescue it, you should probably have a backup of  
> it. When I was messing around with btrfs and the filesystem ate my  
> data I wasn't messing around with hex editors - I just wiped the  
> filesystem and rsynced from a backup.  Sure, it takes time, but you  
> know the filesystem is completely clean when you're done.
Someone (on this list?) had a signature "There are two kinds of people:  
those who do backups and those who have never had a hard drive fail."   
I guess there's actually a third.....
> 
> --
> Rich
Jack

  reply	other threads:[~2018-12-17 19:32 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-15 23:33 [gentoo-user] data recovery advice needed Jack
2018-12-16  0:06 ` Grant Taylor
2018-12-16  0:19 ` Rich Freeman
2018-12-17 19:32   ` Jack [this message]
2018-12-17 19:42     ` Rich Freeman
2018-12-17 20:53       ` Grant Taylor
2018-12-17 20:45     ` Grant Taylor
2018-12-18 12:21     ` Wols Lists
2018-12-18 14:20       ` Dale
2018-12-18 15:56       ` Grant Taylor
2018-12-18 21:28         ` Marc Joliet
2018-12-19 11:51           ` Mick
2018-12-18 17:43       ` Jack
2018-12-17 22:32 ` Heiko Baums
2018-12-17 23:19   ` Jack
2018-12-18  9:43     ` Peter Humphrey
2018-12-18 17:11       ` Jack
2018-12-18 17:42         ` Mick
2018-12-18 17:49           ` Jack
2018-12-18 18:33             ` Mick
2018-12-18 18:58             ` Grant Taylor
2018-12-18 18:51           ` Grant Taylor
2018-12-19 11:43             ` Mick
2018-12-19 18:46               ` Grant Taylor
2018-12-19 22:16                 ` Mick
2018-12-19 23:02                   ` Grant Taylor

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=KFMBYXLF.3UHKMZMB.RDWOC4VF@MUUTOSOU.SXRN5UN5.DBVRFK2R \
    --to=ostroffjh@users.sourceforge.net \
    --cc=gentoo-user@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox