Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have nearly two identical servers, the only difference between the two is the version of Linux and the Hard Drive. Server 1 had (what I think) is a better drive, therefore the performance should be better then what I'm seeing compared to Server 2. Most notably is the difference between the dd test on server 1 and 2 as seen below.

Any suggestions on what to check and what would cause this?

Server 1:

Drive is a Barracuda 7200.12 SATA 6Gb/s 1TB Hard Drive w/64 MB Cache Running XenServer, test performed @ the non-guest level.

hdparm -i /dev/sda

/dev/sda:

 Model=ST31000524AS                            , FwRev=JC4B    ,
SerialNo=            5VP9RWSG
 Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs RotSpdTol>.5% }
 RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=4
 BuffType=unknown, BuffSize=0kB, MaxMultSect=16, MultSect=?16?
 CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=268435455
 IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120}
 PIO modes:  pio0 pio1 pio2 pio3 pio4
 DMA modes:  mdma0 mdma1 mdma2
 UDMA modes: udma0 udma1 udma2
 AdvancedPM=no WriteCache=enabled
 Drive conforms to: unknown:  ATA/ATAPI-4 ATA/ATAPI-5 ATA/ATAPI-6 ATA/ATAPI-7

hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   43912 MB in  1.99 seconds = 22043.28 MB/sec
 Timing buffered disk reads:  344 MB in  3.00 seconds = 114.64 MB/sec

dd if=/dev/zero of=/tmp/output.img bs=8k count=256k

262144+0 records in
262144+0 records out
2147483648 bytes (2.1 GB) copied, 28.0981 seconds, 76.4 MB/s

/etc/fstab

LABEL=root-rizocqaz    /         ext3     defaults   1  1
/var/swap/swap.001          swap      swap   defaults   0  0
none        /dev/pts  devpts defaults   0  0
none        /dev/shm  tmpfs  defaults   0  0
none        /proc     proc   defaults   0  0
none        /sys      sysfs  defaults   0  0

Server 2:

Drive is a Hitachi Deskstar 7200 SATA 3Gb/s 1TB Drive w/32 MB Cache Running Debian 6

hdparm -i /dev/sda

/dev/sda:

 Model=Hitachi HDS721010CLA332, FwRev=JP4OA3MA, SerialNo=JP2940HZ3L08GC
 Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs }
 RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=56
 BuffType=DualPortCache, BuffSize=29999kB, MaxMultSect=16, MultSect=16
 CurCHS=65535/1/63, CurSects=4128705, LBA=yes, LBAsects=1953525168
 IORDY=on/off, tPIO={min:120,w/IORDY:120}, tDMA={min:120,rec:120}
 PIO modes:  pio0 pio1 pio2 pio3 pio4
 DMA modes:  mdma0 mdma1 mdma2
 UDMA modes: udma0 udma1 udma2 udma3 udma4 udma5 *udma6
 AdvancedPM=yes: disabled (255) WriteCache=enabled
 Drive conforms to: unknown:  ATA/ATAPI-2,3,4,5,6,7

dd if=/dev/zero of=/tmp/output.img bs=8k count=256k

262144+0 records in
262144+0 records out
2147483648 bytes (2.1 GB) copied, 13.0055 s, 165 MB/s

hdparm -tT /dev/sda

 Timing cached reads:   24350 MB in  2.00 seconds = 12191.54 MB/sec
 Timing buffered disk reads: 418 MB in  3.00 seconds = 139.22 MB/sec

/etc/fstab

proc            /proc           proc    defaults        0       0

UUID=7fcbd976-2dbc-43fb-a321-2dfd5bc0ff4f /               ext3    errors=remount-ro 0       1
UUID=b3a09499-a85e-4b6c-a6e5-14586861c347 none            swap    sw              0       0
share|improve this question
    
What version of linux are you running on both machines? Also, can we get the output of /etc/fstab on both machines as well? –  Rilindo Dec 16 '11 at 2:52
    
Server 1: XenServer 6 Server 2: Debian 6 - adding fstab to above main post. –  John Dec 16 '11 at 2:54
    
Nevermind, i see the version of Linux. Sorry. –  Rilindo Dec 16 '11 at 3:00
    
Were any guests active on the XenServer at the time? –  Andrew Dec 16 '11 at 3:04
    
Let me ask a couple of more things: Are you running LVM on both machines and what is the output of cat /sys/block/sda/queue/scheduler? –  Rilindo Dec 16 '11 at 3:15

1 Answer 1

The linear throughput of a disk deteriorates as the magnetic tracks spiral further to the disk's center:

enter image description here

This is simply due to the fact that the linear velocity there is much lower than in the outer parts of the rotating disk.

Since you do not know on which part of the disk the blocks of /tmp/output.img are ending up, your comparison of "dd" results is pointless. In contrast, the "hdparm" test always does read the first blocks of the disk - this is why you see more consistent results there.

Anyway, the results will vary as there likely is some concurrency in disk activity while your systems read and write the disk while you are measuring.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.