歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> Linux教程 >> 在RedHat Linux下IDE硬盤的加速

在RedHat Linux下IDE硬盤的加速

日期:2017/2/28 18:01:51   编辑:Linux教程
默認中RedHat Linux將IDE硬盤配置得非常穩定,非常兼容,換句話來說,就是非常的慢。
  如果你的IDE硬盤是最近幾年,特別注明是支持UltraDMA模式的,可以通過修改配置文件輕而易舉地使得你的IDE硬盤加速它的運行。
  編輯/etc/sysconfig/harddisks, 修改自己的IDE硬盤(注:對SCSI硬盤無效)。紅色字體是修改後的參數:
#
# WARNING !!!
#
# The kernel will autodetect the correct settings for most drives.
# Overriding these settings with hdparm can cause data corruption and/or
# data loss.
# Leave this file as it is unless you know exactly what you're doing !!
#
#
#
# These options are used to tune the hard drives -
# read the hdparm man page for more information
# Set this to 1 to enable DMA. This might cause some
# data corruption on certain chipset / hard drive
# combinations. This is used with the "-d" option
USE_DMA=1 (這不用再說明了吧?)
# Multiple sector I/O. 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%. Some drives, however (most
# notably the WD Caviar series), seem to run slower with multiple mode
# enabled. Under rare circumstances, such failures can result in
# massive filesystem corruption. USE WITH CAUTION AND BACKUP.
# This is the sector count for multiple sector I/O - the "-m" option
#
MULTIPLE_IO=16 (這個以前叫multcount, 多少sector能在一次輸入/輸出中斷中被校入)
# (E)IDE 32-bit I/O support (to interface card)
#
EIDE_32BIT=3 (打開這個是非常重要的,幾乎可以提速一倍)
# Enable drive read-lookahead
#
LOOKAHEAD=1 (沒什麼話好說的,個人覺得都無所謂)
# Add extra parameters here if wanted
# On reasonably new hardware, you may want to try -X66, -X67 or -X68
# Other flags you might want to experiment with are -u1, -a and -m
# See the hdparm manpage (man hdparm) for details and more options.
#
EXTRA_PARAMS= -X66 -u1 (這裡的選項很危險,要根據自己的情況填入。請先用/sbin/hdparm 命令確認這些選項不會危害到你的IDE硬盤,再將它們寫入這裡。
  其實上面的參數都可以用hdparm來調整,但系統是不會記住hdparm調整後的參數的。所以每次開機又會回到默認的配置。修改/etc/sysconfig/harddisks文件是為了方便,用戶也可以將hdparm的選項寫入rc.sysinit。仁者見仁了。
Copyright © Linux教程網 All Rights Reserved