dd(1) performance when copiing a disk to another

Patrick Proniewski patpro at patpro.net
Mon Oct 3 00:55:58 PDT 2005

Hi Arne and Eric,

>>> # atacontrol mode 0
>>> Master = BIOSPIO
>>> Slave  = BIOSPIO

>> Hmm... 0 seems to be the wrong ata... Thats why the output does
>> not fit to SATA drives, I think...

oups... I'll have to do it again with channels 2 and 3

>>> # dd if=/dev/ad4 of=/dev/null bs=1m count=1000
>>> 1000+0 records in
>>> 1000+0 records out
>>> 1048576000 bytes transferred in 17.647464 secs (59417943
>>> bytes/sec)

>> That seems to be 2 or about 2 times faster than disc->disc
>> transfer... But still slower, than I would have expected...
>> SATA150 sounds like the drive can do 150MB/sec...

As Eric pointed out, you just can"t reach 150 MB/s with one disk,  
it's a technological maximum for the bus, but real world performance  
is well bellow this max.
In fact, I've though I would reach about 50 to 60 MB/s.

>>>> (Maybe you could find a way to copy /dev/zero to /dev/ad6
>>>> without destroying the previous work... :-))
>>> well, not very easy both disk are the same size ;)

>> I thought of the first 1000 1MB blocks... :-)

damn, I misread this one... :)
I'm gonna try this asap.

> Instead of dd, why not use gmirror?

I had no idea gmirror exists, but I'll continue with dd. It's a one  
time experiment.

> Have you tried a smaller block size?  What does 8k, 16k, or 512k do  
> for you?  There really isn't much room for improvement here on a  
> single device.

nop, I'll try one of them, but I can't do many experiments, the box  
is in my living room, it's a 1U rack, and it's VERY VERY noisy. My  
girlfriend will kill me if it's running more than an hour a day :))


More information about the freebsd-performance mailing list