Ubuntu系統(tǒng)運(yùn)行時(shí)降低硬盤(pán)占用的相關(guān)嘗試

如果返回
APM_level的全稱(chēng)為Advanced Power Management level,即(硬盤(pán))高級(jí)電源管理級(jí)別.
man hdparm 可見(jiàn):
Get/set Advanced Power Management feature, if the drive supports it.
A low value means aggressive power management and a high value means better performance.
Possible settings range from values 1 through 127 (which permit spin-down), and values 128 through 254 (which do not permit spin-down).
The highest degree of power management is attained with a setting of 1, and the highest I/O performance with a setting of 254.
A value of 255 tells hdparm to disable Advanced Power Management altogether on the drive (not all drives support disabling it, but most do).
該值的取值范圍為1~255,值越大,硬盤(pán)性能越高,其中255表示關(guān)閉硬盤(pán)/dev/sda的電源管理,254表示在開(kāi)啟電源管理下的最高性能,1表示最低的硬盤(pán)性能但最省電.
這個(gè)值在1~127區(qū)間時(shí)允許spin-down,在128~254這個(gè)區(qū)間則禁止spin-down.
spin-down是指在閑置時(shí)掛起硬盤(pán),停止轉(zhuǎn)動(dòng),但是頻繁的spin-down和spin-up會(huì)使硬盤(pán)壽命變短.
所以,即使你追求節(jié)能,減少發(fā)熱量,也建議你將該值設(shè)為128,執(zhí)行以下命令即可:
我的操作系統(tǒng)為Ubuntu 14.04(Kernel 3.14),我把該值設(shè)為128,在氣溫26度的情況下,硬盤(pán)溫度僅為36度(對(duì)比:此時(shí)CPU溫度為39度).

如果設(shè)為254,硬盤(pán)溫度甚至?xí)噬?5度,雖然這仍是一個(gè)正常的硬盤(pán)溫度,但對(duì)于筆記本用戶(hù)來(lái)說(shuō),靠近硬盤(pán)處的發(fā)熱量是很容易察覺(jué)到的.
另外電機(jī)持續(xù)高速的旋轉(zhuǎn)也會(huì)加快減少硬盤(pán)的壽命.
在性能和節(jié)能間做個(gè)折中,個(gè)人把APM_level設(shè)為192,讓其開(kāi)機(jī)自動(dòng)設(shè)置,在/etc/rc.local中加入:
如果/etc/rc.local不生效,可以在/etc/hdparm.conf中加入:
apm = 192
apm_battery = 192
}
apm表示在交流電供電模式下, apm_battery表示在電池供電模式下.
注意: 設(shè)置APM后執(zhí)行以下命令查看Load_Cycle_Count值
如果Load_Cycle_Count值每分鐘都在增加,這時(shí)你應(yīng)該把APM值設(shè)回原來(lái)的254,方法同上可以在/etc/hdparm.conf里修改.
執(zhí)行命令
因?yàn)榇蓬^頻繁的Load/Unload同樣會(huì)影響硬盤(pán)壽命,一般硬盤(pán)設(shè)計(jì)能承受的加載循環(huán)計(jì)數(shù)Load_Cycle_Count最多為600000次.
相關(guān)文章
在Ubuntu系統(tǒng)上使用LVM調(diào)整硬盤(pán)分區(qū)的示例
這篇文章主要介紹了在Ubuntu系統(tǒng)上使用LVM調(diào)整硬盤(pán)分區(qū)的示例,LVM可以實(shí)現(xiàn)圖形化操作和顯示,需要的朋友可以參考下2015-09-21Ubuntu系統(tǒng)上使用LVM調(diào)整硬盤(pán)分區(qū)的教程
這篇文章主要介紹了Ubuntu系統(tǒng)上使用LVM調(diào)整硬盤(pán)分區(qū)的教程,操作基于圖形化界面完成,需要的朋友可以參考下2015-09-15- Ubuntu15.04桌面操作系統(tǒng)怎么安裝?有兩種安裝方法,可以下載Ubuntu15.04 ISO鏡像安裝,也可以通過(guò)Virtualbox新建好了一個(gè)虛擬機(jī)安裝,下面分享詳細(xì)的安裝方法,需要的朋友2015-08-20