User Tools

Site Tools


dd - dump device

create a dummy file

The following command creates a “dummy”-file named dummy.bin with a size of 100'000 bytes (98 KB):

dd if=/dev/zero of=dummy.bin bs=100000 count=1

Create 7000 dummy files:

for i in `seq 1 7000`;
  dd if=/dev/zero of=dummy-$i bs=400000 count=1
The command above creates files with a total size of about 2.7 G. Make sure you have enough disk space available.

create a disk image

dd if=/dev/hda bs=16065b | gzip -1 > /mnt/lotofspace/image.gz

load a disk image

gunzip -dc /mnt/lotofspace/image.gz | dd of=/dev/hdc bs=16065b
/srv/ · Last modified: 2009/08/15 12:14 (external edit)