Smart Spindown

Description

Smart spindown is a script that helps you spin down your hard disk on Linux 2.6. It detects periods of inactivity, and spins down your disk if it is inactive for a configurable period. Its primary usage is for harddisks that refuse to spin down properly because they have a lower limit on the idle timeout. If a spindown fails (i.e., the disk spins up immediately again), smart spindown uses a backoff algorithm: the idle timeout is temporarily increased, so that the disk won't be spun down unsuccessfully twenty times in a row.

This script can also be used to achieve a very small performance improvement for laptop mode. When you set SYNC_BEFORE_SPINDOWN=true in the smart spindown script, the disk is synced just before spindown. In laptop mode, the disk is synced idle-timeout before spindown. Because smart spindown is able to sync your disks later, the disks can also spin up later, as laptop mode's "maximum age" (maximum time that data can stay in the cache without being written) is counted from the last sync and not from the moment of spindown.

Status

Unpackaged, unmaintained, and generally for only suitable for people who really need it and who love to tinker with their systems.

Usage instructions

  1. Download the script
  2. Tweak the configuration values (they are described in the script)
  3. Create a copy of the script for every one of your disks, and modify the DISK value in each of them
  4. Start all of the disk-specific versions of the script in the background, as user root.
If you are going to use this in combination with Laptop Mode, please read what it says about Smart Spindown in the laptop mode FAQ.

Download

Smart spindown can be downloaded here. It is a script, so you'll have to chmod u+x it. Please edit the script and modify the configuration values before using it!

Related pages

Laptop Mode
Laptop Mode Tools
Laptop Mode and Laptop Mode Tools FAQ


Navigation

Laptop Mode
... Home
... Tools
...... Packages
... FAQ
Smart Spindown
Bart Samwel