[TriLUG] Copying Files from a Dying HDD...with a twist

Mauricio Tavares via TriLUG trilug at trilug.org
Tue Jul 3 10:17:09 EDT 2018


      I take you first copied the disk into an ISO using ddrescue.
With that said, see if photorec
(https://www.cgsecurity.org/wiki/PhotoRec) has an option to do what
you want; I am not that good with it.

On Tue, Jul 3, 2018 at 10:01 AM, Brian via TriLUG <trilug at trilug.org> wrote:
> Hi Gang,
>
> I know there're several choices available to me when it comes to copying
> bunches of files from one place to another (under Linux, if that didn't go
> without saying.. :-) ).  I have a bit of a twist I want to put on it.
>
> The source drive was dropped while it was running, and although it still
> functions, there are now collections of errors in certain areas (my guess
> being correlating to where the heads were when the drive was dropped).
>
> What I'd like to do is something that will mirror a directory structure, but
> if a read error is encountered in any given file, that file winds up in a
> different location.  In other words, I want to replicate the directory
> structure in two places; one that gets filled up with error-free files, the
> other that gets filled up with error-containing files.  That way I'll have
> an easy, organized way of seeing what files and directories were actually
> lost/corrupted.  e.g.
>
> /good_files/<original_directory_structure>
> /bad_files/<original_directory_structure>
>
> So the question is, is there a command that'll already do this? Something
> like rsync, with an option to give a different target path for files when
> errors occur.  I could always script something, but I feel like file-by-file
> invocations of cp would be much less efficient than some command that would
> handle it internally.
>
> Thanks!
> -Brian
> --
> This message was sent to: raubvogel at gmail.com <raubvogel at gmail.com>
> To unsubscribe, send a blank message to trilug-leave at trilug.org from that
> address.
> TriLUG mailing list : https://www.trilug.org/mailman/listinfo/trilug
> Unsubscribe or edit options on the web  :
> https://www.trilug.org/mailman/options/trilug/raubvogel%40gmail.com
> Welcome to TriLUG: https://trilug.org/welcome


More information about the TriLUG mailing list