[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: hdparm questions



On Wed, Jan 14, 2004 at 09:47:37AM +0100, David Baron wrote:
> No, this is not being run on Debian startup. Editing either /etc/default/
> hdparm or (I made a) /etc/hdparm.conf has not effect.
> 
> Where does one fine hwtools? apt-get did not work.
> 
> How might one add and a script  /etc/rc#/hdparm? (Just take one of the other, 
> leave the preambles and simply do hdparm?)

The best way to do that would be to make the script in /etc/init.d that
looks like this

-- CUT --
!#/bin/sh

case "$1" in
	start)
		# your hdparm commands here
		;;
	*)
		echo "Usage: $0 start"
esac
-- CUT --

Call it hdparm or something similar and then symlink to it in the
runlevels you wish for it to be run under (2 is the default for most
systems). Eg

$ ln -s /etc/init.d/hdparm /etc/rc2.d/S20hdparm

The name of the link is important here, S specifies the script is to
be "started" and 20 is its prefered start order.
-- 
Cheers,
rinmak <rinmak@technine.org>



Reply to: