Incoming from Thomas Chadwick: > I recently discovered that I can greatly improve my harddrive performance > by customizing a few settings using hdparm on the command-line. I'd like > to make the changes permanent, but I'm not sure where to do that. Is there > an /etc/init.d/hdparm script out there somewhere that I should be using?
Try mine, attached. It's not art. > Presumably I'll want to link to it from one of the /etc/rc*.d directories. > Which one, and what should I call it? /etc/init.d/hdparm_init -- Any technology distinguishable from magic is insufficiently advanced. (*) http://www.spots.ab.ca/~keeling Please don't Cc: me. - -
#! /bin/bash # # /etc/init.d/hdparm_init by sbk - 1Dec2003 # # see file:///usr/share/doc/debian/FAQ/ch-customizing.html # # update-rc.d hdparm_init start 19 2 . stop 19 0 1 6 . # case "$1" in start) if [ -f /sbin/hdparm ]; then # 4Jan2004 - trying "-M": # get/set acoustic management (0-254, # 128: quiet, 254: fast) # - oops. that option doesn't appear # to exist in woody. /sbin/hdparm -d1 -X66 -c1 -u1 -m 16 /dev/hda /sbin/hdparm -d1 -X34 -c1 -u1 /dev/hdc echo "hdparm_init: optimize disk performance." fi ;; stop|force-reload|restart) ;; *) echo "Usage: $0 {start|stop|restart|force-reload}" exit 1 esac exit 0