bug-ddrescue
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-ddrescue] Improving ddrescue


From: Joe Kickman
Subject: Re: [Bug-ddrescue] Improving ddrescue
Date: Sun, 27 Nov 2016 00:47:56 +0300

Hello, Santiago Cassina.
Once I experienced similar behavior, I used only 1 fully automated script:

...slow areas are being read at no more than 100 kb/s, sometimes even taking 
some seconds to read 1 physical sector (avg.rate ~1 kb/s).
I used --exit-on-slow with (now useless since v.1.22-pre4 modified line 151 of 
ddrescue.h 1.22-pre3 (having changed 30 s to 1 s)). There is a new option in 
the latest version of ddrescue, --delay-slow
 * Version 1.22-pre4 released.
 * Added new option '--delay-slow'.
 * Option '-K, --skip-size' now accepts sizes up to 1 EiB.
 * '--ask', '-vv' now show size along with model and serial number.

I used also -O -T0 -X -a4194304 - but nothing helps enough. Sometimes ddrescue 
worked for 2 minutes at speed about 4...16 kb/s without stopping by any reason. 
I interrupted it manually.

I finally wrote a script to cycle the skipping, here it follows:

#!/bin/bash
# script for cycling the run of GNU ddrescue on disk with slow areas
# for (( i=1276000; $i<=2720000; i=$i+1280 )); do #1280Mi best suits the skip 
size
#areas before 1276000Mi and after 2720000Mi have been successfully read already.

#1297760 - using the last position, for example if  the script was stopped 
manually
     for (( i=1297760; i<=2720000; i+=500  )) ; do
     ia=$i'Mi'
     echo -i$ia
              ./ddrescue /dev/sdb /dev/sda ~/log.txt --cpass=1 -O -X -R -T0 
-a4194304 -K120Mi -i$ia -s500Mi --exit-on-slow
done

You can easily modify the script for your needs - it exits on most error cases, 
then restarts the rescue from a new position; you can just restart after 
exiting.
Also, try using direct mode as it was recommended.

Besides, with the newest versions you probably wouldn't need any script at all. 
Just try
ddrescue source destination mapfile_name.log -a9Mi -O --delay-slow=1 
--cpass=1,2 --idirect

reply via email to

[Prev in Thread] Current Thread [Next in Thread]