Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
WD caviar green drive writes at 110M/s but reads at 4M/s ...
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Wed Sep 30, 2009 12:05 pm    Post subject: WD caviar green drive writes at 110M/s but reads at 4M/s ... Reply with quote

Brand new drive, baught last week, actually doing badblocks to test it; I can read it at 108M/s average, but reads at ~4M/s.

The Sata cable used was used previously on an other (Seagate) HDD that was working correctly (65M/s in both ways). A second identical WD drive, bought the same day behave the same way, but of course with a different Sata cable :) I don't think the problem can the the cable.

Any clue what can be bad ?

Code:
Device Model:     WDC WD10EADS-00M2B0
Firmware Version: 01.00A01
User Capacity:    1,000,204,886,016 bytes


Code:
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   278 MB in  2.01 seconds = 138.64 MB/sec
 Timing buffered disk reads:   16 MB in  3.37 seconds =   4.74 MB/sec


Code:
moon-gen-3 ~ # dd if=/dev/zero of=/dev/sda bs=1M count=1k
1024+0 records in
1024+0 records out
1073741824 bytes (1.1 GB) copied, 10.4055 s, 103 MB/s
moon-gen-3 ~ # dd of=/dev/null if=/dev/sda bs=1M count=1
1+0 records in
1+0 records out
1048576 bytes (1.0 MB) copied, 0.00454295 s, 231 MB/s
moon-gen-3 ~ # dd of=/dev/null if=/dev/sda bs=1M count=10
10+0 records in
10+0 records out
10485760 bytes (10 MB) copied, 0.058545 s, 179 MB/s
moon-gen-3 ~ # dd of=/dev/null if=/dev/sda bs=1M count=100
100+0 records in
100+0 records out
104857600 bytes (105 MB) copied, 0.425158 s, 247 MB/s
moon-gen-3 ~ # dd of=/dev/null if=/dev/sda bs=1M count=1000
1000+0 records in
1000+0 records out
1048576000 bytes (1.0 GB) copied, 166.59 s, 6.3 MB/s
moon-gen-3 ~ #



Smart NOW after 10h doing badblocks (100% writing once, and 15% reading once:

Code:
smartctl version 5.38 [i686-pc-linux-gnu] Copyright (C) 2002-8 Bruce Allen
Home page is http://smartmontools.sourceforge.net/

=== START OF INFORMATION SECTION ===
Device Model:     WDC WD10EADS-00M2B0
Serial Number:    WD-WCAV51071685
Firmware Version: 01.00A01
User Capacity:    1,000,204,886,016 bytes
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   8
ATA Standard is:  Exact ATA specification draft version not indicated
Local Time is:    Wed Sep 30 13:57:14 2009 CEST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status:  (0x84)   Offline data collection activity
               was suspended by an interrupting command from host.
               Auto Offline Data Collection: Enabled.
Self-test execution status:      (   0)   The previous self-test routine completed
               without error or no self-test has ever
               been run.
Total time to complete Offline
data collection:        (20760) seconds.
Offline data collection
capabilities:           (0x7b) SMART execute Offline immediate.
               Auto Offline data collection on/off support.
               Suspend Offline collection upon new
               command.
               Offline surface scan supported.
               Self-test supported.
               Conveyance Self-test supported.
               Selective Self-test supported.
SMART capabilities:            (0x0003)   Saves SMART data before entering
               power-saving mode.
               Supports SMART auto save timer.
Error logging capability:        (0x01)   Error logging supported.
               General Purpose Logging supported.
Short self-test routine
recommended polling time:     (   2) minutes.
Extended self-test routine
recommended polling time:     ( 239) minutes.
Conveyance self-test routine
recommended polling time:     (   5) minutes.
SCT capabilities:           (0x303f)   SCT Status supported.
               SCT Feature Control supported.
               SCT Data Table supported.

SMART Attributes Data Structure revision number: 16
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x002f   200   200   051    Pre-fail  Always       -       0
  3 Spin_Up_Time            0x0027   118   118   021    Pre-fail  Always       -       7091
  4 Start_Stop_Count        0x0032   100   100   000    Old_age   Always       -       11
  5 Reallocated_Sector_Ct   0x0033   200   200   140    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x002e   200   200   000    Old_age   Always       -       0
  9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       12
 10 Spin_Retry_Count        0x0032   100   253   000    Old_age   Always       -       0
 11 Calibration_Retry_Count 0x0032   100   253   000    Old_age   Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   000    Old_age   Always       -       9
192 Power-Off_Retract_Count 0x0032   200   200   000    Old_age   Always       -       8
193 Load_Cycle_Count        0x0032   200   200   000    Old_age   Always       -       27
194 Temperature_Celsius     0x0022   108   106   000    Old_age   Always       -       39
196 Reallocated_Event_Count 0x0032   200   200   000    Old_age   Always       -       0
197 Current_Pending_Sector  0x0032   200   200   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0030   100   253   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x0032   198   198   000    Old_age   Always       -       58865
200 Multi_Zone_Error_Rate   0x0008   100   253   000    Old_age   Offline      -       0

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
No self-tests have been logged.  [To run self-tests, use: smartctl -t]


SMART Selective self-test log data structure revision number 1
 SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    1        0        0  Not_testing
    2        0        0  Not_testing
    3        0        0  Not_testing
    4        0        0  Not_testing
    5        0        0  Not_testing
Selective self-test flags (0x0):
  After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.



Smart log in the first minute after boot, before any manipulation (dd, badblocks, fdisk ... )

Code:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x002f   100   253   051    Pre-fail  Always       -       0
  3 Spin_Up_Time            0x0027   118   118   021    Pre-fail  Always       -       7091
  4 Start_Stop_Count        0x0032   100   100   000    Old_age   Always       -       11
  5 Reallocated_Sector_Ct   0x0033   200   200   140    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x002e   100   253   000    Old_age   Always       -       0
  9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       0
 10 Spin_Retry_Count        0x0032   100   253   000    Old_age   Always       -       0
 11 Calibration_Retry_Count 0x0032   100   253   000    Old_age   Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   000    Old_age   Always       -       9
192 Power-Off_Retract_Count 0x0032   200   200   000    Old_age   Always       -       8
193 Load_Cycle_Count        0x0032   200   200   000    Old_age   Always       -       13
194 Temperature_Celsius     0x0022   117   113   000    Old_age   Always       -       30
196 Reallocated_Event_Count 0x0032   200   200   000    Old_age   Always       -       0
197 Current_Pending_Sector  0x0032   200   200   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0030   100   253   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x0032   199   199   000    Old_age   Always       -       9
200 Multi_Zone_Error_Rate   0x0008   100   253   000    Old_age   Offline      -       0


Some google answers say that UDMA_CRC_Error_Count reveals bad cable; but I dont think my cable are bad; I tried to replug them several times (and reboot), but it does not change any thing.

Any other idea ?

Vmstat confirms the rates given by dd: about 105M/s for writing, and between 5 and 10 for reading.
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png
Back to top
View user's profile Send private message
kernelOfTruth
Watchman
Watchman


Joined: 20 Dec 2005
Posts: 6111
Location: Vienna, Austria; Germany; hello world :)

PostPosted: Wed Sep 30, 2009 6:07 pm    Post subject: Reply with quote

yes,

switch your i/o scheduler:

cat /sys/block/sda/queue/scheduler

to deadline or at least something other than the scheduler you're currently having

Code:
echo "deadline" > /sys/block/sda/queue/scheduler


then check whether it changed
Code:
cat /sys/block/sda/queue/scheduler




you also might need to change your queue_depth from 31 to 2 or even 1 (0 doesn't work):

cat /sys/block/sda/device/queue_depth

Code:
echo "2" > /sys/block/sda/device/queue_depth


then check
Code:
cat /sys/block/sda/device/queue_depth



hope that helps ...
_________________
https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa

Hardcore Gentoo Linux user since 2004 :D
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7525
Location: almost Mile High in the USA

PostPosted: Wed Sep 30, 2009 6:19 pm    Post subject: Re: WD caviar green drive writes at 110M/s but reads at 4M/s Reply with quote

Anything showing up in dmesg?

Your UDMA error count would definitely have something to do with it, since it's changing a lot, it should not be changing that much. However, what's causing it--I don't know. Also check your power cable to make sure you have a clean connection.

doublehp wrote:
Code:
Device Model:     WDC WD10EADS-00M2B0
Firmware Version: 01.00A01
User Capacity:    1,000,204,886,016 bytes


Code:
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   278 MB in  2.01 seconds = 138.64 MB/sec
 Timing buffered disk reads:   16 MB in  3.37 seconds =   4.74 MB/sec



What computer is this? 138.64MB/sec is abysmal...
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
drescherjm
Advocate
Advocate


Joined: 05 Jun 2004
Posts: 2780
Location: Pittsburgh, PA, USA

PostPosted: Wed Sep 30, 2009 6:26 pm    Post subject: Reply with quote

Quote:
What computer is this? 138.64MB/sec is abysmal...


Yes, It should be 10 to 30 times that..
_________________
John

My gentoo overlay
Instructons for overlay
Back to top
View user's profile Send private message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Thu Oct 01, 2009 12:21 am    Post subject: Reply with quote

kernelOfTruth

Code:
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   352 MB in  2.00 seconds = 175.88 MB/sec
 Timing buffered disk reads:   16 MB in  3.39 seconds =   4.72 MB/sec
moon-gen-3 ~ #
moon-gen-3 ~ # cat /sys/block/sda/queue/scheduler
noop [anticipatory] deadline cfq
moon-gen-3 ~ # echo "deadline" > /sys/block/sda/queue/scheduler
moon-gen-3 ~ # cat /sys/block/sda/queue/scheduler
noop anticipatory [deadline] cfq
moon-gen-3 ~ #
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   168 MB in  2.00 seconds =  83.90 MB/sec
 Timing buffered disk reads:    6 MB in  3.95 seconds =   1.52 MB/sec
moon-gen-3 ~ #
moon-gen-3 ~ # echo "cfq" > /sys/block/sda/queue/scheduler
moon-gen-3 ~ # cat /sys/block/sda/queue/scheduler
noop anticipatory deadline [cfq]
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   392 MB in  2.00 seconds = 195.59 MB/sec
 Timing buffered disk reads:   14 MB in  3.34 seconds =   4.19 MB/sec
moon-gen-3 ~ # echo "noop" > /sys/block/sda/queue/scheduler
moon-gen-3 ~ # cat /sys/block/sda/queue/scheduler
[noop] anticipatory deadline cfq
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   212 MB in  2.00 seconds = 105.88 MB/sec
 Timing buffered disk reads:   26 MB in  3.17 seconds =   8.19 MB/sec
moon-gen-3 ~ # echo "anticipatory" > /sys/block/sda/queue/scheduler
moon-gen-3 ~ # cat /sys/block/sda/queue/scheduler
noop [anticipatory] deadline cfq
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   358 MB in  2.01 seconds = 178.48 MB/sec
 Timing buffered disk reads:   14 MB in  3.35 seconds =   4.17 MB/sec
moon-gen-3 ~ # echo "noop" > /sys/block/sda/queue/scheduler
moon-gen-3 ~ # cat /sys/block/sda/queue/scheduler
[noop] anticipatory deadline cfq
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   384 MB in  2.00 seconds = 191.65 MB/sec
 Timing buffered disk reads:   22 MB in  3.08 seconds =   7.15 MB/sec
moon-gen-3 ~ #


So, YES it changes things and have impact. But, I am not satisfied :)

I can not change depth:

Code:
moon-gen-3 ~ # cat /sys/block/sda/device/queue_depth
1
moon-gen-3 ~ # echo 2 > /sys/block/sda/device/queue_depth
-su: /sys/block/sda/device/queue_depth: Permission denied
moon-gen-3 ~ # cat  /sys/block/sda/device/queue_type
none
moon-gen-3 ~ #


eccerr0r

dmesg is not time stamped. I prefer /var/log/messages :

Code:
Oct  1 02:02:07 moon-gen-3 sd 0:0:0:0: [sda] 1953525168 512-byte hardware sectors: (1.00 TB/931 GiB)
Oct  1 02:02:07 moon-gen-3 sd 0:0:0:0: [sda] Write Protect is off
Oct  1 02:02:07 moon-gen-3 sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
Oct  1 02:02:07 moon-gen-3 sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
Oct  1 02:02:07 moon-gen-3 ata1.00: exception Emask 0x12 SAct 0x0 SErr 0x1000500 action 0x6
Oct  1 02:02:07 moon-gen-3 ata1.00: BMDMA stat 0x5
Oct  1 02:02:07 moon-gen-3 ata1: SError: { UnrecovData Proto TrStaTrns }
Oct  1 02:02:07 moon-gen-3 ata1.00: cmd c8/00:00:00:70:00/00:00:00:00:00/e0 tag 0 dma 131072 in
Oct  1 02:02:07 moon-gen-3 res 51/84:1f:00:70:00/84:00:00:00:00/e0 Emask 0x12 (ATA bus error)
Oct  1 02:02:07 moon-gen-3 ata1.00: status: { DRDY ERR }
Oct  1 02:02:07 moon-gen-3 ata1.00: error: { ICRC ABRT }
Oct  1 02:02:07 moon-gen-3 ata1: hard resetting link
Oct  1 02:02:07 moon-gen-3 ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
Oct  1 02:02:07 moon-gen-3 ata1.00: configured for UDMA/33
Oct  1 02:02:07 moon-gen-3 ata1: EH complete
Oct  1 02:02:07 moon-gen-3 ata1.00: exception Emask 0x12 SAct 0x0 SErr 0x1000500 action 0x6
Oct  1 02:02:07 moon-gen-3 ata1.00: BMDMA stat 0x5
Oct  1 02:02:07 moon-gen-3 ata1: SError: { UnrecovData Proto TrStaTrns }
Oct  1 02:02:07 moon-gen-3 ata1.00: cmd c8/00:00:00:71:00/00:00:00:00:00/e0 tag 0 dma 131072 in
Oct  1 02:02:07 moon-gen-3 res 51/84:7f:00:71:00/84:00:00:00:00/e0 Emask 0x12 (ATA bus error)
Oct  1 02:02:07 moon-gen-3 ata1.00: status: { DRDY ERR }
Oct  1 02:02:07 moon-gen-3 ata1.00: error: { ICRC ABRT }
Oct  1 02:02:07 moon-gen-3 ata1: hard resetting link
Oct  1 02:02:07 moon-gen-3 ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
Oct  1 02:02:07 moon-gen-3 ata1.00: configured for UDMA/33
Oct  1 02:02:07 moon-gen-3 ata1: EH complete
Oct  1 02:02:07 moon-gen-3 sd 0:0:0:0: [sda] 1953525168 512-byte hardware sectors: (1.00 TB/931 GiB)
Oct  1 02:02:07 moon-gen-3 sd 0:0:0:0: [sda] Write Protect is off
Oct  1 02:02:07 moon-gen-3 sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
Oct  1 02:02:07 moon-gen-3 ata1.00: exception Emask 0x12 SAct 0x0 SErr 0x1000500 action 0x6
Oct  1 02:02:07 moon-gen-3 ata1.00: BMDMA stat 0x5
Oct  1 02:02:07 moon-gen-3 ata1: SError: { UnrecovData Proto TrStaTrns }
Oct  1 02:02:07 moon-gen-3 ata1.00: cmd c8/00:00:00:74:00/00:00:00:00:00/e0 tag 0 dma 131072 in
Oct  1 02:02:07 moon-gen-3 res 51/84:3f:00:74:00/84:00:00:00:00/e0 Emask 0x12 (ATA bus error)
Oct  1 02:02:07 moon-gen-3 ata1.00: status: { DRDY ERR }
Oct  1 02:02:07 moon-gen-3 ata1.00: error: { ICRC ABRT }
Oct  1 02:02:07 moon-gen-3 ata1: hard resetting link
Oct  1 02:02:08 moon-gen-3 ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
Oct  1 02:02:08 moon-gen-3 ata1.00: configured for UDMA/33
Oct  1 02:02:08 moon-gen-3 ata1: EH complete
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] 1953525168 512-byte hardware sectors: (1.00 TB/931 GiB)
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] Write Protect is off
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
Oct  1 02:02:08 moon-gen-3 ata1.00: exception Emask 0x12 SAct 0x0 SErr 0x1000500 action 0x6
Oct  1 02:02:08 moon-gen-3 ata1.00: BMDMA stat 0x5
Oct  1 02:02:08 moon-gen-3 ata1: SError: { UnrecovData Proto TrStaTrns }
Oct  1 02:02:08 moon-gen-3 ata1.00: cmd c8/00:00:00:a3:00/00:00:00:00:00/e0 tag 0 dma 131072 in
Oct  1 02:02:08 moon-gen-3 res 51/84:1f:00:a3:00/84:00:00:00:00/e0 Emask 0x12 (ATA bus error)
Oct  1 02:02:08 moon-gen-3 ata1.00: status: { DRDY ERR }
Oct  1 02:02:08 moon-gen-3 ata1.00: error: { ICRC ABRT }
Oct  1 02:02:08 moon-gen-3 ata1: hard resetting link
Oct  1 02:02:08 moon-gen-3 ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
Oct  1 02:02:08 moon-gen-3 ata1.00: configured for UDMA/33
Oct  1 02:02:08 moon-gen-3 ata1: EH complete
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] 1953525168 512-byte hardware sectors: (1.00 TB/931 GiB)
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] Write Protect is off
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
Oct  1 02:02:08 moon-gen-3 sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA


This probably happened while doing the previous test.

I cheked the IDMA error count on other drives; ALL my other drives have zero there. Even my Seagate. My seagate used to be on the Sata port, with my oldest Sata cable, where the WD is today (the Seagate is not on PATA-SATA adapter somewhere else ... and still works at >50M/s ).

While I am doing dd for reading the disk, the UDMA value get increased of about 3 units per second. The value is now hudge because I left badblocks read this disk for hours .. before I get bored and evaluated ETA = +120h instead of +23h .

My power cable seem to have a problem, but I hardly see how it could impact performance in this manner. I added aluminium fold around the data cable (some kind of additionnal shielding); did not gain any thing.

My second WD is on esata plug. So, different kind of data cable (different manifacturer), but same kind of power cable than the first one. So, yes there is an "external" common point between drives: the power cable.

I wonder if the firmware version could be the problem; many web sites tell about this version, but they do not really quote it as having problems ...

My box is ... old :) other drives usually get 250M/s to 280 for cache; Seagate on this Sata port also used to get around 250. These WD both get between 210 and 120M/s; usually around 150M. So, compared to my other drives, this value is really lower. But I understand that even 250M/s may still look abyssal for you :=)

drescherjm

No: DDR in DDR/SDRAM hybrid MB; running only an old Athlon at 1.6G. I could boost the clock a bit, but its offtopic. I could gain 50% by playing a bit in the BIOS settings.

*** *** ***

More ideas ? the only new idea I got here is to try an other power cable.
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png
Back to top
View user's profile Send private message
drescherjm
Advocate
Advocate


Joined: 05 Jun 2004
Posts: 2780
Location: Pittsburgh, PA, USA

PostPosted: Thu Oct 01, 2009 12:57 am    Post subject: Reply with quote

Quote:
No: DDR in DDR/SDRAM hybrid MB; running only an old Athlon at 1.6G.


I see. We had a bunch of those in the past but as they hit about 7 years old we began server consolidation.

I am thinking that this is caused by using some generic driver instead of the one for your chipset. I have seen read speeds like this on my laptop and this was the cause.
_________________
John

My gentoo overlay
Instructons for overlay
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7525
Location: almost Mile High in the USA

PostPosted: Thu Oct 01, 2009 3:50 pm    Post subject: Reply with quote

doublehp wrote:

Code:
moon-gen-3 ~ # cat /sys/block/sda/device/queue_depth
1
moon-gen-3 ~ # echo 2 > /sys/block/sda/device/queue_depth
-su: /sys/block/sda/device/queue_depth: Permission denied
moon-gen-3 ~ # cat  /sys/block/sda/device/queue_type
none
moon-gen-3 ~ #


I don't know what controller you have, but likely it doesn't support NCQ.

Quote:

I cheked the IDMA error count on other drives; ALL my other drives have zero there. Even my Seagate. My seagate used to be on the Sata port, with my oldest Sata cable, where the WD is today (the Seagate is not on PATA-SATA adapter somewhere else ... and still works at >50M/s ).

While I am doing dd for reading the disk, the UDMA value get increased of about 3 units per second. The value is now hudge because I left badblocks read this disk for hours .. before I get bored and evaluated ETA = +120h instead of +23h .

The DMA errors would indicate something is corrupting transfers. Since a corrupted transfer needs a re-do, you would lose throughput.

Quote:

My power cable seem to have a problem, but I hardly see how it could impact performance in this manner. I added aluminium fold around the data cable (some kind of additionnal shielding); did not gain any thing.

My second WD is on esata plug. So, different kind of data cable (different manifacturer), but same kind of power cable than the first one. So, yes there is an "external" common point between drives: the power cable.

I wonder if the firmware version could be the problem; many web sites tell about this version, but they do not really quote it as having problems ...

My box is ... old :) other drives usually get 250M/s to 280 for cache; Seagate on this Sata port also used to get around 250. These WD both get between 210 and 120M/s; usually around 150M. So, compared to my other drives, this value is really lower. But I understand that even 250M/s may still look abyssal for you :=)


As you well know, clean power is needed for disks to operate properly. If you don't have clean power, nothing is guaranteed.

So, as I can deduce with your very low cached reads, you probably have an old PCI motherboard/CPU and likely do not have on-board SATA controllers. How are you hooking up the SATA disk? What controller are you using?

This is my Athlon-XP 2200+ hdparm on my RAID5 (4xPATA, ECS K7S5A + Promise Ultra66, disk per channel):
Code:
/dev/md1:
 Timing cached reads:   522 MB in  2.00 seconds = 260.60 MB/sec
 Timing buffered disk reads:  368 MB in  3.02 seconds = 122.01 MB/sec


I have not had good luck with the PATA(MB) to SATA(disk) adaptors. I also have a Via-based PCI SATA adaptor, and it leaves much to be desired (at least in a via motherboard).
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Fri Oct 02, 2009 12:15 am    Post subject: Reply with quote

drescherjm ... the write speed are OK for me. Only read is a problem. And about the Sata chipset, it is also perfectly ok: when I plug my Seagate drive, I have ~65%/s in both ways. About the RAM, it's BIOS settings problem.

eccerr0r

Quote:
dhp@moon-gen-3:~$ lspci
00:00.0 Host bridge: Silicon Integrated Systems [SiS] 735 Host (rev 01)
00:01.0 PCI bridge: Silicon Integrated Systems [SiS] Virtual PCI-to-PCI bridge (AGP)
00:02.0 ISA bridge: Silicon Integrated Systems [SiS] SiS85C503/5513 (LPC Bridge)
00:02.1 SMBus: Silicon Integrated Systems [SiS] SiS961/2 SMBus Controller
00:02.2 USB Controller: Silicon Integrated Systems [SiS] USB 1.1 Controller (rev 07)
00:02.3 USB Controller: Silicon Integrated Systems [SiS] USB 1.1 Controller (rev 07)
00:02.5 IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE] (rev d0)
00:02.7 Multimedia audio controller: Silicon Integrated Systems [SiS] AC'97 Sound Controller (rev a0)
00:09.0 VGA compatible controller: nVidia Corporation NV5M64 [RIVA TNT2 Model 64/Model 64 Pro] (rev 15)
00:0b.0 VGA compatible controller: Matrox Graphics, Inc. MGA 2064W [Millennium] (rev 01)
00:0d.0 VGA compatible controller: Matrox Graphics, Inc. MGA 2064W [Millennium] (rev 01)
00:0f.0 Ethernet controller: Intel Corporation 82557/8/9/0/1 Ethernet Pro 100 (rev 08)
00:11.0 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller (rev 62)
00:11.1 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller (rev 62)
00:11.2 USB Controller: VIA Technologies, Inc. USB 2.0 (rev 65)
00:11.3 RAID bus controller: VIA Technologies, Inc. VT6421 IDE RAID Controller (rev 50)

01:00.0 VGA compatible controller: nVidia Corporation NV6 [Vanta/Vanta LT] (rev 11)
dhp@moon-gen-3:~$


It's an all in one card: USB2-PATA-SATA ... on standard old PCI bus.

> The DMA errors would indicate something is corrupting transfers. Since a corrupted transfer needs a re-do, you would lose throughput.

why would this happen only when reading and not writing ? how do you think i can solve this ?

don't forget that ... on the same SATA card, with the same SATA cable and power adapter i get acceptable rates (65M/s is acceptable to me compared to 4M). Just switched from Seagate to WD and ... blam. Both are 1TB (or, all 3 to be exactc :D one seagate and two WD).

(edited by DoubleHP for Cyker :D )
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png


Last edited by doublehp on Sun Oct 04, 2009 1:47 pm; edited 3 times in total
Back to top
View user's profile Send private message
drescherjm
Advocate
Advocate


Joined: 05 Jun 2004
Posts: 2780
Location: Pittsburgh, PA, USA

PostPosted: Fri Oct 02, 2009 1:07 am    Post subject: Reply with quote

Does the drive have a jumper to fix it to SATA 1 mode? It may be trying to read at SATA2 speed confusing your SATA1 controller.
_________________
John

My gentoo overlay
Instructons for overlay
Back to top
View user's profile Send private message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Fri Oct 02, 2009 8:23 pm    Post subject: Reply with quote

Do you think my controller is Sata 1 ?

the selector has 8 pins; the labbel ABOVE the disk mentions 3 positions:
- SSC (spread spectrum clocking)
- PUS (power up in stand by)
- 1.5 GB PHY

so ... finally, nobody can help me ?
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7525
Location: almost Mile High in the USA

PostPosted: Fri Oct 02, 2009 8:46 pm    Post subject: Reply with quote

Yes it's worth to change it.

I recall that my VIA PCI SATA board also uses VT6421, and it's SATA-1.5.

doublehp wrote:

> The DMA errors would indicate something is corrupting transfers. Since a corrupted transfer needs a re-do, you would lose throughput.

why would this happen only when reading and not writing ? how do you think i can solve this ?

There's more to a piece of wire than a piece of wire... The hardware on the drive may not be compatible with the hardware on the controller board. In this case you may be SOL and look for another PCI SATA bridge...

I'm tempted to toss my POS VIA board. Should have gotten an Silicon Image board, or even a venerable JMicron.
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Fri Oct 02, 2009 9:20 pm    Post subject: Reply with quote

Ok, I did not understand your card was 1.5 and that we have the same one :) (I am very tired at night when I switch my desktop on).

So, change what ? ask the kernel to tell the HDD to reduce compatibility ? ask the card to tell the drive to use an older proto(maybe down to 1.0 ?) ? change the card ?

No i cant change the card; I need a USB-SATA card (no more free PCI slot).

Can I tell the card to limit to 1.0 and hope that the drive will also restrict to 1.0 ?

Your message now explains very well why the upload (host to drive) works fine while the download (reading the plates) has bugs.

Do you mean I should report a bug to WD to tell them their drive are crap ?

So, I do not have a solution/fix yet, but at least, you made me understand where the problem seem to be. Many thanks for this.
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png
Back to top
View user's profile Send private message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Fri Oct 02, 2009 9:49 pm    Post subject: Reply with quote

Found an alternative: on IDE port of the card, I put an IDE-SATA adapter; there, the WD can work at 53M/s. This is acceptable rate to me.

Other idea: on the Sata port, I put a SATA>IDE adapter, then IDE>Sata, then the WD HDD. In this configuration, the disk is not detected at all (unless I misplugged somehing; i will unplug and replug everything tomorrow).

So, I am happy that the drive itself is NOT faulty. And this test confirms your idea that it's a SATA protocol version problem.
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 45793
Location: 56N 3W

PostPosted: Fri Oct 02, 2009 9:52 pm    Post subject: Reply with quote

Code:
Oct  1 02:02:08 moon-gen-3 ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
Oct  1 02:02:08 moon-gen-3 ata1.00: configured for UDMA/33


Shows that the SATA link is SATA1. Your drives will be SATA2 as they are new.

SATA2 is supposed to fall back to SATA1 but often the autofallback is broken. the result is a lot of UDMA errors as the data link from the drive to the chipset is unreliable. It results in very low data rates, normally both ways.

Most SATA2 drives have a very small jumper to force SATA1 operation. I suspect you need to set this jumper.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7525
Location: almost Mile High in the USA

PostPosted: Fri Oct 02, 2009 9:52 pm    Post subject: Reply with quote

I don't have the same card but have the same chipset. Due to past experience with Via products, I now have a strong tendency to spite them. Rarely do I get a decent Via product, they've all had some sort of issue with them. (I also am starting to hate Genesys Logic as well, but some of their stuff does work allright.)

The suggestion is to change your SATA disk to limit its protocol to SATA 1.5GHz, some SATA disks have it as a jumper (as it seems in your case) else it will need to be done in firmware with a manufacturer utility (in the case of some Hitachi drives). If that doesn't work, it sounds like you'll need to get a slower USB connection since you can't change your PCI card. I've not had very good luck with PATA board-SATA disk adapters as above, but you may want to try it. (the other way around has been better for me, but doesn't apply in your case...)
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Fri Oct 02, 2009 10:10 pm    Post subject: Reply with quote

I dont see any "hidden" jumper. Do you think that "1.5GB PHY" was a typo meaning v1.5 or 1.5GHz or 1.5Gb ? 1.5GB sounded to me an "old BIOS compatibility feature"; 1.5G byte as a speed makes no sens to me; 1.5Gb as size limit makes no sens, but 1.5Gb as speed limit WOULD make sens !!! Do you think they put a cap instead of lower case by mistake ?

I ll put a jumper on corresponding pins, and report tomorrow.

Thanks for help; at last I see an exit and some light :) see you later :) Good night :) (and I ll report before 48h anyway).
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png
Back to top
View user's profile Send private message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Fri Oct 02, 2009 10:22 pm    Post subject: Reply with quote

I have put a jumper on "position" "1.5GB PHY" ... and ...

Code:
moon-gen-3 ~ # hdparm -tT /dev/sdb

/dev/sdb:
 Timing cached reads:   310 MB in  2.00 seconds = 154.77 MB/sec
 Timing buffered disk reads:   20 MB in  3.43 seconds =   5.83 MB/sec
moon-gen-3 ~ # hdparm -tT /dev/sda

/dev/sda:
 Timing cached reads:   310 MB in  2.01 seconds = 154.43 MB/sec
 Timing buffered disk reads:   16 MB in  3.75 seconds =   4.27 MB/sec
moon-gen-3 ~ #


Could the problem be linked to the fact I use a Molex power adaptor ? this means ... the drives only have +5 and +12, no +3.3.
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png
Back to top
View user's profile Send private message
drescherjm
Advocate
Advocate


Joined: 05 Jun 2004
Posts: 2780
Location: Pittsburgh, PA, USA

PostPosted: Fri Oct 02, 2009 11:27 pm    Post subject: Reply with quote

Quote:
Could the problem be linked to the fact I use a Molex power adaptor ? this means ... the drives only have +5 and +12, no +3.3.


Doubtful. I have dozens of SATA drives at work using adaptors mainly because my servers have 8 to 20 drives in them and single power suppiles generally do not have that many connectors.
_________________
John

My gentoo overlay
Instructons for overlay
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 45793
Location: 56N 3W

PostPosted: Sat Oct 03, 2009 7:07 pm    Post subject: Reply with quote

doublehp,

The 1.5Gbs is the data rate on the SATA interface. SATA1, uses 1.5Gbps, SATA2 uses 3.Gbps.
Your controller can only do SATA1 and the drives appear to not fall back properly.

Searching goole, I've found a mention of a jumper but I've not found any images.
Time for an email to WD support to ask about SATA1 compatibility.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
drescherjm
Advocate
Advocate


Joined: 05 Jun 2004
Posts: 2780
Location: Pittsburgh, PA, USA

PostPosted: Sat Oct 03, 2009 8:34 pm    Post subject: Reply with quote

This is a little frustrating to me because I had one of those 1TB WG green drives in my hand on Monday of this week. If the machine was not already in production I would open it up and look..
_________________
John

My gentoo overlay
Instructons for overlay
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 45793
Location: 56N 3W

PostPosted: Sat Oct 03, 2009 9:48 pm    Post subject: Reply with quote

doublehp,

eueaka! heres the page you need. Jumper the drive for 1.5Gbps operation.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7525
Location: almost Mile High in the USA

PostPosted: Sat Oct 03, 2009 10:09 pm    Post subject: Reply with quote

honestly this is very weird, if the disk is jumperred to SATA-1.5 hopefully that's out of the equation now. Curious what the virtual "DMA" settings are from hdparm -iv ... though I don't think those results mean much. When I was running my sata disks in pio emulation, performance really stunk. But I doubt this is the case here as the Seagate should also suffer.

Sorry I'm not seeing the problem seen here, when I was trying to use my Via SATA card with my SATA disks I simply could not maintain a stable connection, with lots of dropped packets and pitiful performance... I pretty much gave up on Via.
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
doublehp
Guru
Guru


Joined: 11 Apr 2005
Posts: 472
Location: FRANCE

PostPosted: Sat Oct 03, 2009 10:13 pm    Post subject: Reply with quote

NeddySeagoon not really eureka; your website is exactly what's written on the labbel of the disk ... except that your web site do NOT have the typo: "1.5Gb" instead of the confusing "1.5GB". And, as I said previously, putting a jumper there does NOT solve my problem (Fri Oct 02, 2009 10:22 pm GMT+2 for me).
_________________
DEMAINE Benoît-Pierre (aka DoubleHP ) http://www.demaine.info/
>o_/ Coin coin coin \_o<
to contact me (MSN,ICQ, JABBER, Skype ... ) http://benoit.demaine.info/contact.png
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 45793
Location: 56N 3W

PostPosted: Sat Oct 03, 2009 10:37 pm    Post subject: Reply with quote

doublehp,

Sorry, I must have skimmed over your post. I'm out of ideas
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Cyker
Veteran
Veteran


Joined: 15 Jun 2006
Posts: 1746

PostPosted: Sun Oct 04, 2009 10:06 am    Post subject: Reply with quote

Stupid question;

You say you're using a PCI card to get SATA support; What chipset does it use and what drivers are you using?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum