You are not logged in.

#1 2011-04-22 21:21:53

dcbdbis
Member
From: Aurora, Colorado
Registered: 2004-09-10
Posts: 247

[SOLVED] hdparm -S 241 no longer working

Sometime in the last month, hdparm has stopped spinning down defined HDD's. I have a total of three HDD's in my system. Al rotating media. Two of those HDD's I use for backup, and as such are not needed for most of the day.

In my rc.local I have:

hdparm -S 241 /dev/sdb
hdparm -S 241 /dev/sdc


Under the 2.6.27 series of kernels it worked, and now under the 2.6.38 series it no longer functions.

BUT...there has been a lot of updates since then as well so it may not be a kernel issue.

As a test, I rebooted my system, launched LXDE, launched nothing else except a terminal window. I made myself root, and issued the above commands manually and then I went away for an hour. The drives did not spindown as requested. The 241 parameter decodes to 30 minutes.

Does any one have any ideas what's up?


Thank you for your assistance.


Sincerely and respectfully,


Dave

Last edited by dcbdbis (2011-04-23 03:31:40)

Offline

#2 2011-04-23 02:04:28

lagagnon
Member
From: an Island in the Pacific...
Registered: 2009-12-10
Posts: 1,087
Website

Re: [SOLVED] hdparm -S 241 no longer working

I wonder if it is not working because something is now accessing the disk at certain intervals so it never times out the standby period. If it were me I would install "iotop" and run it (perhaps log it) and see what process(es) might be accessing your hard drives at intervals when they should not be. That would be a start anyways...


Philosophy is looking for a black cat in a dark room. Metaphysics is looking for a black cat in a dark room that isn't there. Religion is looking for a black cat in a dark room that isn't there and shouting "I found it!". Science is looking for a black cat in a dark room with a flashlight.

Offline

#3 2011-04-23 02:54:47

dcbdbis
Member
From: Aurora, Colorado
Registered: 2004-09-10
Posts: 247

Re: [SOLVED] hdparm -S 241 no longer working

Thank you for your reply. I was unaware of a utility such as iotop. It's installed and I'll monitor and see if I can discover anything. I'll report back with my findings....



Dave

Offline

#4 2011-04-23 03:31:25

dcbdbis
Member
From: Aurora, Colorado
Registered: 2004-09-10
Posts: 247

Re: [SOLVED] hdparm -S 241 no longer working

Solved!

And an explanation is due......

Culprit = Thunar, the XFCE file manager.

About one month ago, I made a significant change to my system. When I learned that Gnome 2 (my DE) was not going to be maintained, and that Gnome 3 was going to be force-fed to all Gnome users, I wiped my system and performed a complete fresh install and went with LXDE.

I looked at Gnome 3 after it was released via a live OpenSuse CD. It's not at all what I want, and it broke to many desktop paradigms for me personally. This is not a good vs evil thing as many are portraying Gnome 3, well at least it's not in my mind.

It's about choice. I use Arch for my daily work. I'm nearly 60 years old. I have no interest in having my desktop look like a smartphone. So I looked at KDE and LXDE. KDE can be customized much more easily than LXDE, but again it's a little too "heavy" for my personal tastes.

In the end I went with LXDE. PcManFm does not have a tree view in the left-hand pane. Thunar does. So Thunar got the nod as my file manager of choice.

I have discovered with the assistance of 'iotop' that when you open Thunar, it goes out and refreshes itself (I suspect the dir tree) with regard to every mounted file system. And as my backups, sdb1 and sdc1 were mounted, they had a read event. Your suggestion of iotop documented this. Apparently Gnome 2's 'Nautilus' file manager does not do this, because under Gnome 2, the drives spun down in accordance with my hdparm settings in the /etc/rc.local file.

My personal solution is simple. I changed my /etc/fstab and added the noauto to the line for these two drives. They do not get mounted, and in tests, Thunar doesn't attempt to automount them (I did not install the volume addon), and I also turned off the mounting features in pcmanfm.

Problem solved. The drives no longer have read events everytime I open Thunar, and spin down as they should.

For others, a second solution would be to leave the /etc/fstab alone, and simply unmount the backup drive(s) when you know you will not be using them for a while.

'iotop' did the trick for me in identifying the problem.


Thank you sincerely for the assistance. I appreciate it!


Dave.....

Last edited by dcbdbis (2011-04-23 03:39:09)

Offline

Board footer

Powered by FluxBB