# HD speed . cant get Timing buffered disk reads up to speed!

## doblebo

/dev/hda:

 Timing cached reads:   1024 MB in  2.01 seconds = 510.55 MB/sec

 Timing buffered disk reads:   78 MB in  3.05 seconds =  25.57 MB/sec

which is OK.. but my problem is here:

/dev/hdb:

 Timing cached reads:   904 MB in  2.01 seconds = 450.27 MB/sec

 Timing buffered disk reads:    6 MB in  3.76 seconds =   1.60 MB/sec

here are my settings for this drive: 

```
root@b0x gumby # hdparm -dvi /dev/hdb

/dev/hdb:

 multcount    = 16 (on)

 IO_support   =  1 (32-bit)

 unmaskirq    =  1 (on)

 using_dma    =  1 (on)

 keepsettings =  0 (off)

 readonly     =  0 (off)

 readahead    = 128 (on)

 geometry     = 16383/255/63, sectors = 61492838400, start = 0

 Model=IC35L060AVV207-0, FwRev=V22OA66A, SerialNo=VNVB07G2GUVHHM

 Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs }

 RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=52

 BuffType=DualPortCache, BuffSize=1821kB, MaxMultSect=16, MultSect=16

 CurCHS=4047/16/255, CurSects=16511760, LBA=yes, LBAsects=120103200

 IORDY=on/off, tPIO={min:240,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 

 AdvancedPM=yes: disabled (255) WriteCache=enabled

 Drive conforms to: ATA/ATAPI-6 T13 1410D revision 3a: 

 * signifies the current active mode
```

any ideas on how i can get this drive up to speed?

----------

## NeddySeagoon

doblebo,

I wouldn't be any too happy with /dev/hda at 25Mb/sec. If it can do udma5, like /dev/hdb, it should be over 40Mb/sec.

Tell us what drives you have, what motherboard and chpset they are connected to and if you use and 80 conductor IDE cable or not.

----------

## doblebo

 *NeddySeagoon wrote:*   

> doblebo,
> 
> I wouldn't be any too happy with /dev/hda at 25Mb/sec. If it can do udma5, like /dev/hdb, it should be over 40Mb/sec.
> 
> Tell us what drives you have, what motherboard and chpset they are connected to and if you use and 80 conductor IDE cable or not.

 

/dev/hda is a western digital 80 gig drive WDC WD800JB-00ETA0

/dev/hdb is a hitachi 60 gig drive IC35L060AVV207-0

/dev/hdd is a maxtor 20 gig drive Maxtor 52049H4

motherboard and processor = K7S5A Pro with Athlon XP 2400+

IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE] (rev d0)

as far as the cable goes... yes it is 80 conductor IDE cable with the blue thing plugged into the board, /dev/hda is master and /dev/hdb is slave on the cable.

hda and hdd are getting OK speeds (ran test again without other things running in background) hda is giving me results of 38 megs per second and hdd is giving me 30~ish. when i run the timings in an Eterm window with enlightenment and mozilla (2 tabs open) gaim and gkrellm, my hda timings go down into the 20's (megs per sec). 

/dev/hdb will do 2.5 megs per second at best. i dont understand what the problem is. its on the same cable, even tried swithing master/slave around so i dont think its the cable. 

```
root@b0x gumby # hdparm -d1 -A1 -u1 -a64 -X69 -c3 -m16 -W1 -M192 /dev/hdb

/dev/hdb:

 setting fs readahead to 64

 setting 32-bit IO_support flag to 3

 setting multcount to 16

 setting unmaskirq to 1 (on)

 setting using_dma to 1 (on)

 setting xfermode to 69 (UltraDMA mode5)

 setting drive read-lookahead to 1 (on)

 setting drive write-caching to 1 (on)

 multcount    = 16 (on)

 IO_support   =  3 (32-bit w/sync)

 unmaskirq    =  1 (on)

 using_dma    =  1 (on)

 readahead    = 64 (on)

 setting acoustic management to 192

 acoustic     =  0 (128=quiet ... 254=fast)

```

```
root@b0x gumby # hdparm -tT /dev/hdb

/dev/hdb:

 Timing cached reads:   1028 MB in  2.01 seconds = 512.54 MB/sec

 Timing buffered disk reads:    6 MB in  3.07 seconds =   1.96 MB/sec

```

and so i'm stumped. 

thanks

----------

## NeddySeagoon

doblebo,

About the only thing I can think of is that your  *Quote:*   

> hitachi 60 gig drive IC35L060AVV207-0 

 is DMA blacklisted. That means you can set it all up correctly and it will be ignored by the kernel to avoid data corruption.

I grepped hitachi and IC35L060 for the whole kernel tree and the hits I got didn't fully match your drive.

If you want to try, the command sequence is

```
cd /usr/src/linux

grep -R IC35L060 ./*
```

Its case sensitive too. It can take a while, its going to read the whole kernel tree, including the binary files.

----------

## doblebo

 *NeddySeagoon wrote:*   

> doblebo,
> 
> About the only thing I can think of is that your  *Quote:*   hitachi 60 gig drive IC35L060AVV207-0  is DMA blacklisted. That means you can set it all up correctly and it will be ignored by the kernel to avoid data corruption.
> 
> 

 

that is entirely possible. this was a fry's clearance item and the drive failed on me once before, but i was able to reformat and get it running again. 

so i grepped..

```
root@b0x linux # grep -R IC35L060 ./*

./drivers/ide/pci/hpt366.h:     "IC35L060AVER07-0",

./drivers/ide/pci/hpt366.h:     "IC35L060AVER07-0",

```

will that do me any good?

Thanks again   :Smile: 

----------

## NeddySeagoon

doblebo,

Since you didn't get an exact match, yor drive is not mentioned by name, either in a blacklist or whitelist. The hpt366.h is a part of the Highpoint IDE driver software, so what you found is only relevent to users of that card.

Is there anything in your log files. Look through /var/log for disk errors after you have been using /dev/hdb.

A high error rate will lead to a low useful data rate because of retries.

Such errors will be logged.

Try 

```
emerge smartmontools
```

This tool allows you to read the drives Self-Monitoring, Analysis and Reporting Technology (SMART) info. After you have it installed, read its man page 

```
man smartd
```

to find out how to use it .

----------

## doblebo

ok this is good stuff. Thanks again and again NeddySeagoon!!!

here's some output from the command

```
smartd -d -i 30
```

```
Device: /dev/hdb, 4 Currently unreadable (pending) sectors

Device: /dev/hdb, 4 Currently unreadable (pending) sectors

Device: /dev/hdb, SMART Usage Attribute: 194 Temperature_Celsius changed from 125 to 122

Device: /dev/hda, SMART Usage Attribute: 194 Temperature_Celsius changed from 106 to 107

```

before that there's nothing special, just the drive being recognized as smart capable and adding it to the 'monitor' list.

so then i try moving a file which doesnt really tell me anything new except that the temperature goes up a little bit.

```
Device: /dev/hdb, 4 Currently unreadable (pending) sectors

Device: /dev/hdb, 4 Currently unreadable (pending) sectors

Device: /dev/hdb, SMART Usage Attribute: 194 Temperature_Celsius changed from 122 to 125

Device: /dev/hda, SMART Usage Attribute: 194 Temperature_Celsius changed from 107 to 106

Device: /dev/hdb, 4 Currently unreadable (pending) sectors

Device: /dev/hdb, 4 Currently unreadable (pending) sectors

Device: /dev/hdb, 4 Currently unreadable (pending) sectors

Device: /dev/hdb, 4 Currently unreadable (pending) sectors

Device: /dev/hdb, SMART Usage Attribute: 194 Temperature_Celsius changed from 125 to 122

Device: /dev/hda, SMART Usage Attribute: 194 Temperature_Celsius changed from 106 to 105

Device: /dev/hdb, 4 Currently unreadable (pending) sectors

```

the 

Device: /dev/hdb, 4 Currently unreadable (pending) sectors

message just keeps repeating over and over. is this telling me that the drive is better off as a paperweight?

----------

## doblebo

```
root@b0x / # smartctl -H /dev/hdb

smartctl version 5.33 [i686-pc-linux-gnu] Copyright (C) 2002-4 Bruce Allen

Home page is http://smartmontools.sourceforge.net/

=== START OF READ SMART DATA SECTION ===

SMART overall-health self-assessment test result: PASSED

```

thats gotta mean something good, right?

----------

## NeddySeagoon

doblebo,

That means the drive thinks its not broken.

It maty be worth running 

```
fsck
```

. and/or 

```
badblocks
```

 on the contents of /dev/hdb.

Can you test the drive on an IDE cable on its own?

----------

## doblebo

 *NeddySeagoon wrote:*   

> doblebo,
> 
> That means the drive thinks its not broken.
> 
> It maty be worth running 
> ...

 

i have used badblocks /dev/hdb and it completed after a long while without printing any messages to the screen.

i've also used fsck and even the Hitachi Drive Fitness tool without any luck

when i first used this drive with its own cable, it gave the the same SLOW performance.

thanks

----------

