Skip to content

Western Digital, Linux, S.M.A.R.T., hdparm standby

When I bought hard drives for my server I searched around and decided to buy Western Digital green power disks. I bought 3 750GB disk and set them up in RAID 5 so that I would have some security. I installed smartmontools and added the following lines to /etc/smartd.conf: /dev/sda -a -d sat -o on -S on -s (S/../.././01|L/../../6/02) -m myemail(at)nospam.dk /dev/sdb -a -d sat -o on -S on -s (S/../.././01|L/../../6/02) -m myemail(at)nospam.dk /dev/sdc -a -d sat -o on -S on -s (S/../.././01|L/../../6/02) -m myemail(at)nospam.dk /dev/sdd -a -d sat -o on -S on -s (S/../.././01|L/../../6/02) -m myemail(at)nospam.dk sda being my OS disk and sd[abc] being my storage disks. I thought everything was fine with this until I started pondering the other day why the hard drives never went into standby mode. server:~# hdparm -C /dev/sd[bcd] /dev/sdb: drive state is: active/idle /dev/sdc: drive state is: active/idle /dev/sdd: drive state is: active/idle I then started trying to setup hdparm to spin down the drives after 10min of inactivity. But for some reason it did not work. I searched and searched on Google trying to come up with a solution to the problem until I finally stumbled on a post somewhere where a person mentioned that spin down on his/her Western Digital disks didn't work until he had set up smartd and done a short test on the drive. I ran a short test on the drives but this didn't solve the problem but in the process I found that smart tests had never been run on either of the drives. I pondered this for some time and looked into it and finally I realized that if /etc/smartd.conf has a line starting with DEVICESCAN all other device lines are ignored. I commented out the DEVICESCAN line, restarted smartd and waited until next day. Voila, all of a sudden my disks had spun down as I had requested. I checked up on the specifications of the drives. According to Western Digital the green power disks use 2.8 watts in idle and 0.40 watts in standby. 3 disks * 2.4 watts = 7.2 watts. 7.2 watts * 24 hours/day * 300 days/year = 51840 Wh/year or 51.8 kWh/year. This equals to roughly DKK 100,- per year. This may not be a lot but DKK 100,- saved here and another there will sum up pretty fast, and it didn't really cost me anything except for some time to fix it. Besides I like being a nerd like this. I enjoy it tremendously.

Trackbacks

No Trackbacks

Comments

Display comments as Linear | Threaded

Ivan on :

smartmontools are pulling info from drives, and that disables them to go to sleep.

Andrew Chang on :

Why I still found your method useless? I am using an embedded Linux. Hdparm ver is 9.37 Same problem, using Western Digital HDD, I gave it command as "hdparm -S1 /dev/sdb" 5 seconds later, nothing happened... I tried to run command "smartd -c" and it made a check from sda to sdz. Then I ran "hdparm -S1 /dev/sdb" again. Still, the HDD did not spin down, its motor kept spinning happily... Could you describe how to make WD HDD spin down? Thanks a lot!

Andrew on :

Why I still found your method useless? I am using an embedded Linux. Hdparm ver is 9.37 Same problem, using Western Digital HDD, I gave it command as "hdparm -S1 /dev/sdb" 5 seconds later, nothing happened... I tried to run command "smartd -c" and it made a check from sda to sdz. Then I ran "hdparm -S1 /dev/sdb" again. Still, the HDD did not spin down, its motor kept spinning happily... Could you describe how to make WD HDD spin down? Thanks a lot!

Mark Nyqvist Hjarding on :

If you can give me some more information of the entire configuration then it may help me identify the problem. List what drives you have installed and your /etc/fstab. Currently I am using 4*2TB WD Green disks in my server and they all spin down just fine. If I had to make a wild guess then it might be because some service is accessing the drive at regular intervals.

Wolfgang on :

/me asuming... embedded linux -> USB disk -> hdparm over usb doesn't work fix it by attaching the disks to a sata port directly. Settings should be persistant. HTH

Add Comment

E-Mail addresses will not be displayed and will only be used for E-Mail notifications.

To prevent automated Bots from commentspamming, please enter the string you see in the image below in the appropriate input box. Your comment will only be submitted if the strings match. Please ensure that your browser supports and accepts cookies, or your comment cannot be verified correctly.
CAPTCHA

Form options