Page 1 of 6 123 ... LastLast
Results 1 to 10 of 54

Thread: HOW TO: get a free speed boost from your hard drive

  1. #1
    Join Date
    Dec 2004
    Beans
    297

    HOW TO: get a free speed boost from your hard drive

    Warning. The advice contained in this How To is risky. It might destroy your system. You have been warned!

    Many operations on a PC are I/O constrained. In day-to-day operation, my processor rarely reaches 100%, but my hard drive is often struggling to keep up. But, by default, Hoary doesn't use the fastest possible settings for disk access; it's a little safety conscious. On my newish Dell laptop, these tips speed up my hard drive by 60%, noticeably improving system responsiveness. And nothing's crashed... yet.

    First find out how fast your hard drive is. Fire up a terminal end enter
    Code:
    sudo hdparm -t -T /dev/hda
    (Change hda for your own hard drive's device number; if you don't know, you're probably not yet ready for this guide). Do this three times, and note the average result.

    Now we need to understand the drive's capabilities. Use
    Code:
    sudo hdparm -i /dev/hda
    to tell you. If you're really interested, try
    Code:
    sudo hdparm -I /dev/hda
    to get more details.

    First, look for two settings: MultSec and MaxMultSec. According to the manual, "multiple sector mode, is a feature of most modern IDE hard drives, permitting the transfer of multiple sectors per I/O interrupt, rather than the usual one sector per interrupt. When this feature is enabled, it typically reduces operating system overhead for disk I/O by 30-50%. On many systems, it also provides increased data throughput of anywhere from 5% to 50%." Despite this, you'll probably find that MultSec is off, even if it's supported by your drive, as "Some drives claim to support multiple mode, but lose data at some settings. Under rare circumstances, such failures can result in massive filesystem corruption.

    If you're willing to risk it - remember, it may not be wise - enter
    Code:
    sudo hdparm -m <your MaxMultSec value> /dev/hda
    Check out your results again, and enjoy the free performance boost.

    Now it's time to enable 32-bit I/O. In these days of 64 bit processors, it's a shame to have bits of the system pretending they're in the 1980s - but that's what Hoary seems to do to some drives. Establish the position with
    Code:
    sudo hdparm -c /dev/hda
    If the result is 0, you're still in the dark ages. Cross your fingers, and try this:
    Code:
    sudo hdparm -c 3 /dev/hda
    It worked for me. A final speed check showed my hard drive was 60% faster - and it felt it, too. But if it blew away your system's brains... I did warn you.

    Now all I need to do is work out which config file I have to edit to make this happen at boot time. Does anyone know?

  2. #2
    Join Date
    Apr 2005
    Beans
    75

    Re: HOW TO: get a free speed boost from your hard drive

    I can vouch for the second method.

    Before:
    Timing cached reads: 2020 MB in 2.00 seconds = 1008.64 MB/sec
    Timing buffered disk reads: 130 MB in 3.03 seconds = 42.95 MB/sec

    After:
    Timing cached reads: 2532 MB in 2.00 seconds = 1264.93 MB/sec
    Timing buffered disk reads: 148 MB in 3.00 seconds = 49.29 MB/sec

  3. #3
    Join Date
    Dec 2004
    Location
    Utah, USA
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: HOW TO: get a free speed boost from your hard drive

    This had little effect on my laptop, but laptops are a different animal.

    Mike
    Mike: "The hardest questions in life are the ones worth answering"

  4. #4
    Join Date
    Apr 2005
    Beans
    54

    Re: HOW TO: get a free speed boost from your hard drive

    I really suggest against using HDPARM if it is not really necessary. In most of the motherboard, DMA can turn on by using the Bios settings.

    The most concern about using HDPARM is the constant system lock up. If you try to copy large files, you will sometimes experience "/dev/hd* time out" and the HDPARM will return back to DMA=off (even DMA is on in your BIOS) and you will stuck with ~1.4Mb/sec. This is one of many factors that causes system lockups.

    Good luck! if you insist to try.

  5. #5
    Join Date
    Mar 2005
    Beans
    1

    Re: HOW TO: get a free speed boost from your hard drive

    Quote Originally Posted by jonny
    Now all I need to do is work out which config file I have to edit to make this happen at boot time. Does anyone know?
    Check out /etc/hdparm.conf

  6. #6
    Join Date
    Mar 2005
    Beans
    38

    Re: HOW TO: get a free speed boost from your hard drive

    Quote Originally Posted by vnbuddy2002
    I really suggest against using HDPARM if it is not really necessary. In most of the motherboard, DMA can turn on by using the Bios settings.
    My DVD and CD/RW have DMA enabled at boot by most distros, including Warty. Hoary has it disabled, which destroys DVD playback and limits burning to about 16x (52x drive). Quick hack of /etc/hdparm.conf fixes that problem.

  7. #7
    Join Date
    Oct 2004
    Location
    Michigan, USA
    Beans
    158
    Distro
    Ubuntu

    Re: HOW TO: get a free speed boost from your hard drive

    To have your system load hdparm commands at boot, edit the hdparm.conf file.

    For the details search the forums for "hdparm.conf" to find the answer.

    Cheers ...

  8. #8
    Join Date
    Mar 2005
    Location
    Fredericia, DK
    Beans
    204
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: HOW TO: get a free speed boost from your hard drive

    What about SATA disks?
    Are there any differences?

  9. #9
    Join Date
    Oct 2004
    Location
    Mobile, AL, USA
    Beans
    337
    Distro
    Ubuntu 8.10 Intrepid Ibex

    Re: HOW TO: get a free speed boost from your hard drive

    Quote Originally Posted by WMCoolmon
    I can vouch for the second method.

    Before:
    Timing cached reads: 2020 MB in 2.00 seconds = 1008.64 MB/sec
    Timing buffered disk reads: 130 MB in 3.03 seconds = 42.95 MB/sec

    After:
    Timing cached reads: 2532 MB in 2.00 seconds = 1264.93 MB/sec
    Timing buffered disk reads: 148 MB in 3.00 seconds = 49.29 MB/sec
    O_O My drives are incredibly slow compared to yours. Is this normal?

    Code:
    $ sudo hdparm -t -T /dev/hdb
    
    /dev/hdb:
     Timing cached reads:   792 MB in  2.01 seconds = 394.68 MB/sec
     Timing buffered disk reads:  100 MB in  3.00 seconds =  33.28 MB/sec
    $ whatis themeaningoflife
    themeaningoflife: not found

  10. #10
    Join Date
    Apr 2005
    Beans
    54

    Re: HOW TO: get a free speed boost from your hard drive

    Quote Originally Posted by HungSquirrel
    O_O My drives are incredibly slow compared to yours. Is this normal?

    Code:
    $ sudo hdparm -t -T /dev/hdb
    
    /dev/hdb:
     Timing cached reads:   792 MB in  2.01 seconds = 394.68 MB/sec
     Timing buffered disk reads:  100 MB in  3.00 seconds =  33.28 MB/sec
    It seems normal to me. The speed also depends on the speed of your hard drive also. Average hard drive speed for IDE hard drives (7200RPM) is ~ 32.00 Mb/sec (on Mode 2 Ultra ATA).

Page 1 of 6 123 ... LastLast

Bookmarks

Posting Permissions

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