-
Notifications
You must be signed in to change notification settings - Fork 1
Remote
This is not ready today,but it hopefully is a pointer in the right direction.
Sadly I have not yet found a way to support
ddrescue
. However there is a way to pull the image and then useddrescue-verify
to verify the result.Note that I will improve this as soon as I need it.
This is not a complete solution yet. Best would be to integrate some generic remote dev
access driver into ddrescue
and ddrescue-verify
, such that you can provide your own remote driver for ssh
and others.
Here is the situation:
- You have a local machine with plenty of storage.
- You have a remote machine which is somewhat broken.
- The link to the remote is not exactly stable, so there may be interruptions any time
- The filesystem on the remote is so broken, that it no more mounts, so using
rsync
and similar does not work - You want to take an image of the remote drives, before you try to repair.
Here is how it works:
- Boot the remote machine into some rescue system which offers
root
ssh
access - That's enough to pull the image
Pull the image using sshcopydev
, see https://github.com/hilbix/sshcopydev
Create a dummy ddrescue compatible logfile (sorry, this step is missing)
Following is untested, but it should work:
Instead, with
Linux
, you can create dummy device using the
IMAGE=image dmsetup.sh DEVNAME
script of
sshcopydev
to create a clone of the remote drive, which also will keep the unreadable parts unreadableNow you can use
ddrescue
to create anddrescue
compatible log like withddrescue /dev/mapper/DEVNAME /dev/null image.ddrescue.log
(And yes, outch, this hurts, to write all data to
/dev/null
)
Use ddrescue-verify
to verify the image on the remote.
You probably need a statically compiled ddrescue-verify
version to run it on the remote.
Note that, at the time of writing,
sshcopydev
provides it's own verification hint in the fileTODO.md
Pull the differences, somehow
Well, no, sorry, I have no easy to follow recipe for this yet
I have nothing to do with ddrescue
. I am only the author of ddrescue-verify
.