Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have /etc/hdparm.conf configured to power down the external USB HDD, but it actually never spins down. When I manually turn it off (hdparm -Y or set its spindown hdparm -S 36) - everything works as expected.

It seems like my Ubuntu ignores /etc/hdparm.conf on reboot :( Here's some useful info:

# blkid
/dev/sde6: LABEL="BACKUP-HDD" UUID="fee45c66-11bd-49fa-a62a-4a541716e8e1" TYPE="ext2"

# ls -lh /dev/disk/by-label
lrwxrwxrwx 1 root root  10 2009-10-19 05:59 BACKUP-HDD -> ../../sde6

# cat /var/log/dmesg /var/log/messages | grep hdparm


# tail -n 4 /etc/hdparm.conf
/dev/disk/by-label/BACKUP-HDD {
    apm = 20
    spindown_time = 36
    standby
    }

Any suggestions how to troubleshoot this?

UPD: launching sudo /lib/udev/hdparm seems to re-read /etc/hdparm.conf, but has no effect: HDD is still spinning.

share|improve this question

2 Answers 2

up vote 1 down vote accepted

There are at least two problems here.

The first one is that the script /lib/udev/hdparm that parses /etc/hdparm.conf expects that the name of the device to be configured is in environment variable $DEVNAME in the same form as it is in configuration file. The udev rule, at least in 9.04, specifies that the device name is of form [sh]d[a-z]. Of course, since the device name depends on other plugged-in drives, this is quite useless. The bug report has been open for a while: https://bugs.launchpad.net/ubuntu/+source/hdparm/+bug/222458

Another problem in the setup is that the udev script seems to be never called for SATA drives.

share|improve this answer

Powerdown of USB drives is done by the controller chip inside the drive.

This is why when the do spin down for whatever reason they often have errors.

The only real solution for this is to replace the USB enclosure.

Dan Rutter wrote a good post on this a while ago:

http://www.dansdata.com/gz055.htm

share|improve this answer
    
I'm sure my drive supports spindown well! As I said, hdparm -S 36 works well: HDD spins down in ~5min. Althou, setting spindown = 36 in /etc/hdparm.conf has no effect, and that's the case –  kolypto Oct 20 '09 at 14:14

Your Answer

 
discard

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.