Debian Install and Configure:
$ sudo apt-get install hdparm
$ sudo nano /etc/hdparm.conf
$ sudo /etc/init.d/hdparm restart
Check Current State:
hdparm -C /dev/hda
--------------------------------------------------------------------------------
Set Spin-Down Time:
hdparm -S {0|1-240}
spindown_time (-S)
-S[1-240] # multiples of 5 seconds:
Mx60/5=-S
012 = 01m
024 = 02m
120 = 10m (0600/60s=10m)
180 = 15m (0900/60s=15m)
240 = 20m (1200/60s=20m)
--------------------------------------------------------------------------------
#/etc/hdparm.conf
/dev/hda {
spindown_time = 12 # -S (standby (spindown) timeout for the drive)
mult_sect_io = 16 # -m (sector count for multiple sector I/O =32)
write_cache = on # -W (Disable/enable the IDE drive's write-caching feature)
dma = on # -d (disable/enable the "using_dma" flag for this drive)
apm = 255 # -B (apm setting)
}
/dev/hdb {
quiet # -q (be quiet)
bus = on # -b (bus state)
read_only = on # -r (read-only flag for device)
standby # -y (force to immediately enter the standby mode)
sleep # -Y (force to immediately enter the sleep mode)
read_ahead_sect = 12 # -a (sector count for filesystem read-ahead)
lookahead = on # -A (disable/enable the IDE drive's read-lookahead feature)
disable_seagate # -Z (disable the power-saving function of certain seagate drives (ST3xxx))
}
--------------------------------------------------------------------------------
Research (/etc/hdparm.conf)
-k disable/enable the "keep_settings_over_reset" flag for this drive
keep_settings_over_reset = off
-K disable/enable the drive's "keep_features_over_reset" flag
keep_features_over_reset = on
-P maximum sector count for the drive's internal prefetch mechanism
prefetch_sect = 12
-M Set the acoustic management properties of a drive
acoustic_management
--------------------------------------------------------------------------------
hdparm man selections
-B Set Advanced Power Management feature, if the drive supports it.
A low value means aggressive power management and a high value
means better performance. A value of 255 will disable apm on the
drive.
-C Check the current IDE power mode status, which will always be
one of unknown (drive does not support this command),
active/idle (normal operation), standby (low power mode, drive
has spun down), or sleeping (lowest power mode, drive is com-
pletely shut down). The -S, -y, -Y, and -Z flags can be used to
manipulate the IDE power modes.
-S Set the standby (spindown) timeout for the drive. This value is
used by the drive to determine how long to wait (with no disk
activity) before turning off the spindle motor to save power.
Under such circumstances, the drive may take as long as 30 sec-
onds to respond to a subsequent disk access, though most drives
are much quicker. The encoding of the timeout value is somewhat
peculiar. A value of zero means "timeouts are disabled": the
device will not automatically enter standby mode. Values from 1
to 240 specify multiples of 5 seconds, yielding timeouts from 5
seconds to 20 minutes. Values from 241 to 251 specify from 1 to
11 units of 30 minutes, yielding timeouts from 30 minutes to 5.5
hours. A value of 252 signifies a timeout of 21 minutes. A
value of 253 sets a vendor-defined timeout period between 8 and
12 hours, and the value 254 is reserved. 255 is interpreted as
21 minutes plus 15 seconds. Note that some older drives may
have very different interpretations of these values.
-y Force an IDE drive to immediately enter the low power consump-
tion standby mode, usually causing it to spin down. The current
power mode status can be checked using the -C flag.
-Y Force an IDE drive to immediately enter the lowest power con-
sumption sleep mode, causing it to shut down completely. A hard
or soft reset is required before the drive can be accessed again
(the Linux IDE driver will automatically handle issuing a reset
if/when needed). The current power mode status can be checked
using the -C flag.
-Z Disable the automatic power-saving function of certain Seagate
drives (ST3xxx models?), to prevent them from idling/spinning-
down at inconvenient times.
-i Display the identification info that was obtained from the drive
at boot time, if available. This is a feature of modern IDE
drives, and may not be supported by older devices. The data
returned may or may not be current, depending on activity since
booting the system. However, the current multiple sector mode
count is always shown. For a more detailed interpretation of
the identification info, refer to AT Attachment Interface for
Disk Drives (ANSI ASC X3T9.2 working draft, revision 4a, April
19/93).
-I Request identification info directly from the drive, which is
displayed in a new expanded format with considerably more detail
than with the older -i flag.