dd: use ddrescue to backup broken device instead of dd

This commit is contained in:
Mikaela Suomalainen 2012-12-10 17:48:52 +02:00
parent db8151753a
commit d54dbaf62e
2 changed files with 23 additions and 8 deletions

View File

@ -12,20 +12,25 @@ dd cheatsheet
<a href="../../sitemap/sitemap.html">Sitemap</a> <a href="../../sitemap/sitemap.html">Sitemap</a>
<hr/> <hr/>
<h1 id="figuring-out-what-is-the-usb-stick">Figuring out what is the USB stick</h1> <h1 id="introductiom">Introductiom</h1>
<p>Programs used / Debian packages</p>
<p>isohybrid dd ddrescue / syslinux coreutils gddrescue</p>
<p>Finding out what is the USB drive in /dev/sd*</p>
<p>Start by mounting the stick which should be automatic in GUI.</p> <p>Start by mounting the stick which should be automatic in GUI.</p>
<pre><code>mount|grep /dev/sd</code></pre> <pre><code>mount|grep /dev/sd</code></pre>
<p>should tell what is the /dev/USBSTICK</p> <p>should tell what is the /dev/USBSTICK</p>
<h2 id="creating-bootable-usb-stick">Creating bootable USB stick</h2> <h2 id="creating-bootable-usb-stick">Creating bootable USB stick</h2>
<pre><code>isohybrid image.iso <pre><code>isohybrid image.iso
dd if=image of=/dev/USBSTICK bs=1024</code></pre> dd if=image of=/dev/USBSTICK bs=1024;</code></pre>
<h2 id="creating-.iso-from-cddvd">Creating .iso from CD/DVD</h2> <h2 id="creating-.iso-from-cddvd">Creating .iso from CD/DVD</h2>
<p>First unmount the CD/DVD and then</p> <p>First unmount the CD/DVD and then</p>
<pre><code>dd if=/dev/DRIVE of=image.iso</code></pre> <pre><code>dd if=/dev/DRIVE of=image.iso</code></pre>
<p>DRIVE can be /dev/dvd /dev/cdrom or /dev/scd0 depending on the CD/DVD.</p> <p>DRIVE can be /dev/dvd /dev/cdrom or /dev/scd0 depending on the CD/DVD.</p>
<h2 id="backing-up-scratched-cddvd">Backing up scratched CD/DVD</h2> <h2 id="backing-up-scratched-cddvd">Backing up scratched CD/DVD</h2>
<pre><code>dd if=/dev/DRIVE (see above) of=IMAGE.iso conv=noerror</code></pre> <pre><code>ddrescue /dev/device /where/to/create/the/file.iso /path/to/logfile.log</code></pre>
<p>maybe ddrescue should be used instead of dd.</p> <p>The logfile.log is used to keep track of what has been recovered. You can use same logfile for multiple clones.</p>
<p>Usage: You have two broken copies of same device. First you clone the other and then give same command to other, different source, but same destination and log file. If the device isn't broken on same part as the another, ddrescue will build a complete file.</p>
<p>I would also use ddrescue with backing up large devicces instead of dd.</p>
<!-- vim : set ft=html --> <!-- vim : set ft=html -->
<hr/> <hr/>

View File

@ -15,7 +15,13 @@
[Sitemap](../../sitemap/sitemap.html) [Sitemap](../../sitemap/sitemap.html)
<hr/> <hr/>
# Figuring out what is the USB stick # Introductiom
Programs used / Debian packages
isohybrid dd ddrescue / syslinux coreutils gddrescue
Finding out what is the USB drive in /dev/sd*
Start by mounting the stick which should be automatic in GUI. Start by mounting the stick which should be automatic in GUI.
@ -29,7 +35,7 @@ should tell what is the /dev/USBSTICK
``` ```
isohybrid image.iso isohybrid image.iso
dd if=image of=/dev/USBSTICK bs=1024 dd if=image of=/dev/USBSTICK bs=1024;
``` ```
## Creating .iso from CD/DVD ## Creating .iso from CD/DVD
@ -45,10 +51,14 @@ DRIVE can be /dev/dvd /dev/cdrom or /dev/scd0 depending on the CD/DVD.
## Backing up scratched CD/DVD ## Backing up scratched CD/DVD
``` ```
dd if=/dev/DRIVE (see above) of=IMAGE.iso conv=noerror ddrescue /dev/device /where/to/create/the/file.iso /path/to/logfile.log
``` ```
maybe ddrescue should be used instead of dd. The logfile.log is used to keep track of what has been recovered. You can use same logfile for multiple clones.
Usage: You have two broken copies of same device. First you clone the other and then give same command to other, different source, but same destination and log file. If the device isn't broken on same part as the another, ddrescue will build a complete file.
I would also use ddrescue with backing up large devicces instead of dd.
<!-- vim : set ft=html --> <!-- vim : set ft=html -->
<hr/> <hr/>