View Single Post
  #4   (View Single Post)  
Old 30th December 2010
Carpetsmoker's Avatar
Carpetsmoker Carpetsmoker is offline
Real Name: Martin
Tcpdump Spy
 
Join Date: Apr 2008
Location: Netherlands
Posts: 2,243
Default

I use dd on a regular basis to copy disks on FreeBSD, you *need* to specify a block size otherwise it will *always* be slow.

In general, I just choose 16MB.

Example: # dd if=/dev/ad0 of=/dev/ad1 bs=16M

Using a variety of WD disks, I get about 100MB/s transfer rates.

I just tested your command, and it's also very slow on my system, even with a larger block size.
A "normal" dd without pipes to gzip and split works fine.

Using:
# dd if=/dev/ad1 bs=16M | gzip -c > /data/tmp/img

Is also very slow. If I look at top, I notice that gzip is using 100% CPU.

Note that this is on an Intel Atom system, so that's not particularly fast, but the point is that the problem may be in your pipies to gzip or split and not in dd.

Quote:
I would like to bump it up a bit but this is not an average dd command. It's using gZip and I'm not sure where to place the numbers like bs=1M to this appending type dd command.
Code:
dd if=/dev/ad4s1 bs=16M | gzip -c | split -b 3500m - /12/PcBSD-Partiton-dd-By-FreeBSD.gz.
__________________
UNIX was not designed to stop you from doing stupid things, because that would also stop you from doing clever things.
Reply With Quote