Re: dd too slow
From: emilio lazardo (NotARealAddress_at_spam.this)
Date: Sat, 20 Dec 2003 23:08:26 GMT
'hdparm -iv /dev/hda /dev/hdc' will tell you if DMA is set on both drives,
which it should be:
> hdparm -v /dev/hdb
multcount = 0 (off)
IO_support = 1 (32-bit)
unmaskirq = 1 (on)
using_dma = 1 (on)
keepsettings = 1 (on)
readonly = 0 (off)
readahead = 8 (on)
geometry = 2491/255/63, sectors = 40021632, start = 0
Even for slower 5400RPM drives, 40GB -> 40GB should take no more than 45
minutes when the drives are on different controllers as yours are.
For block sizes over 4k, the 'bs' value does not make any significant
difference. For example, 'bs=4k' will copy just as fast as 'bs=1024k'.
> hdparm -tT /dev/hdb
Timing buffer-cache reads: 664 MB in 2.00 seconds = 332.00 MB/sec
Timing buffered disk reads: 84 MB in 3.04 seconds = 27.63 MB/sec
> /usr/bin/time dd if=/dev/hdb of=/spare/bs.test bs=4k count=131072
131072+0 records in
131072+0 records out
: dd if=/dev/hdb of=/spare/bs.test bs=4k count=131072
: 31.34 0:31.34 s 17.15 u 0.06 c 54% mapf 112 mipf 12
> /usr/bin/time dd if=/dev/hdb of=/spare/bs.test bs=1024k count=512
512+0 records in
512+0 records out
: dd if=/dev/hdb of=/spare/bs.test bs=1024k count=512
: 31.31 0:31.31 s 17.47 u 0.00 c 55% mapf 113 mipf 267
> bc -q
> I had to copy one HDD to another of same brand-size-model and it took more
> than 6 hours (I left it running) for 40GB UDMA 100 hard drives.
> I used these command options
> dd if=/dev/hda of=/dev/hdc bc=1M
> is this a normal speed for this size?
> can make it faster?
> would hdparam do any good?