Results 1 to 17 of 17
  1. #1
    Join Date
    Jun 2002
    Posts
    44

    Improving Hard Drive Performance

    anyone knows how to improve my hd


    [email protected] [/]# hdparm -t /dev/sda

    /dev/sda:
    Timing buffered disk reads: 64 MB in 6.02 seconds = 10.63 MB/sec
    [email protected] [/]# hdparm -t /dev/sda

    /dev/sda:
    Timing buffered disk reads: 64 MB in 5.44 seconds = 11.76 MB/sec
    [email protected] [/]# hdparm -t /dev/sda

    /dev/sda:
    Timing buffered disk reads: 64 MB in 6.15 seconds = 10.41 MB/sec
    [email protected] [/]# hdparm -t /dev/sda

    /dev/sda:
    Timing buffered disk reads: 64 MB in 5.95 seconds = 10.76 MB/sec

  2. #2
    Join Date
    Jun 2002
    Posts
    44
    anyone please?

  3. #3
    Join Date
    Feb 2002
    Location
    Philadelphia, PA
    Posts
    96

    What kind of drive?

    Get a faster drive. There isn't anyway to increase teh speed of your hardware, it runs at what it runs at. (please overclocking followers)

    You can however improve I/O performance via defragging, physical and logical stripping, moving as far as possible away from RAID 5 (depending on your controller), setting OS performance parms based on past performance.

    You might want to start at what the manufacturer says the drive should be pumping data. Also, its hard to tell anything from what you posted. You should provide some background about what you did to get those numbers.

  4. #4
    Join Date
    Oct 2002
    Location
    Canada
    Posts
    3,100

  5. #5
    Join Date
    Jun 2002
    Posts
    44
    it's a scsi drive... how could it be that slow???
    there is a discussion at http://forums.rackshack.net/showthre...ghlight=hdparm

    but i am not sure if I can use that command for scsi drives.



    [email protected] [/proc/scsi]# cat /proc/scsi/scsi
    Attached devices:
    Host: scsi0 Channel: 00 Id: 00 Lun: 00
    Vendor: QUANTUM Model: ATLAS IV 36 SCA Rev: 0B0B
    Type: Direct-Access ANSI SCSI revision: 03
    [email protected] [/proc/scsi]# dmesg |grep hd
    ide0: BM-DMA at 0xd000-0xd007, BIOS settings: hda:pio, hdb:pio
    ide1: BM-DMA at 0xd008-0xd00f, BIOS settings: hdc:pio, hdd:pio
    SCSI device sda: 71770336 512-byte hdwr sectors (36746 MB)

  6. #6
    try turning on UDMA if there is any. My IDE7200 gives 45mb/s.
    Powered by AMD & FreeBSD.
    "Documentation is like sex:
    when it is good, it is very, very good;
    and when it is bad, it is better than nothing."

  7. #7
    Join Date
    Jun 2002
    Posts
    44
    Originally posted by Miha
    try turning on UDMA if there is any. My IDE7200 gives 45mb/s.
    [email protected] [/]# hdparm -v /dev/sda

    /dev/sda:
    readonly = 0 (off)
    geometry = 35044/64/32, sectors = 71770336, start = 0

    I just don't know how to fix it... :p

  8. #8
    Join Date
    Aug 2002
    Location
    Long Island
    Posts
    427
    SCSI isn't always the fastest; I love SCSI and always go with it. It's more reliable and if you get 10k or 15k drives with a raid 5 with enough drives you can really rock the data...

    Not sure what c3r3br0 said about RAID5, do you like it or not? I simply like the fact that I can sleep at night without worrying about the phone ringing.
    John Trovato
    In Office Networks, LLC
    Programmer, Cisco Network Engineer, Roofer, Biochemist, and Conductor.

  9. #9
    Join Date
    Mar 2002
    Location
    London & Kent, UK
    Posts
    372
    First, use:

    hdparm -i

    e.g.

    [email protected]:/home/nick > hdparm -i /dev/hda

    /dev/hda:

    Model=IBM-DTLA-307015, FwRev=TX2OA50C, SerialNo=YF0YFT00541
    Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs }
    RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=40
    BuffType=3(DualPortCache), BuffSize=1916kB, MaxMultSect=16, MultSect=off
    DblWordIO=no, OldPIO=2, DMA=yes, OldDMA=2
    CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=30003120
    tDMA={min:120,rec:120}, DMA modes: mword0 mword1 mword2
    IORDY=on/off, tPIO={min:240,w/IORDY:120}, PIO modes: mode3 mode4
    UDMA modes: mode0 mode1 mode2 mode3 *mode4 mode5
    Drive Supports : Reserved : ATA-2 ATA-3 ATA-4 ATA-5

    UDMA mode is supported by drive and chipset, so then:

    hdparm -d 1

    and then use hdparm -t -T to test.

    e.g.

    [email protected]:/home/nick > hdparm -d 0 /dev/hda

    /dev/hda:
    setting using_dma to 0 (off)
    using_dma = 0 (off)
    [email protected]:/home/nick > hdparm -t -T /dev/hda

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 0.81 seconds =158.02 MB/sec
    Timing buffered disk reads: 64 MB in 16.81 seconds = 3.81 MB/sec
    [email protected]:/home/nick > hdparm -d 1 /dev/hda

    /dev/hda:
    setting using_dma to 1 (on)
    using_dma = 1 (on)
    [email protected]:/home/nick > hdparm -t -T /dev/hda

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 0.81 seconds =158.02 MB/sec
    Timing buffered disk reads: 64 MB in 1.82 seconds = 35.16 MB/sec
    [email protected]:/home/nick >

    Good luck!
    Real-time intrusion protection and error reporting for PHP sites ioncube24.com
    Software protection for website owners and PHP developers ionCube PHP Encoder

  10. #10
    Join Date
    Jun 2002
    Posts
    44
    I think this instruction is used for IDE drives only.


    Originally posted by phpa
    First, use:

    hdparm -i

    e.g.

    [email protected]:/home/nick > hdparm -i /dev/hda

    /dev/hda:

    Model=IBM-DTLA-307015, FwRev=TX2OA50C, SerialNo=YF0YFT00541
    Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs }
    RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=40
    BuffType=3(DualPortCache), BuffSize=1916kB, MaxMultSect=16, MultSect=off
    DblWordIO=no, OldPIO=2, DMA=yes, OldDMA=2
    CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=30003120
    tDMA={min:120,rec:120}, DMA modes: mword0 mword1 mword2
    IORDY=on/off, tPIO={min:240,w/IORDY:120}, PIO modes: mode3 mode4
    UDMA modes: mode0 mode1 mode2 mode3 *mode4 mode5
    Drive Supports : Reserved : ATA-2 ATA-3 ATA-4 ATA-5

    UDMA mode is supported by drive and chipset, so then:

    hdparm -d 1

    and then use hdparm -t -T to test.

    e.g.

    [email protected]:/home/nick > hdparm -d 0 /dev/hda

    /dev/hda:
    setting using_dma to 0 (off)
    using_dma = 0 (off)
    [email protected]:/home/nick > hdparm -t -T /dev/hda

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 0.81 seconds =158.02 MB/sec
    Timing buffered disk reads: 64 MB in 16.81 seconds = 3.81 MB/sec
    [email protected]:/home/nick > hdparm -d 1 /dev/hda

    /dev/hda:
    setting using_dma to 1 (on)
    using_dma = 1 (on)
    [email protected]:/home/nick > hdparm -t -T /dev/hda

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 0.81 seconds =158.02 MB/sec
    Timing buffered disk reads: 64 MB in 1.82 seconds = 35.16 MB/sec
    [email protected]:/home/nick >

    Good luck!

  11. #11
    Join Date
    Mar 2002
    Location
    London & Kent, UK
    Posts
    372
    Yes, apologies for that, you're right. I wasn't looking closely enough.

    Mind you, worth noting for the IDE folks as linux setups usually don't enable UDMA by default.

    What's really lame is that one dedicated host provider I use advertise UDMA drives on their machines, and they are indeed, but again don't enable this in the setup. So you get sucky performance. I pointed this out when changing the setup and they said that they didn't like hdparm (read don't understand it?) and that I might violate my support contract if I use it. Hmm, I think not.

    I used it of course and have 432 days uptime without problems and still going strong as one would expect.
    Real-time intrusion protection and error reporting for PHP sites ioncube24.com
    Software protection for website owners and PHP developers ionCube PHP Encoder

  12. #12
    Join Date
    Jun 2002
    Posts
    44
    I bought this server from nocster btw... sent them a ticket about this issue but haven't got any answers yet?

  13. #13
    Join Date
    Jul 2002
    Location
    England
    Posts
    348
    Admiutedly... i didn't knwo about that.... and just tried it on my crappy test server (P166, 32Mb ram etc..) and it increased HDD performance by a whopping 220%!!!

    Does this cause any damage to the drive etc... or is just how data is controlled?

  14. #14
    Join Date
    Nov 2002
    Location
    Toronto, ON
    Posts
    441
    its just using features of the hardware it wasn't using before
    http://www.spingen.com :: Internet Solutions
    Multiple Domain Hosting Packages
    msn: [email protected]

  15. #15
    Join Date
    Jul 2002
    Location
    England
    Posts
    348
    On my test server...

    Before enabling uDMA:

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 3.77 seconds = 33.95 MB/sec
    Timing buffered disk reads: 64 MB in 25.45 seconds = 2.51 MB/sec

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 3.76 seconds = 34.04 MB/sec
    Timing buffered disk reads: 64 MB in 25.54 seconds = 2.51 MB/sec

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 3.76 seconds = 34.04 MB/sec
    Timing buffered disk reads: 64 MB in 25.56 seconds = 2.50 MB/sec


    After enabling:

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 3.76 seconds = 34.04 MB/sec
    Timing buffered disk reads: 64 MB in 9.68 seconds = 6.61 MB/sec

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 3.76 seconds = 34.04 MB/sec
    Timing buffered disk reads: 64 MB in 9.66 seconds = 6.63 MB/sec

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 3.75 seconds = 34.13 MB/sec
    Timing buffered disk reads: 64 MB in 9.69 seconds = 6.60 MB/sec

    Based on these... increases performance by 220%

  16. #16
    Join Date
    Nov 2002
    Location
    UK
    Posts
    24
    Enabling UDMA on some machines works fine, however on others the following is reported:

    /dev/hda:
    setting using_dma to 1 (on)
    HDIO_SET_DMA failed: Operation not permitted
    using_dma = 0 (off)

    The machines are different hardware, however the machine giving the above message is brand new, so support for UDMA can be assumed - yes?

    I found some articles suggesting that via support wasn't enabled - but this machine has an Intel chipset.

    Can anyone shed any light on this?

    Thanks,
    Andy


    Originally posted by phpa
    First, use:

    hdparm -i

    e.g.

    [email protected]:/home/nick > hdparm -i /dev/hda

    /dev/hda:

    Model=IBM-DTLA-307015, FwRev=TX2OA50C, SerialNo=YF0YFT00541
    Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs }
    RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=40
    BuffType=3(DualPortCache), BuffSize=1916kB, MaxMultSect=16, MultSect=off
    DblWordIO=no, OldPIO=2, DMA=yes, OldDMA=2
    CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=30003120
    tDMA={min:120,rec:120}, DMA modes: mword0 mword1 mword2
    IORDY=on/off, tPIO={min:240,w/IORDY:120}, PIO modes: mode3 mode4
    UDMA modes: mode0 mode1 mode2 mode3 *mode4 mode5
    Drive Supports : Reserved : ATA-2 ATA-3 ATA-4 ATA-5

    UDMA mode is supported by drive and chipset, so then:

    hdparm -d 1

    and then use hdparm -t -T to test.

    e.g.

    [email protected]:/home/nick > hdparm -d 0 /dev/hda

    /dev/hda:
    setting using_dma to 0 (off)
    using_dma = 0 (off)
    [email protected]:/home/nick > hdparm -t -T /dev/hda

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 0.81 seconds =158.02 MB/sec
    Timing buffered disk reads: 64 MB in 16.81 seconds = 3.81 MB/sec
    [email protected]:/home/nick > hdparm -d 1 /dev/hda

    /dev/hda:
    setting using_dma to 1 (on)
    using_dma = 1 (on)
    [email protected]:/home/nick > hdparm -t -T /dev/hda

    /dev/hda:
    Timing buffer-cache reads: 128 MB in 0.81 seconds =158.02 MB/sec
    Timing buffered disk reads: 64 MB in 1.82 seconds = 35.16 MB/sec
    [email protected]:/home/nick >

    Good luck!

  17. #17
    Join Date
    Feb 2002
    Location
    Philadelphia, PA
    Posts
    96

    RAID5 Misconception

    Not sure what c3r3br0 said about RAID5, do you like it or not? I simply like the fact that I can sleep at night without worrying about the phone ringing.

    RAID5's main purpose is not for availablity of disk or redundancy. Never has been and never will be. The point of RAID5 is to be able to string disks together that's pretty much it. Sure you can have a parity and spare's out the wazoo configuration but it will never be more reliable than a mirrored system.

    So why would you use RAID5? They don't make 200GB disks, and mirroring is expensive since there is usually an idle drive.

    ----------------------------

    An Atlas IV has a sustained transfer rate of 13.5 to 21.5MB/sec. The buffer is 2MB, so there should be some cache/read ahead feature that you can enable which will help performance. How old is the drive? What type of controller are you going through?
    Last edited by c3r3br0; 11-20-2002 at 05:08 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •