Dd

dd is used to copy raw data from source to sink, where source and sink can be a block device, file or piped input/output.

Installation
As part of the GNU, it should be already installed with any Gentoo GNU/Linux system.

Usage
The program takes input from, optional manipulates the data and writes to per default.

Examples
Some common tasks where dd is used:

Boot-Stick
This should work with any live media as long as the memory stick is large enough.


 * - defines the source
 * - defines the sink
 * - block size - defines the amount of data read/written at a time, default is 512 bytes but most modern devices can read/write much faster. It is possible to define different sizes for source and sink using  and.

Backup MBR
To backup the MBR partition table, dd can be told to only copy the first 512 bytes:


 * - is the number of blocks to copy

Manipulate input
As an example, convert any upper case character in a file to lowercase and reverse the input per line, then pipe the default stdout to to display the file:


 * - this will revert the input per line by swapping any input byte (writing backwards)
 * - convert any upper case letter to lower case, the opposite is
 * - continue if a read error occurs

External resources

 * man pages for dd