LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
LinkBack Search this Thread
Old 07-01-2005, 11:46 PM   #1
ch_music
Member
 
Registered: Apr 2004
Location: Singapore
Distribution: Debian Sarge/Sid
Posts: 52

Rep: Reputation: 15
Slow PATA Performance


Hi,

I have 2 harddrive: maxtor 60GB (/dev/hda, master) and seagate 20GB (/dev/hdb, slave) connected by Parallel ATA (ide0) and another harddrive: maxtor 120GB (/dev/hde) connected by SATA (ide2). In addition to that, /dev/hdc is CDRW and /dev/hdd is DVDRW. My motherboard runs on nForce2 chipset.

Currently I'm getting very slow performance on /dev/hda (but not /dev/hdb and /dev/hde). I have enabled DMA to no avail. Here's the information churned out by my computer (/dev/hdb and /dev/hde is given as reference).

# hdparm -Tt /dev/hda
/dev/hda:
Timing cached reads: 1560 MB in 2.00 seconds = 779.73 MB/sec
Timing buffered disk reads: 4 MB in 8.92 seconds = 459.01 kB/sec #This reading varies between 400kB/s to 700kB/s which is unacceptably slow

# hdparm /dev/hda
/dev/hda:
multcount = 16 (on)
IO_support = 1 (32-bit)
unmaskirq = 1 (on)
using_dma = 1 (on)
keepsettings = 0 (off)
readonly = 0 (off)
readahead = 256 (on)
geometry = 65535/16/63, sectors = 120103200, start = 0

# hdparm -i /dev/hda
/dev/hda:
Model=Maxtor 6Y060L0, FwRev=YAR41BW0, SerialNo=Y2SXS03E
Config={ Fixed }
RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=57
BuffType=DualPortCache, BuffSize=2048kB, MaxMultSect=16, MultSect=16
CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=120103200
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: (null):
* signifies the current active mode


Reading of /dev/hdb:

# hdparm -Tt /dev/hdb
/dev/hdb:
Timing cached reads: 1408 MB in 2.00 seconds = 702.35 MB/sec
Timing buffered disk reads: 66 MB in 3.06 seconds = 21.56 MB/sec

# hdparm /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 = 256 (on)
geometry = 39761/16/63, sectors = 40079088, start = 0

#hdparm -i /dev/hdb
/dev/hdb:
Model=ST320430A, FwRev=3.11, SerialNo=7BX0A09R
Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs RotSpdTol>.5% }
RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=0
BuffType=unknown, BuffSize=512kB, MaxMultSect=16, MultSect=16
CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=40079088
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
AdvancedPM=no WriteCache=enabled
Drive conforms to: device does not report version: 1 2 3 4
* signifies the current active mode

Reading from /dev/hde:

# hdparm -Tt /dev/hde
/dev/hde:
Timing cached reads: 1500 MB in 2.00 seconds = 750.11 MB/sec
Timing buffered disk reads: 160 MB in 3.01 seconds = 53.22 MB/sec

# hdparm /dev/hde
/dev/hde:
multcount = 16 (on)
IO_support = 0 (default 16-bit)
unmaskirq = 0 (off)
using_dma = 1 (on)
keepsettings = 0 (off)
readonly = 0 (off)
readahead = 256 (on)
geometry = 65535/16/63, sectors = 240121728, start = 0

# hdparm -i /dev/hde
/dev/hde:
Model=Maxtor 6Y120M0, FwRev=YAR511W0, SerialNo=Y3NYTLTE
Config={ Fixed }
RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=4
BuffType=DualPortCache, BuffSize=7936kB, MaxMultSect=16, MultSect=16
CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=240121728
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=yes: disabled (255) WriteCache=enabled
Drive conforms to: (null):
* signifies the current active mode

PCI reading:

# lspci | grep IDE
0000:00:09.0 IDE interface: nVidia Corporation nForce2 IDE (rev a2)

#dmesg
...
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
NFORCE2: IDE controller at PCI slot 0000:00:09.0
NFORCE2: chipset revision 162
NFORCE2: not 100% native mode: will probe irqs later
NFORCE2: BIOS didn't set cable bits correctly. Enabling workaround.
NFORCE2: 0000:00:09.0 (rev a2) UDMA133 controller
ide0: BM-DMA at 0xf000-0xf007, BIOS settings: hdaMA, hdbMA
ide1: BM-DMA at 0xf008-0xf00f, BIOS settings: hdcMA, hddMA
Probing IDE interface ide0...
hda: Maxtor 6Y060L0, ATA DISK drive
hdb: ST320430A, ATA DISK drive
ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
Probing IDE interface ide1...
hdc: TDK CDRW401248B, ATAPI CD/DVD-ROM drive
hdd: TSSTcorpCD/DVDW TS-H552U, ATAPI CD/DVD-ROM drive
ide1 at 0x170-0x177,0x376 on irq 15
SiI3112 Serial ATA: IDE controller at PCI slot 0000:01:05.0
SiI3112 Serial ATA: chipset revision 1
SiI3112 Serial ATA: 100% native mode on irq 11
ide2: MMIO-DMA , BIOS settings: hdeio, hdfio
ide3: MMIO-DMA , BIOS settings: hdgio, hdhio
Probing IDE interface ide2...
hde: Maxtor 6Y120M0, ATA DISK drive
ide2 at 0xe081c080-0xe081c087,0xe081c08a on irq 11
hda: max request size: 128KiB
hda: 120103200 sectors (61492 MB) w/2048KiB Cache, CHS=65535/16/63, UDMA(133)
hda: cache flushes supported
hda: hda1 hda2 hda3 hda4 < hda5 hda6 hda7 hda8 hda9 >
hdb: max request size: 128KiB
hdb: 40079088 sectors (20520 MB) w/512KiB Cache, CHS=39761/16/63, UDMA(33)
hdb: cache flushes not supported
hdb: hdb1 hdb2 hdb3
hde: max request size: 64KiB
hde: 240121728 sectors (122942 MB) w/7936KiB Cache, CHS=65535/16/63
hde: cache flushes supported
hde: hde1 hde2 hde3 hde4 < hde5 hde6 hde7 hde8 >
hdc: ATAPI 48X CD-ROM CD-R/RW drive, 2048kB Cache, UDMA(33)
Uniform CD-ROM driver Revision: 3.20
hdd: ATAPI 48X DVD-ROM DVD-R CD-R/RW drive, 2048kB Cache, UDMA(33)


The driver for IDE is compiled directly into kernel, not as module, otherwise DMA can't be turned on (the module's name, when compiled as module, is, I think, amd7xxx).

Any help will be greatly appreciated. Thank you very much.

cHeers.
Chris
 
Old 07-20-2005, 09:55 AM   #2
BrianWarner
LQ Newbie
 
Registered: Jul 2005
Posts: 2

Rep: Reputation: 0
I've got the same problem, also on NForce2 Mobo running FC4

80 gig maxtor on hda udma5
160 gig samsung on hdb udma6
160 gig samsung on sda (usb2.0)

all 3 drives show over 1100 MB/sec thru cache reads
through buffered reads
hda 718 kB/sec
hdb 58.93 MB/sec
sda 29.59 MB/sec

I can't figure out why the little maxtor has problems reading, it seems to read a bit and then lag for awhile, I've changed all the hdparm flags, only thing that helped a little was to set -A0 to turn off the drives read_ahead and set -a 1024 (reads 512KB ahead) and that only bumped the speed up to around 2 MB/sec

doesn't seem to be a dma, unmaskirq, acoustic, spindown, or power management problem

Anyone out there have a fix?
 
Old 07-20-2005, 11:10 AM   #3
BrianWarner
LQ Newbie
 
Registered: Jul 2005
Posts: 2

Rep: Reputation: 0
okay, kinda got rid of the long delay between reads, still takes firefox over 20 seconds to load but now the menu's in kde and everything are filled in under 3 seconds (big improvement)

try this /sbin/hdparm -m 16 -c 3 -u 1 -d 0 -A 1 -a 256 /dev/hda

I'm up to getting 6.7 MB/sec so it's alot better than the 100-700 k
good luck
 
Old 07-20-2005, 11:18 AM   #4
ch_music
Member
 
Registered: Apr 2004
Location: Singapore
Distribution: Debian Sarge/Sid
Posts: 52

Original Poster
Rep: Reputation: 15
Nope, no luck. But I use dirty trick to make the app faster. I move /usr /home /var /tmp partitions to the faster harddrive. Then you'll not have performance problems anymore.

I've made sure it's not connections problem. Tried with PATA in channel ide0 with slave, without slave, alone in ide2, still no luck. I think getting a new PATA controller (which is quite cheap nowadays) may solve the problem. But for now, copying most partitions to another harddrive gave the performance boost that I need.

And yeah, the harddrive is currently underused. I put my windows xp there, which seems to have little problem with slow performance. Never really tested it though, I haven't been in Windows for quite sometime... =)

cHeers.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
slow disk performance oldi *BSD 1 08-02-2004 11:11 PM
Slow performance satinet Slackware 9 06-15-2004 05:54 PM
slow performance dominant Linux - Newbie 20 03-16-2004 10:56 AM
Very slow performance with RH8.0 cihans Linux - General 9 02-08-2003 02:44 AM
Slow SCSI hd performance Half_Elf Linux - General 2 12-25-2002 09:00 PM


All times are GMT -5. The time now is 09:58 AM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration