I noticed hdparm is able to change the acoustic management value of HD (-Y flag) and my HD (IBM 60GXP 40 GB) is able to report it's temperature (I use hddtemp), so I decided it could be neat to have a script to set the HDspeed automatically, for example every 15 minutes.

Unfortunately, I have never wrote scripts that deal with strings and I'm not able to extract the value of temperature and system load.
hddtemp report this: "/dev/hda: IC350L40AVER07-0: 42�C"
and /proc/loadavg: 0.005 0.02 0.01 xxxxxx".


I'd like to extract the temperature ("42") and the third value of system load (if I remember correctly, the first refers to the first minute, the second to 5 minutes and the third 15 minutes).

I tried sed and gawk but without success.

THX
Olaf



Want to buy your Pack or Services from MandrakeSoft? 
Go to http://www.mandrakestore.com

Reply via email to