Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm running Ubuntu 12.04 on my Laptop with two hard disks. The primary one is a SSD, whereas the second one is a spinning hard disk. Most of the time I don't need the second hard disk, I just use it for some larger files like movies etc.. Hence I send it to sleep with 'hdparm -Y /dev/sdb'.

However after resuming from suspend the hard disk is switched on again, which is quite annoying... Does anyone know a solution to avoid waking up the second hd?

Thank you,


share|improve this question
Thank you. But I would like to avoid unnecessary spin-ups to increase the lifetime of my disk. – user70600 Jun 14 '12 at 14:18

I would send the suspend command to the drive on resume.

under /etc/apm/resume.d/ you can add a script that does that.

it would probably look like this

 # sleep drive when resuming

 case "$1" in
   resume) /sbin/hdparm -Y /dev/sdb;; 
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.