Forrest logo
tool overview
On this page you find all important commands for the CLI tool dd. If the command you are looking for is missing please ask our AI.

dd

The dd command line tool is a utility that is commonly used in Unix-like operating systems. It stands for "data duplicator" or "disk destroyer" and is primarily used for low-level data operations.

Here are some key features and uses of the dd tool:

  1. Disk Imaging: dd can create an exact clone, or image, of a disk or partition. This can be useful for backing up or restoring data, as well as for migrating systems to new hardware.

  2. Data Transfer: dd can be used to transfer data from one location to another, either within the same machine or across a network. This can be useful for copying files, folders, or entire disks.

  3. Disk Wiping: dd can securely erase data from a disk by overwriting it with random or zero bytes. This can be important for ensuring sensitive data is properly destroyed before disposing of a disk or handing it over to someone else.

  4. File Conversion: dd can convert the format of files, such as converting an ISO image to a USB bootable format, or transforming raw binary data into a readable text format.

  5. Low-Level Disk Operations: Since dd operates at a very low level, it can be used for advanced disk operations like changing partition tables, disk layout, or even modifying the boot sector. However, caution should be exercised as these operations can have serious consequences.

It's worth noting that dd operates silently and does not provide any progress indication by default, so it's important to exercise caution and double-check the commands entered before executing them. A small mistake can cause significant data loss.

List of commands for dd:

  • dd:tldr:207f8 dd: Benchmark the write performance of a disk.
    $ dd if=/dev/zero of=${filename_1GB} bs=${1024} count=${1000000}
    try on your machine
    explain this command
  • dd:tldr:443e6 dd: Make a bootable USB drive from an isohybrid file (such like `archlinux-xxx.iso`).
    $ dd if=${filename-iso} of=/dev/${usb_drive}
    try on your machine
    explain this command
  • dd:tldr:4e0b2 dd: Clone a drive to another drive with 4 MiB block and ignore error.
    $ dd if=/dev/${source_drive} of=/dev/${dest_drive} bs=${4194304} conv=${noerror}
    try on your machine
    explain this command
  • dd:tldr:50378 dd: Generate a system backup into an IMG file.
    $ dd if=${-dev-drive_device} of=${filename-img}
    try on your machine
    explain this command
  • dd:tldr:6825c dd: Generate a file of 100 random bytes by using kernel random driver.
    $ dd if=/dev/urandom of=${path-to-random_file} bs=${100} count=${1}
    try on your machine
    explain this command
  • dd:tldr:9f6b5 dd: Clone a drive to another drive with 4 MiB block, ignore error and show the progress.
    $ dd if=${-dev-source_drive} of=${-dev-dest_drive} bs=${4M} conv=${noerror} status=progress
    try on your machine
    explain this command
  • dd:tldr:aeb5f dd: Make a bootable USB drive from an isohybrid file (such like `archlinux-xxx.iso`) and show the progress.
    $ dd if=${filename-iso} of=${-dev-usb_drive} status=progress
    try on your machine
    explain this command
  • dd:tldr:f26f2 dd: Generate a system backup into an IMG file and show the progress.
    $ dd if=/dev/${drive_device} of=${filename-img} status=progress
    try on your machine
    explain this command
tool overview