3

I'm getting a laptop tomorrow with an SSD as the primary (operating system) drive, and I will be putting my old laptop's HDD into it as a secondary drive for holding music etc.

Since HDDs use power when idle, just to keep themselves spinning, I was wondering what the optimum settings for 'spinning down' the drive might be, as well as any other tips. I remember seeing reference to a settings file where I would be able to choose how long the drive can sit idle for before spinning down, but I don't know where it was.

Additionally, if the drive uses an NTFS file system, will the system write or read anything from the drive by itself which could prevent the spin-down from happening? I was intending to permanently mount it using the installer to /windows, but would be open to any better methods if this would cause a problem.

Thanks for any assistance.

0

2 Answers 2

7

To put your second HDD (I suppose /dev/sdb) to standby immediately, you can use

sudo hdparm -y /dev/sdb

To put it to standby after a minute of inactivity, you can use

sudo hdparm -S 12 /dev/sdc

(time is counted in 5s for 5s to 20min)

To make this setting permanent, you can write it in /etc/hdparm.conf:

sudo gedit /etc/hdparm.conf

and there:

[...]
/dev/sdb {
    spindown_time = 12
}
2
  • I am using sdparm --command=stop <device> to spin down the drive. Where would I need to configure that?
    – Marco
    Sep 28, 2012 at 16:47
  • 1
    Thankyou for this answer. Just out of interest, if I choose to simply mount/unmount the drive myself each time, will the drive be powered down whenever it's unmounted? If not, how can I 'turn it off' when I don't want it?
    – Sman789
    Sep 30, 2012 at 0:56
0

You could also try to enabled Aggressive Link Power Management (ALPM). Aggressive Link Power Management (ALPM) is a mechanism where a SATA AHCI controller can put the SATA link that connects to the disk into a very low power mode during periods of zero I/O activity and into an active power state when work needs to be done. Tests show that this can save around 0.5-2 Watts of power on a typical system.

ALPM is now available in several SATA controllers that use the Advanced Host Controller Interface (AHCI). However, there is evidence that some controllers may go into a low power state incorrectly and this ends up causing data loss. Ubuntu has the ability to use ALPM but it it disabled by default since it can cause data loss on some machines. Since there is a chance that this can cause data loss do not enable it unless you have backups of your data and are willing to take the risk.

To enable ALPM:

echo SATA_ALPM_ENABLE=true | sudo tee /etc/pm/config.d/sata_alpm

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .