You are not logged in.
Hi,
I have a third hard disk in my computer for Windows which I want to spin down in Linux, because of noise reasons. On several servers I maintain I just set the standby timeout to several minutes with hdparm and because the disk is not used (spare disk for RAID array), it spins down. However, on my desktop, it keeps spinning up again.
I put these commands in /etc/rc.local:
echo "Spinning down Windows disk and setting timeout to 1 min..."
hdparm -S 12 /dev/sdc
hdparm -y /dev/sdc
But the timeout option doesn't seem to work, because after spinning down, it spins up again and never spins down. When I issue the first hdparm command again, the disk does go into stand by after a minute. It's almost as though the timeout is reset at some point after rc.local is started. What could that be?
What is accessing the disk all the time? Is it some hotplug/automount thing?
How do I keep the disk spinned down?
Offline
Try hdparm -S 120 /dev/sdX. I could be wrong, but it should work better.
Offline
Why would that work better? It just changes the time.
I think I noticed what's happening. The disk spins down properly and everything, but as soon as I start KDE, it spins up again. It doesn't matter if I wait long or short before logging into KDE. And, the disk doesn't spin down anymore.
I think KDE changes the spindown timeout, but I can't find anything about it in the settings.
Is there a way to spin down the disk and then tell the kernel to discard the drive? I mean, I don't need access to it in Linux.
Offline
Try sdparm... it works for me:
sdparm --command=stop /dev/sdc
oz
Offline
Actually I posted something different from yours halfgaar. You posted sdc while I posted sdX, changes it a bit. And I was going based on what worked for my friend.
Offline
@ozar
That is basically the same as hdparm -y. I need something that makes the drive inaccessible.
@Dave158
What is /dev/sdX besides a notation that normally requires the user to replace the X with a, b, c, d, etc? /dev/sdX doesn't exist and therefore hdparm will say "/dev/sdX: No such file or directory".
Offline
This is because KDE -> HAL -> pm-utils. When KDE starts always set APM in "AC mode". You can do the trick at differents levels:
* Disable power management from KDE. (in system settings)
* Deny power management messages in HAL (/etc/dbus-1/system.d/hal.conf)
* Disable harddisk management from pm-utils (touch /etc/pm/power.d/harddrive /etc/pm/power.d/readahead)
Offline
laptop-mode tools worked for me
Last edited by alecmg (2010-09-07 07:41:03)
Xyne wrote:
"We've got Pacman. Wacka wacka, bitches!"
Offline
@ozar
That is basically the same as hdparm -y. I need something that makes the drive inaccessible.@Dave158
What is /dev/sdX besides a notation that normally requires the user to replace the X with a, b, c, d, etc? /dev/sdX doesn't exist and therefore hdparm will say "/dev/sdX: No such file or directory".
Yeah, I feel like an idiot now. Thanks for letting me know what I should have known. Sorry. I'm new to Arch.
Offline
It seems that the "touch /etc/pm/power.d/harddrive /etc/pm/power.d/readahead" worked
Offline