Professional Documents
Culture Documents
Now Open! Enter your photos, video and audio in the annual celebration of Africa!
Help
From Wikipedia, the free encyclopedia
The main article for this category is Inferno (operating system).
names are sometimes used for GNU's ddrescue , including addrescue (the name on freecode.com and
freshmeat.net), gddrescue (Debian package name), and gnu_ddrescue (openSUSE package name).
Another open-source program called savehd7 uses a sophisticated algorithm, but it also requires the
installation of its own programming-language interpreter.
Benchmarking drive performance[edit]
To make drive benchmark test and analyze the sequential (and usually single-threaded) system read and
write performance for 1024-byte blocks:
Write performance: dd if=/dev/zero bs=1024 count=1000000 of=1GB_file_to_write
Read performance: dd if=1GB_file_to_read of=/dev/null bs=1024
Generating a file with random data[edit]
To make a file of 100 random bytes using the kernel random driver:
Progress indicator[edit]
Being a program mainly designed as a filter, dd normally does not provide any progress indication. This can
be overcome by sending an USR1 signal to the running GNU dd process (INFO on BSD systems), resulting
in dd printing the current number of transferred blocks.
The following one-liner results in continuous output of progress every 10 seconds until the transfer is
finished, when dd-pid is replaced by the process-id of dd:
Newer versions of GNU dd support the status=progress option, which enables periodic printing of
transfer statistics to stderr.[24]
Forks[edit]
dcfldd [edit]
dcfldd is a fork of GNU dd that is an enhanced version developed by Nick Harbour, who at the time was
working for the United States' Department of Defense Computer Forensics Lab.[25][26][27] Compared
to dd, dcfldd allows more than one output file, supports simultaneous multiple checksum calculations,
provides a verification mode for file matching, and can display the percentage progress of an operation. As
of February 2024, the last release was 1.9.1 from April 2023.[28]
dc3dd[edit]
dc3dd is another fork of GNU dd from the United States Department of Defense Cyber Crime Center (DC3).
It can be seen as a continuation of the dcfldd, with a stated aim of updating whenever the GNU upstream is
updated. As of June 2023, the last release was 7.3.1 from April 2023.[29]
See also[edit]
Backup
Disk cloning
Disk Copy
Disk image
.img (filename extension)
List of Unix commands
ddrescue a GNU version that copies data from corrupted files
References[edit]
1. ^ Austin Group. "POSIX standard: dd invocation". Archived from the original on 2010-03-10. Retrieved 2016-
09-29.
2. ^ Chessman, Sam. "How and when to use the dd command?". CodeCoffee. Archived from the original on 14
Feb 2008. Retrieved 2008-02-19.
dd if=system.img of=/dev/sdc bs=64M Restores a hard disk drive (or an SD card, for
conv=noerror example) from a previously created image.
The noerror option means to keep going if there is an error, while the sync option causes output blocks to
be padded.
In-place modification[edit]
dd can modify data in place. For example, this overwrites the first 512 bytes of a file with null bytes:
The notrunc conversion option means do not truncate the output file — that is, if the output file already
exists, just replace the specified bytes and leave the rest of the output file alone. Without this
option, dd would create an output file 512 bytes long.
Master boot record backup and restore[edit]
The example above can also be used to back up and restore any region of a device to a file, such as
a master boot record.
To duplicate the first two sectors of a floppy disk:
Disk wipe[edit]
Main article: Data erasure
For security reasons, it is sometimes neces
ows EOF).