High frequency of load/unload cycles on some hard disks may shorten lifetime

Bug #59695 reported by Gilles Schintgen
842
This bug affects 80 people
Affects Status Importance Assigned to Milestone
acpi-support
Invalid
Undecided
Unassigned
Suse
Fix Released
Unknown
acpi-support (Baltix)
Fix Released
Undecided
Unassigned
acpi-support (Debian)
Fix Released
Unknown
acpi-support (Ubuntu)
Fix Released
Critical
Steve Langasek
Declined for Dapper by Steve Langasek
Declined for Edgy by Timo Aaltonen
Declined for Feisty by Steve Langasek
Declined for Gutsy by Steve Langasek
Nominated for Karmic by Metzelmaennchen
Nominated for Lucid by Metzelmaennchen
Nominated for Maverick by Kikko
Hardy
Fix Released
Critical
Steve Langasek
Intrepid
Fix Released
Critical
Steve Langasek
Jaunty
Fix Released
Critical
Steve Langasek
laptop-mode-tools (Mandriva)
Unknown
Critical
linux-meta (Ubuntu)
Invalid
Undecided
Unassigned
Declined for Dapper by Steve Langasek
Declined for Edgy by Timo Aaltonen
Declined for Feisty by Steve Langasek
Declined for Gutsy by Steve Langasek
Nominated for Karmic by Metzelmaennchen
Nominated for Lucid by Metzelmaennchen
Nominated for Maverick by Kikko
Hardy
Invalid
Undecided
Unassigned
Intrepid
Invalid
Undecided
Unassigned
Jaunty
Invalid
Undecided
Unassigned
pm-utils (Fedora)
Invalid
Medium
pm-utils (Ubuntu)
Fix Released
Undecided
Unassigned
Declined for Dapper by Steve Langasek
Declined for Edgy by Timo Aaltonen
Declined for Feisty by Steve Langasek
Declined for Gutsy by Steve Langasek
Nominated for Karmic by Metzelmaennchen
Nominated for Lucid by Metzelmaennchen
Nominated for Maverick by Kikko
Hardy
Fix Released
Critical
Steve Langasek
Intrepid
Fix Released
Critical
Steve Langasek
Jaunty
Fix Released
Undecided
Unassigned

Bug Description

The kernel wiki gathers info about drives with too aggressive power saving defaults. A script called "storage-fixup" is also available.
https://ata.wiki.kernel.org/index.php/Known_issues#Drives_which_perform_frequent_head_unloads_under_Linux

This is not a support forum. Please do not use it as such (even though it has been used as such already).

You can scan through the bug for links to the Ubuntu forums where many, many different questions have been asked, answered, and re-answered. The temporary workaround is just below.

See https://wiki.ubuntu.com/PowerManagement for an overview about what is involved and for a remedy.

SRU justification: current behavior may lead to premature disk failure in laptops due to excessive unnecessary drive parking. Fix will disable disk cycling by default when on AC power, by correcting an error in the hdparm logic of acpi-support.

For jaunty, this issue is addressed in acpi-support 0.115.

TEST CASE:

1. With acpi-support 0.109 (hardy) or 0.114 (intrepid) installed and laptop-mode *not* enabled in either /etc/default/laptop-mode or /etc/default/acpi-support, monitor the load cycle count of your hard drive by running 'sudo smartctl -a /dev/sda|grep Load_Cycle_Count' over an interval of several minutes, and observe that it is incrementing. (If it does not increment, your hard drive's manufacturer defaults are sane and you are not affected by this problem.)
2. install acpi-support from hardy-proposed or intrepid-proposed
3. while connected to AC power, monitor 'sudo smartctl -a /dev/sda|grep Load_Cycle_Count' again to confirm that the number is no longer incrementing
4. (assuming that the system is a laptop:) disconnect the system from AC power, and confirm that the number is incrementing again
5. enable laptop mode by setting ENABLE_LAPTOP_MODE=true in /etc/default/laptop-mode and running 'sudo /etc/init.d/laptop-mode restart'
6. reconnect the system to AC power and confirm that the Load_Cycle_Count stops incrementing.
7. suspend and resume the system and confirm that the Load_Cycle_Count is still not incrementing.

REGRESSION POTENTIAL:

As this patch causes "hdparm -B 128" and "hdparm -B 254" to be invoked automatically on systems where it was not being run before, there is some risk that this change will have a measurable impact on the disk throughput, power consumption, and temperature of some hard drives. Nevertheless, it is believed that these APM power settings are the sensible default settings for the vast majority of hard drives and that the current behavior poses a significant risk to the longevity of hard drives used in a wide range of laptop models, so this update should only be blocked if it results in confirmed hardware damage that can be expected to apply to a similar range of configurations.

Following is a summary of the issue:
It is confirmed that some systems are seeing an unusually high number of load/unload cycles on their hard disks, as evidenced by smartctl.

It was originally surmised that this was related to laptop-mode being enabled, but this especially affects systems where laptop-mode is disabled. In fact, aggressive APM is not a bad idea while a system is not on AC, as that system is much more likely to encounter a physical impact.

This is due to disk APM settings that let the heads park or disk spin down after an idle period that is shorter than the regular disk access patterns of the OS.

Then, the heads are only parked for a very short period of time and almost imediately loaded again. Making impact protection much ineffective and wearing out the drive.

It can happen when the disk asumes aggressive APM settings (like many laptop disks) and the OS does not take care to set the APM settings accordingly to its current disk access pattern.

This problem has been confirmed in Ubuntu as well as in other distributions and on MacOS X and Windows.

Symptoms of this bug are:
* Frequent HD clicks -- more than one per 3 minutes while idle, louder than the typical access sounds. Often more than twice per minute. On some disks, the click is very quiet
* Rapidly Increasing Load_Cycle_Count as displayed in the final number in "sudo smartctl -a /dev/hda | grep Load_Cycle_Count" (where /dev/hda is replaced with your own hard disk device)

The problem is only present due to the existence of *all four* of the following factors:
* Hardware is set (default or otherwise) to aggressive power management, causing heads to park. (default behaviour of many drives and often the only user available type of power management)
* Disk is touched often, causing heads to unpark. (default behaviour of many distributions)
* Drives are spec'd to a limited number of these cycles. (600,000 is the most common, although some may be spec'd higher or lower).
* The OS not setting disk APM variables according to current disk access pattern.

Reasonable Limits / Criteria for a fix:
* There should be fewer than ~15 load cycles per hour, except during heavy usage while on battery.
* This provides a life expectancy of over four years, which is reasonable for a hard disk.

Temporary Workaround:
* Follow the above link.

Some hardware with this issue:
WD1200VE -- http://www.wdc.com/en/library/portable/2879-001121.pdf -- This aggressive parking is a feature of this disk, but that feature relies on behaviour that allows for significant amounts of (truly) idle time without the disk being touched. Notice the "Load/unload cycles" of 600,000.

Example Load_Cycle_Counts:
* Thinkpad Z60m/Hitachi HTS541080G9SA00 with well over 7000 load cycles in only 100 hours. That's >70 per hour.
* Gateway MT6451/Western Digital WD1200VE with 164762 load cycles in 3747 hours (156 days) of uptime. That's ~43 per hour -- except that the system was patched during the initial third of its life, which puts it at ~63/hour since Gutsy was installed (and wasn't patched, as I had done with feisty).
* Dell Inspiron 8600/Hitachi HTS721010G9AT00 with 200 to 280 load cycles per hour

Please see for yourself how often your drive is load cycling:
smartctl -d ata -a /dev/sda
(This command is for an SATA drive; you'll need to install the smartmontools package first.)

You can get the average per hour by the following division:
Load_Cycle_Count / Power_On_Hours

Old workaround for 7.10 (not working in 8.04): https://bugs.launchpad.net/ubuntu/+source/acpi-support/+bug/59695/comments/14
A more extensive description of the workaround: http://ubuntuforums.org/showthread.php?t=591503

You may need to use '254', or a bit lower, as opposed to '255'. If HD temperature gets high, you may want to set it all the way "down" to 200 or so. ~1 click every 2.5-3 minutes is fine.
Note: Some disks are unresponsive to having their APM changed by hdparm, and therefore the workaround doesn't work. It would be a good idea, in such cases, to disable APM in the BIOS if possible.

See also http://paul.luon.net/journal/hacking/BrokenHDDs.html for a rather dramatic account of the effects the current default values may have.

Revision history for this message
Loic Pefferkorn (loic) wrote :

I can confirm this behavior with my T43

Changed in acpi-support:
assignee: nobody → ubuntu-laptop
importance: Untriaged → Wishlist
status: Unconfirmed → Needs Info
Revision history for this message
Gilles Schintgen (shigi) wrote : Re: [Bug 59695] Re: default value in power.sh potentially kills laptop disks

> I can confirm this behavior with my T43
Thanks for confirming. So now we'll have to determine sane default values.
I did some very unscientific tests using the command

smartctl -d ata -a /dev/sda | grep 193; hdparm -B 180 /dev/sda; sleep 600; \
smartctl -d ata -a /dev/sda | grep 193; hdparm -B 255 /dev/sda

and continuing to work normally. After 10 minutes I checked the output.

Here are some values:
-B 128 -> 23 cycles in 10 minutes
-B 160 -> 29 in 10'
-B 180 -> 0 in 10'
-B 196 -> 0 in 10'
-B 200 -> 0 in 10'

So even -B 160 leads to 3 cycles per minute (180 per hour), leading to a
lifespan of 600,000/180/24=139 days (of continuous battery powered use).
Note that only a few years ago 300,000 load/unload cycles was a common value.

What is remarkable is the sharp drop between 180 and 196. Could somebody else
report some values for his system?

Does anyone know how the -B parameter is interpreted or is that left up to the
device?

Revision history for this message
Gilles Schintgen (shigi) wrote : Re: [Bug 59695] default value in power.sh potentially kills laptop disks

> When switching to battery power, /etc/acpi/power.sh issues the command
> hdparm -B 1 to all block devices.
But only if laptop mode is enabled.
However in my case laptop mode is still _disabled_
in /etc/default/acpi-support. So, if I'm understanding the power.sh script
correctly it's _not_ this script which causes these frequent load cycles.
Hence my original report was wrong. Sorry about that.

Some more investigation led me to the following page:
http://www.thinkwiki.org/wiki/Problem_with_hard_drive_clicking
It seems that Hitachi is using some quite aggressive power management.

I'm not sure what to do about this report. If it really turns out to be a
hardware problem it should probably be closed.

Revision history for this message
Peter Funk (pf-artcom-gmbh) wrote : Re: default value in power.sh potentially kills laptop disks

Running Ubuntu 6.10 on brand new HP compaq nw9440 with a Seagate ST910021AS
since February 27th: Load Cycle Count 134608 in 2 and half month ! :-(
I also noticed the hard drive clicking noise quite frequently and using Google
I stumbled over your bug report here. I'm using XFS as a filesystem, if
this mattern anyhow in this issue.
Update: after 10 minutes with ``hdparm -B 180 /dev/sda`` the load cycle
count has increased to 134616. I will now try the command
``smartctl -o on /dev/sda`` as suggested on the thinkwiki page mentioned
in the thread here.

Revision history for this message
Gilles Schintgen (shigi) wrote :

Please increase the importance of this issue. I'm really concerned about my disk's health.

I was noticing some clicking but didn't think much about it since I "fixed" this issue a long time ago. Only now it occurred to me that maybe some update overwrote my changes.

Unfortunately this seems to be the case. Here's the current stats from my disk (the thinkpad is from august 2006!):
192 Power-Off_Retract_Count 0x0032 100 100 000 Old_age Always - 7143426

Over 7 MILLION retracts! I'm wondering how long it will hold. I just find it curious that "value" is still at "100" whereas the threshold (for failure) is "000".

Revision history for this message
Gilles Schintgen (shigi) wrote :

Oh well...

Forget about my last comment. I was looking at "192 Power-Off_Retract_Count" instead of "193 Load_Cycle_Count" and freaked out. I guess I need some sleep.

Anyway, what is Power-Off_Retract_Count and how can it reach 7,000,000?

Revision history for this message
TDB (michael-baranov) wrote :

Please increase the importance of this issue!
``hdparm -B 255 /dev/sda`` works like a charm!
changing 1=>255 in /etc/acpi/power.sh does not seem to work for me.

Toshiba P205, FUJITSU MHW2120BH

Revision history for this message
TDB (michael-baranov) wrote :

Oh... seems like when going out of hibernate/suspend the effect of ``hdparm -B 255 /dev/sda`` disappears. Need to re-issue it again. Can somebody help me with executing this on 1) boot 2) return from hibernate 3) return from suspend, PLZ?

Revision history for this message
TDB (michael-baranov) wrote :

I wonder if /etc/hdparm.conf can help...

BTW: https://bugs.launchpad.net/ubuntu/+bug/104535

Revision history for this message
Gilles Schintgen (shigi) wrote :

It seems that I completely forgot to publish my fix/workaroud. As far as I remember I did two things:

1) I added the following lines to my hdparm.conf:
/dev/sda {
  apm = 255
}

2) I created a file /etc/acpi/resume.d/99-stop-hitachi-madness.sh
with the following contents:
#!/bin/sh
hdparm -B 255 /dev/sda

I hope this helps.

Revision history for this message
TDB (michael-baranov) wrote :

Gilles, thanks! The first workaround that actually works.

IMO, modifying hdparm.conf has no effect because the "last word" is said by /etc/acpi/resume.d/99foo.sh
I've also added the same script to /etc/acpi/start.d/

Oh... now with kernel 2.6.22 (emergency unloads on shutdown fixed) and this fix my HDD can rest at ease...

Revision history for this message
William (williamc-sp) wrote : THIS IS REALLY A PROBLEM ... Re: default value in power.sh potentially kills laptop disks

Confirmed also with my Hitachi HTS541210H9SA00 (which has used up 10% of its life in less than a month :( ). Needless to say I would suggest this bug have very high priority. I am surprised that it has persisted as long as it has --- Ubuntu is meant to be harmless, but, it isn't at the moment.

Changed in acpi-support:
status: Incomplete → Confirmed
Revision history for this message
unknown (stealthbox) wrote : Re: default value in power.sh potentially kills laptop disks

I can confirm this bug on my inspiron 1501, the hd light goes on way too much compared to xp. Its a shame this isnt considered important. I guess i cant use ubuntu on my laptop

Revision history for this message
TDB (michael-baranov) wrote :

Here is how I permanently fixed it:

1) make a file named "99-hdd-spin-fix.sh". The important thing is starting with "99".
2) make sure the file contains the following 2 lines (fix it if you have PATA HDD):
#!/bin/sh
hdparm -B 255 /dev/sda
3) copy this file to 3 locations:
/etc/acpi/suspend.d/
/etc/acpi/resume.d/
/etc/acpi/start.d/

Voila! After that the HDD never spins down on power (looks like it actually spins down on battery at modest rate).
Sorry if the instruction is too detailed, no offense.

Revision history for this message
TDB (michael-baranov) wrote :

Ah... the same workaround posted by someone else before me.... sorry.

Revision history for this message
ramas (slocascio) wrote :

The command hdparm -b 255 turn off completely APM.
This could last HD life by saving load cycles.
On the other hand, the HD temperature could get very HOT (51°c on my Inspiron), also decreasing drive life.

I wonder if there is another better solution to this, for example using SMART functions with smartctl.
BTW fot Itachi drives I found this page that could help: http://www.dellcommunity.com/supportforums/board/message?board.id=insp_harddrive&thread.id=38562&view=by_date_ascending&page=1

Revision history for this message
Bart Samwel (bart-samwel) wrote : Re: [Bug 59695] Re: default value in power.sh potentially kills laptop disks

ramas wrote:
> The command hdparm -b 255 turn off completely APM.
> This could last HD life by saving load cycles.
> On the other hand, the HD temperature could get very HOT (51°c on my Inspiron), also decreasing drive life.
>
> I wonder if there is another better solution to this, for example using SMART functions with smartctl.
> BTW fot Itachi drives I found this page that could help: http://www.dellcommunity.com/supportforums/board/message?board.id=insp_harddrive&thread.id=38562&view=by_date_ascending&page=1

AFAICT this page simply describes a tool for Windows that does exactly
what hdparm does, except that it sets the default for the drive. Nothing
new there.

Cheers,
Bart

Revision history for this message
TDB (michael-baranov) wrote : Re: default value in power.sh potentially kills laptop disks

@ramas
AFAIK modern drives are able to handle high temps just fine. Up to 75 C is OK. More over, 2,5" HDDs produce max 2 wats of heat on idle spin, so unless you keep the lead of your laptop closed and the HDD spinning overnight, you won't have any heat problems.

Revision history for this message
Don Mullis (don.mullis) wrote :

An alternative to the "99-hdd-spin-fix.sh" fix is to install and enable the package laptop-mode-tools,
then customize /etc/laptop-mode/laptop-mode.conf, setting

CONTROL_HD_POWERMGMT=1

Revision history for this message
Mike C. (launchpad-christiansons) wrote :

I am also experiencing this issue on my Dell Inspiron 6400.

According to smartctl, my load cycle count is 73,603. Now, I’ve had my 6400 for five months, so that’s ~484 cycles per day. At this rate my hard drive (HTS721010G9SA00) will “last” ~3.5 years.

Revision history for this message
Martin Polden (martin-polden) wrote :

I have the same problem on a M1330. I've only been using it since Friday the 19th and my load cycle count is already at 851. I managed to "slow it down" by doing sudo hdparm -B 254 /dev/sda.

Revision history for this message
Jens Berke (jensberke) wrote :

Behaviour confirmend on an IBM Thinkpad R52 with harddisk Hitachi HTS541060G9AT00. Default value for APM is 128 after a clean install of Gutsy Gibbon. A value of 192 or bigger, set with "hdparm -B", seems to be the range of values with no load cycles.

The load cycles are *not* limited to battery power mode on my system. I also had them when not in battery power mode.

Revision history for this message
brokencrystal.com (admin-brokencrystal) wrote :

Since this can significantly shorten the life of your hard drive, shouldn't this bug be listed a little higher in importance than just a wishlist?

Revision history for this message
Christian Wolf (christianwolf) wrote :

All 3 of my laptops are also affected. The suggested fix with "hdparm -B 180" however does not work for all harddrives. On my HITACHI_DK239A-65B (old Notebook drive in my Thinkpad 600E) for example, it does exactly the opposite when the laptop was set into laptop mode - it then starts frequent harddrive access every 10 sec which are otherwise turned off when in laptop mode. I have to turn OFF S.M.A.R.T with smartctl -s off /dev/hda and then to start laptop-mode AND in order to stop all unneccessary HD access.

By the way, this is my reload_cycle number for this 9 yr old harddrive, used as my webserver:
225 Load_Cycle_Count 0x0012 100 100 050 Old_age Always - 1627390049

Lovely :-) What is this numer - billions?

Seriously: I think that marking this severe issue as "Wishlist" is inapproprate. Also, not issuing a public warning reminds me to the behaviour of a software company based in Redmond, USA and is not nice to to all Ubuntu supporters who trust Canonical and the developers. Ubuntu is not perfect, but we have nothing to hide, even if a bug like this could cause bad press.

From the Ubuntu Code of Conduct:
Be considerate. Your work will be used by other people, and you in turn will depend on the work of others. Any decision you take will affect users and colleagues, and we expect you to take those consequences into account when making decisions.

Ty for your consideration.

Revision history for this message
Martin Polden (martin-polden) wrote :

As a temporary fix I edited /etc/hdparm.conf and added:

/dev/sda {
  apm = 255
  spindown_time = 0
}

Afterwards I installed the hdparm init script by doing 'sudo update-rc.d hdparm defaults' to make the changes consistent over reboots.

This is the same as running the following commands:
hdparm -B255 /dev/sda
hdparm -S0 /dev/sda

This will turn off Advanced Power Management on the drive and it will disable the standby (spindown) timeout, so the drive will never be spun down and up again.

Revision history for this message
SendDerek (sendderek) wrote :

Is there any way to brief a beginner on how to read the output of "smartctl -d ata -a /dev/sda"? I'm having a hard time finding the line where it states "xx cycles in xx minutes". Here is what I can see from this command (some info has been left out):

Model Family: Hitachi Travelstar 5K100 series
Device Model: HTS541010G9SA00
Firmware Version: MBZOC65D
User Capacity: 100,030,242,816 bytes
Device is: In smartctl database [for details use: -P show]
ATA Version is: 7
ATA Standard is: ATA/ATAPI-7 T13 1532D revision 1
Local Time is: Wed Oct 24 07:06:02 2007 MDT
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

Vendor Specific SMART Attributes with Thresholds:
193 Load_Cycle_Count 0x0012 066 066 000 Old_age Always - 349519

Revision history for this message
Joey Stanford (joey) wrote :

I have been able to confirm this on my System76 Darter. It appears to also have been the problem I've been seeing since feisty where the HD seems to always be in use. By deactivating APM (e.g. hdparm -B 255 /dev/sda ), my always in use issue has been resolved. My current Load Cycle is 333001 on a machine I bought in March. Also to note, that the load cycle increases also on AC Power, although not near as frequently as with laptop mode.

Revision history for this message
Blue (vali-dragnuta) wrote :

I confirm this and more : same behaviour on a _desktop_ computer. This because on that desktop on_ac_power returns nonzero and the system thinks it's running on batteries.
The actual hdparm setting is here :
/etc/apm/event.d/20hdparm
This creates TWO new bugs :
1. first one is that this script runs AFTER /etc/init.d/hdparm so if we set -S0 in /etc/hdparm.conf to disable this behaviour , the setting will have no effect as it will be overset by 20hdparm
2. second bug is that in /etc/apm/event.d/20hdparm line 64 the script does not treat the case where on_ac_power returns 255 (could not determine state). In this case, the power conserve mode should NOT be activated.

Anyway, as a temporary workaround you can edit /etc/apm/event.d/20hdparm and set on line 32 APMD_SPINDOWN to a saner value. Also, it would be nice to move this parameter in /etc/default so that it is cleanly configurable.

Revision history for this message
Blue (vali-dragnuta) wrote :

I think this deserves a greater importance than "wishlist".
A value of 18 for hdparm -S translates to 90 seconds, and this is insane, because even let to idle the system will try write to the disks every 2..4 minutes.
That means that the disk idles for 90 seconds and spins down and after another 90 seconds the system wants to write on it and it spins it up again. So, even with an idle system
the hard disk will be spinned up 90 seconds and spinned down the next 90. Not only this is dangerous, but it's useless from a power management point of view.

Revision history for this message
CheolHan Yoon (mait) wrote :

It's not 'wishlist', just 'critical issue'.

I've had same problem, and now solved with martin's tweak.

Quote,

As a temporary fix I edited /etc/hdparm.conf and added:

/dev/sda {
  apm = 255
  spindown_time = 0
}

Afterwards I installed the hdparm init script by doing 'sudo update-rc.d hdparm defaults' to make the changes consistent over reboots.

Thnks, martin.

Revision history for this message
Blue (vali-dragnuta) wrote :

Please note that that editing hdparm.conf alone does NOT solve the problem, see comment 58 for details.

Revision history for this message
Chris Moore (dooglus) wrote :

Which comment do you mean, Blue? Yours is comment 31. Do you have abilities to predict the future? If so, will this laptop of mine be killed for a 2nd time by this bug before its 12 month warranty expires?

Revision history for this message
Martin Polden (martin-polden) wrote :

Editing hdparm.conf alone is not enough and as I wrote in my previous comment, you have to run 'sudo update-rc.d hdparm defaults' too so that the hdparm init script is added to the approperiate runlevels (2, 3, 4 and 5). Runlevel 2 is the last runlevel and scripts in this runlevel are executed last, you can verify this by running the 'runlevel' command after you log in.

Revision history for this message
Christian Wolf (christianwolf) wrote :

WARNING:

Fiddling around with hdparm might stop the unload/load cycles but can also dramatically increases HD Temp - at least here on my Compaq Evo600N:

192 Power-Off_Retract_Count 0x0032 100 100 000 Old_age Always - 12
193 Load_Cycle_Count 0x0032 094 094 000 Old_age Always - 67387
194 Temperature_Celsius 0x0022 100 100 000 Old_age Always - 50 (Lifetime Min/Max 16/50)

-->we have winter, the laptop is being used as a web server, low load, in a very cold room (14 degress Celsius!!) The fan is going on constantly to cool down the HD.
I took the -B 200 value, which works fine for my HP NX6325 - but NOT for this machine. I have to check if this is connected with laptop-mode - although I am on cable, it seems to be activated during boot up.

So careful with modifying APM values with hdparm.....

I think this bug does not get more importance until Mark Shuttleworth notebook dies from it :-((((((

Revision history for this message
Blue (vali-dragnuta) wrote : Re: [Bug 59695] Re: default value in power.sh potentially kills laptop disks
Revision history for this message
Blue (vali-dragnuta) wrote : Re: default value in power.sh potentially kills laptop disks

I would rather suggest to modify /etc/apm/event.d/20hdparm and at line 32 instead of
APMD_SPINDOWN=18

put
APMD_SPINDOWN=180 # 15 minutes instead of 90 seconds.

You can also set /etc/hdparm.conf, but as long as the apmd service is activated the setting in /etc/hdparm.conf will be useless, so if you modify hdparm.conf please
don't forget to make sure that hdparm is executed at boot (use rcconf,update-rc.d or services admin for that) AND make sure that you either modify the APMD_SPINDOWN or disable the apmd service using the previously mentioned rc tools.
I had a longer discussion with Martin by email and he had apmd disabled - that's why his hdparm.conf setting was not overset.
Anyway, 90 seconds is insane as default value.
And I also want to reiterate that the same apm script incorrectly assumes a on-battery configuration when it can't actually figure out if we are running on ac power or on battery (the special case 255 returned by on_ac_power ).

Revision history for this message
Joey Stanford (joey) wrote :

Keep in mind that you can change the acpi spindown time in /etc/defaults/acpi-support. restarting the acpi-support service should enable the new times. I'm unfortunately not a power management expert so your mileage may vary.

Revision history for this message
Kamil Páral (kamil.paral) wrote :

I have Dell Latitude C640 with Western Digital 40GB. The harddisk is 3 days old (brand new) and I have 900 load cycle count. My harddisk "clicks" (increases load cycle count) roughly twice a minute (regardless battery or AC mode), but (this is important) only when there is absolutely no other harddisk activity. If I use some app which few times a minute reads or writes a file, there is no load cycle count increase.

I have also tried Windows XP - there is no cycle count increase, no hdd clicking. In BIOS, hdd clicks once (the sound is distinguishable from normal activity) - after that, it's silent. In Ubuntu 7.10, twice a minute.

For those who have IBM/Hitachi, you can try download Hitachi Feature Tool
http://www.hitachigst.com/hdd/support/download.htm
and disable/tweak APM manually right from that livecd. Maybe after that you will not have to hack scripts (maybe it can "force" the APM setting), but I am not sure of that.

Revision history for this message
Brian Ealdwine (eode) wrote : Re: [Bug 59695] Re: default value in power.sh potentially kills laptop disks

I wonder if it's going into sleep, and then trying to write to the log
that it has gone to sleep.. That would be a big 'duh'.

On Wed, 2007-10-24 at 22:43 +0000, Kamil Páral wrote:
> I have Dell Latitude C640 with Western Digital 40GB. The harddisk is 3
> days old (brand new) and I have 900 load cycle count. My harddisk
> "clicks" (increases load cycle count) roughly twice a minute (regardless
> battery or AC mode), but (this is important) only when there is
> absolutely no other harddisk activity. If I use some app which few times
> a minute reads or writes a file, there is no load cycle count increase.
>
> I have also tried Windows XP - there is no cycle count increase, no hdd
> clicking. In BIOS, hdd clicks once (the sound is distinguishable from
> normal activity) - after that, it's silent. In Ubuntu 7.10, twice a
> minute.
>
> For those who have IBM/Hitachi, you can try download Hitachi Feature Tool
> http://www.hitachigst.com/hdd/support/download.htm
> and disable/tweak APM manually right from that livecd. Maybe after that you will not have to hack scripts (maybe it can "force" the APM setting), but I am not sure of that.
>

Revision history for this message
Martin Wilson (martinmwilson) wrote : Re: default value in power.sh potentially kills laptop disks

I just want to chime in with all the others that are frustrated this is listed as "wishlist". I know a quick triager may have just skimmed and not noticed the importance. But, now that this is getting more attention from people affected, it's clear this is a critical priority issue.

Please reevaluate the importance of this issue.

Matt Zimmerman (mdz)
description: updated
Brian Ealdwine (eode)
description: updated
Brian Ealdwine (eode)
description: updated
779 comments hidden view all 825 comments
Revision history for this message
In , Andrey (andrey-redhat-bugs) wrote :

TOSHIBA Satellite L30-113 notebook.
Intel Celeron 430M, ATI Radeon Xpress 200M.
Fedora 8.

== Increasing Load_Cycle_Count ==

[root@fedora ~]# smartctrl --all /dev/sda
[...]
Model Family: Hitachi Travelstar 5K100 series
Device Model: HTS541060G9SA00
Serial Number: MPBCPAXMGMV6PM
Firmware Version: MB3OC60R
User Capacity: 60,011,642,880 bytes
Device is: In smartctl database [for details use: -P show]
ATA Version is: 7
ATA Standard is: ATA/ATAPI-7 T13 1532D revision 1
Local Time is: Tue Nov 20 18:03:50 2007 VLAT
[...]

[root@fedora ~]# smartctl --all /dev/sda|grep -i count
  4 Start_Stop_Count 0x0012 100 100 000 Old_age Always
- 432
 10 Spin_Retry_Count 0x0013 100 100 060 Pre-fail Always
- 0
 12 Power_Cycle_Count 0x0032 100 100 000 Old_age Always
- 432
192 Power-Off_Retract_Count 0x0032 099 099 000 Old_age Always
- 211
193 Load_Cycle_Count 0x0012 090 090 000 Old_age Always
- 103707
196 Reallocated_Event_Count 0x0032 100 100 000 Old_age Always
- 1
199 UDMA_CRC_Error_Count 0x000a 200 253 000 Old_age Always
- 0

but a hour ago Load_Cycle_Count was: 103698

== ReiserFS or ...? ==

Day ago I leave my notebook on 30 minutes, and when I came back I was heard
that my HDD was buzzing!
[noisy like the sound of a bee; doing something hard]
I tried to do something, but Fedora don't respond.. even if I press Ctrl+Alt+F2
or Ctrl+Alt+Del..
I wait about 10 minutes..
I was forced to press and hold PowerOff button for 5 seconds for hard-shutdown..
When I turn on my laptop, I found something strange in /var/log/messages file:

Nov 19 22:09:23 fedora yum: Installed: unrar - 3.7.8-1.lvn8.i386
Nov 19 22:43:34 fedora kernel: ReiserFS: sda6: warning: vs-8115: get_num_ver:
not directory or indirect item
Nov 19 22:43:34 fedora kernel: ReiserFS: sda6: warning: vs-8115: get_num_ver:
not directory or indirect item

And before this Load_Cycle_Cont was about 96###, and after - 102### ...

Revision history for this message
In , Andrey (andrey-redhat-bugs) wrote :

I think I found solution to stop increasing Load_Cycle_Count.

]# hdparm -I /dev/sda|grep Advan
        Advanced power management level: 128 (0x80)
           * Advanced Power Management feature set

The solution:
]# hdparm -B 255 /dev/sda

/dev/sda:
 setting Advanced Power Management level to disabled

]# hdparm -I /dev/sda|grep Advan
        Advanced power management level: 254 (0xfe)
                Advanced Power Management feature set

Now Load_Cycle_Count stopped increasing!

Revision history for this message
In , Phil (phil-redhat-bugs) wrote :

Reassigning this bug to the kernel component as it's a bug in that component.

Read ya, Phil

Revision history for this message
In , Chuck (chuck-redhat-bugs) wrote :

That value is set by the system BIOS at power-on; we never change it. (Some
other distributions do, but not Fedora.)

Changed in acpi-support:
importance: Wishlist → Critical
Changed in acpi-support:
assignee: ubuntu-laptop → nobody
Przemek K. (azrael)
Changed in acpi-support:
status: New → Incomplete
Changed in acpi-support:
status: Incomplete → Confirmed
Changed in acpi-support:
status: Unknown → Fix Released
Changed in laptop-mode-tools:
status: Unknown → In Progress
Przemek K. (azrael)
Changed in pm-utils:
status: Confirmed → Unknown
Changed in pm-utils:
status: Unknown → Invalid
Brian Ealdwine (eode)
description: updated
Brian Ealdwine (eode)
description: updated
maor (maors)
description: updated
Brian Ealdwine (eode)
description: updated
Revision history for this message
In , Eric (eric-redhat-bugs) wrote :

Bug confirmed un a Toshiba Satellite A210-FS3

I coded the following script. Do not use without checking if the HD temperature
is not going too high. Here is the script that you can activate through
/etc/rc.d/rc.local :

==============

#! /bin/bash
#Utility that checks whether the APM level is at 254 if not, reset it there.

SLEEP="120"

while [ true ] ; do

STATE=`hdparm -I /dev/sda | grep "Advan" | sed "s/.* \([0-9][0-9][0-9]*\).*/\1/"`
ASTATE=`echo ${STATE:0:3}`

     if [[ $ASTATE != "254" ]] ; then
           hdparm -B 254 /dev/sda
     fi

sleep ${SLEEP}s
done

==============

It is useful since each time it comes back from suspend or hibernate the value
is set back at 128 so having such a script reset it back to 254 which prevents
the Load_Cycle_Count problem as noted above.

Hope this help.

Eric

Changed in acpi-support:
status: Confirmed → Triaged
assignee: nobody → ubuntu-kernel-acpi
Changed in laptop-mode-tools:
status: In Progress → Invalid
Changed in laptop-mode-tools:
status: Unknown → Confirmed
Changed in laptop-mode-tools:
status: Confirmed → In Progress
Changed in laptop-mode-tools:
status: In Progress → Confirmed
Changed in laptop-mode-tools:
status: Confirmed → Fix Released
Changed in laptop-mode-tools:
status: Fix Released → Confirmed
Chris Cheney (ccheney)
description: updated
description: updated
Chris Cheney (ccheney)
description: updated
Zaar Hai (haizaar)
Changed in dell:
status: New → Confirmed
ceg (ceg)
description: updated
ceg (ceg)
description: updated
Colin Watson (cjwatson)
Changed in acpi-support:
status: Triaged → Fix Released
Colin Watson (cjwatson)
Changed in acpi-support:
importance: Undecided → Critical
milestone: none → ubuntu-8.04.2
status: New → Triaged
Changed in dell:
importance: Undecided → Low
Nanley Chery (nanoman)
Changed in acpi-support:
status: Fix Released → In Progress
Steve Langasek (vorlon)
Changed in acpi-support:
status: New → Triaged
Changed in acpi-support:
status: In Progress → Fix Released
Steve Langasek (vorlon)
Changed in acpi-support:
importance: Undecided → Critical
Steve Langasek (vorlon)
Changed in acpi-support:
status: Triaged → In Progress
assignee: nobody → vorlon
assignee: nobody → vorlon
status: Triaged → In Progress
Martin Pitt (pitti)
Changed in acpi-support:
status: In Progress → Fix Committed
milestone: ubuntu-8.04.2 → none
status: In Progress → Fix Committed
Steve Langasek (vorlon)
Changed in acpi-support:
milestone: none → ubuntu-8.04.2
Steve Langasek (vorlon)
description: updated
Endolith (endolith)
description: updated
Colin Watson (cjwatson)
Changed in pm-utils:
assignee: nobody → vorlon
importance: Undecided → Critical
milestone: none → ubuntu-8.04.3
status: New → Triaged
Changed in acpi-support:
status: Fix Committed → Fix Released
status: Fix Committed → Fix Released
Steve Langasek (vorlon)
Changed in acpi-support:
status: Fix Released → In Progress
status: Fix Released → Triaged
Steve Langasek (vorlon)
Changed in acpi-support:
status: Fix Released → Triaged
Colin Watson (cjwatson)
Changed in acpi-support:
milestone: ubuntu-8.04.2 → none
status: In Progress → Fix Committed
Colin Watson (cjwatson)
Changed in acpi-support:
status: Triaged → Fix Committed
Changed in acpi-support:
status: Fix Committed → Fix Released
status: Fix Committed → Fix Released
Steve Langasek (vorlon)
Changed in acpi-support:
assignee: ubuntu-kernel-acpi → vorlon
Steve Langasek (vorlon)
Changed in linux-meta:
status: New → Invalid
status: New → Invalid
status: New → Invalid
Changed in acpi-support:
status: New → Fix Released
Changed in dell:
status: Confirmed → Fix Released
Changed in acpi-support:
status: Triaged → Fix Released
Changed in pm-utils:
status: New → Fix Released
Steve Langasek (vorlon)
Changed in pm-utils:
status: Triaged → In Progress
assignee: nobody → vorlon
importance: Undecided → Critical
status: New → In Progress
Martin Pitt (pitti)
Changed in pm-utils:
status: In Progress → Fix Committed
status: In Progress → Fix Committed
Changed in laptop-mode-tools (Mandriva):
status: Confirmed → Invalid
Martin Pitt (pitti)
tags: added: verification-done
removed: verification-needed
Changed in pm-utils (Ubuntu Hardy):
status: Fix Committed → Fix Released
Changed in pm-utils (Ubuntu Intrepid):
status: Fix Committed → Fix Released
37 comments hidden view all 825 comments
Revision history for this message
ethanay (ethan-y-us) wrote :

If the intention is to enable a apm setting of 128 when on battery, where is the rationale and evidence explaining how
1. it actually protects the hdd from shocks
2. it actually saves power
3. evidence (even anecdotal) of drives overheating otherwise

my understanding and experience is that Ubuntu software polls the hdd too frequently and cancels out #1 and #2 above, because the hdd parks and unparks again almost immediately. thus, there is no real shock protection and no power saving (maybe even increased power consumption due to unnecessary activity?), and in the absence of any heating issues (not a problem on AC, by the way?), it makes no sense whatsoever to use an apm value of 128 until software can be written with the standard of reduced polling frequency while on battery mode.

cheers,
ethan

Revision history for this message
Marcin Kowalczyk (qrczakmk) wrote : Re: [Bug 59695] Re: High frequency of load/unload cycles on some hard disks may shorten lifetime

On Jun 7, 2009 10:00 PM, "ethanay" <email address hidden> wrote:

If the intention is to enable a apm setting of 128 when on battery, where is
the rationale and evidence explaining how
1. it actually protects the hdd from shocks
2. it actually saves power
3. evidence (even anecdotal) of drives overheating otherwise

my understanding and experience is that Ubuntu software polls the hdd
too frequently and cancels out #1 and #2 above, because the hdd parks
and unparks again almost immediately. thus, there is no real shock
protection and no power saving (maybe even increased power consumption
due to unnecessary activity?), and in the absence of any heating issues
(not a problem on AC, by the way?), it makes no sense whatsoever to use
an apm value of 128 until software can be written with the standard of
reduced polling frequency while on battery mode.

cheers,
ethan

-- High frequency of load/unload cycles on some hard disks may shorten
lifetime https://bugs.launc...

Revision history for this message
ktulu77 (ktulu-highwaytoacdc) wrote :

Hi.

I have a XPS M1530 and I have the strange HD clicks 1 or 2 times per minutes.

I am on ubuntu 9.04 x64. I don't understand why this bug is marked as fixed.

I don't understand what I have to do to fix this problem. The bug report is huge. What can I do to save my HDD and do not lost my data ?

Revision history for this message
houstonbofh (leesharp) wrote : Re: [Bug 59695] Re: High frequency of load/unload cycles on some hard disks may shorten lifetime

ktulu77 wrote:
> Hi.
>
> I have a XPS M1530 and I have the strange HD clicks 1 or 2 times per
> minutes.
>
> I am on ubuntu 9.04 x64. I don't understand why this bug is marked as
> fixed.
>
> I don't understand what I have to do to fix this problem. The bug report
> is huge. What can I do to save my HDD and do not lost my data ?

The answer is to enable laptop mode. However, you point is valid that
you have to know to do this! So, I agree that this bug should not be
marked as "Fixed" if there is no intuitive way to know how to save your
drive.

Revision history for this message
George A (georgeabraham-ro) wrote :

The bug still exists in any ubuntu (9.04/9.10, x86) and I'm using a desktop computer with two WD6401AALS drives. Every minute, or every few minutes, four clicks occur. This is annoying to say the least, and if it will go on, I will simply walk away from linux. I have tried every solution (enabling laptop mode, setting hdparm -B 254/255), but the bug still persists. And I'm using a DESKTOP computer. F*ck. This is not fixed, but plaguing high and low.
Please, I need a solution other than going back to windows!

Revision history for this message
taka k. (scar) wrote :

i have been living with this problem for years, never occurred to me it could be resolved through software. i have a sony vaio pcg-tr3a with hitachi HTC426040G9AT00 disk drive. i don't think it keeps track of the load cycle with a human readable number, but it is definitely increasing:

$ date; sudo smartctl -a /dev/sda|grep Load_Cycle_Count
Fri Jan 29 00:43:37 MST 2010
193 Load_Cycle_Count 0x0032 011 011 000 Old_age Always - 9055335103588
scar@kovu:~$ date; sudo smartctl -a /dev/sda|grep Load_Cycle_Count
Fri Jan 29 00:47:17 MST 2010
193 Load_Cycle_Count 0x0032 011 011 000 Old_age Always - 9055351880805
$ date; sudo smartctl -a /dev/sda|grep Load_Cycle_Count
Fri Jan 29 00:56:07 MST 2010
193 Load_Cycle_Count 0x0032 011 011 000 Old_age Always - 9055368658022
$ date; sudo smartctl -a /dev/sda|grep Load_Cycle_Count
Fri Jan 29 00:56:32 MST 2010
193 Load_Cycle_Count 0x0032 011 011 000 Old_age Always - 9055385435239

i am using ubuntu 9.04 with acpi-support 0.121, and i have enabled laptop mode in /etc/default/acpi-support

it doesn't seem to have helped, but i understand it is only supposed to help when on battery power?

this laptop remains stationary and on AC power, so i would like to also hear about a solution for this scenario.

ceg (ceg)
description: updated
Revision history for this message
Jimmy Merrild Krag (beruic) wrote :

Just installed lucid. Still got lots of load cycling, even though I've turned stopping the hard drive off. Any (hopefully) helpful information I can post?

Revision history for this message
Jimmy Merrild Krag (beruic) wrote :

Oh yeah. Running Lucid 64 bit.

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

Please don't open new tasks against random projects without explanation and actual reasons. Thanks!

Changed in acpi-support:
status: New → Invalid
Changed in laptop-mode-tools (Mandriva):
status: Invalid → Unknown
Changed in laptop-mode-tools (Mandriva):
importance: Unknown → Critical
1 comments hidden view all 825 comments
Revision history for this message
Adam Porter (alphapapa) wrote :

I've been getting some of these LinkedIn spam invites lately, but how are they being sent to this bug's address? This is getting ridiculous.

Revision history for this message
Chow Loong Jin (hyperair) wrote : Re: [Bug 59695] Re: High frequency of load/unload cycles on some hard disks may shorten lifetime

On 05/05/2011 09:12, Adam Porter wrote:
> I've been getting some of these LinkedIn spam invites lately, but how
> are they being sent to this bug's address? This is getting ridiculous.
>

Probably from Gmail contact lists.

--
Kind regards,
Loong Jin

Revision history for this message
Grizzly (sven-witterstein) wrote :

Not sure if it's related or simply common knowledge - the WD EcoGreen "EARS" Advanced Format drives unter natty still park their heads every eight seconds.... smartctl in rc.local does lower the Load_Cycle_Count but does not fully help. There is a linux version of wdidle3 that also did not help much - so, there are still configurations after years with this problem...

Revision history for this message
theghost (theghost) wrote :

Same here on Ubuntu 11.04 Natty with a Western Digital Scorpio Blue. Every 7-8 seconds the load_cycle_count increases.

Additionally, ff I activate HDD spin down when running on battery in the power manager, I hear a clicking noise of my hdd every second. I can gurantee that this clicking sound is unsual, normally when parking the hdd's head. Deactivation of spin down setting helps, but load_cycle increases still every 7 seconds.

Based on this, it seems that there are still problems with the HDD management.

Revision history for this message
Andrzej Kłapeć (solidslash) wrote :

Unfortunately, the dirty fix of setting APM to 254 doesn't end this issue. My hard disk is WDC WD2500BEVT-75ZCT2 (Dell Studio 1555) and, on Ubuntu 11.04, it gets really hot on the default settings. (up to 50 C on idle and even 54 C when copy/pasting) The load_cycle_count doesn't seem to go up very fast though. Setting to, for example, 239 makes the temperature go lower but then the load_cycle_count increases like crazy. I mentioned the 239 value because I use it on Windows 7 by applying it by quietHDD and both the temperature and load_cycle_count problems are non-existent.
Isn't it affected anyhow by ext4 and how it uses the drive to read/write data? It seems to be using hdd all the time.

Revision history for this message
Adam Hallgat (hallgat) wrote :

Ocassionaly frequent load-unload cycles happens under Oneiric 11.10 Beta 1 usually when watching youtube.
This happened from 10.04 and up on every ubuntu distro. 10.04 clearly tried to kill my hard drive, fortunately the never versions are less cruel :) As I know there still isn't a 100% workaround for my hdd.

I'm using a NEC Versa one laptop without ( ACPI=off ) with the hdd below:

*-disk
                description: ATA Disk
                product: ST9120822AS
                vendor: Seagate
                physical id: 0.0.0
                bus info: scsi@2:0.0.0
                logical name: /dev/sda
                version: 3.AL
                serial: 5LZ7Z1VR
                size: 111GiB (120GB)
                capabilities: partitioned partitioned:dos
                configuration: ansiversion=5 signature=2bd2c32a

Revision history for this message
CLI (m-wichtowski) wrote :

I think the workaround for the problem is to install laptop-mode-tools and in /etc/laptop-mode/laptop-mode.conf change line:
BATT_HD_POWERMGMT=1
to
BATT_HD_POWERMGMT=254
This of course sets default disk APM to 254, but with laptop mode tools my WD Scorpio Blue 500GB stays pretty cool (about 43 degrees Celsius) and there is no idle drive "clicking" from now on. I've tested it on 11.04 and 10.04.
Maybe laptop-mode-tools should be installed by default on all laptops?

Revision history for this message
Adam Hallgat (hallgat) wrote :

I usually write hdparm -B 254 /dev/sda to the /etc/rc.local to set the APM 254 or 255, so if laptop-mode-tools only do the same unfortunately it won't be enough.

For example my harddrive is Seagate ST9120822AS. If you check https://wiki.ubuntu.com/DanielHahler/Bug59695
it shows there is no known safe APM setting exists to this hard drive. In the earlier Ubuntu distributions I tried both 254 and 255 but they didn't solve the problem for me.

For many hdd it shows solution but for mine and some others there isn't any known solution.

Revision history for this message
Yann (lostec) wrote :

6 Month ago I upgraded a previous 2.5" laptop internal WD Sata 320GB 5400rpm HDD for another WD (scorpio black?) 750GB 7200rpm:

cat /proc/scsi/scsi

labels it as:
WDC WD7500BPKT-0 Rev: 01.0

The 320GB one was responding to various "hdparm -B VALUE" values... with 254/255 shutting off spindown/unload completely...
The 750GB new one doesn't seems to care at all!

Ubuntu version unchanged (10.04), only disks copy (dd command with an USB adapter)/changed.

And unload seems more brutal and loud than previous device, maybe because of increased rpms.

For the moment, no problem with it... but the issue is probably with new HDD firmwares that does not take care of energy saving modes/values to exhibit good performance per watt figures in tests, whatever the test configuration/OS. Even if that may cause reliability problems.

Needless to say that booting windows partition does not change anything. That's not a linux problem.

Revision history for this message
Serhiy (xintx-ua) wrote :

It looks like WD BEVT-series was not mentioned here and the kernel.org is still down.
I just noticed huge Load_Cycle_Count on the WD1600BEVT-80A23T0. It almost reached 300 000 when I stopped it (299 252 to be precise) with
hdparm -B 255 /dev/sda
-B 254 didn't help, it just _ignored_ it.

Power_On_Hours is 2771 and that gives an average of 107 cycles per hour. Which is still very small compared to what I've heard today: it parks every 3-6 seconds (!) on the battery.

I didn't read all the comments (there is way too much of them) so if there was a better fix then disabling APM at all, please inform me.

FYI: it's an Asus T101MT notebook.

Revision history for this message
Andrzej Kłapeć (solidslash) wrote :

Guys, I don't want to jinx it but... about 5 hours ago I installed Ubuntu 12.04 alpha 2 on my laptop (WD2500BEVT hdd) and, without further configuring it (no changes to apm or anything like that) it WORKS. Just WORKS.
The temperature stays at 45'C and the load_cycle_count didn't increase even by one for these 5 hours! I'm shocked. I have no idea what's going on.
Now I'm moving to Ubuntu as my primary OS. Whoever contributed to this - thank you.

Revision history for this message
Brian Ealdwine (eode) wrote :

(!) really? ..wow.

Revision history for this message
Mikko Rantalainen (mira) wrote :

SolidSlash (solidslash): it might be that recent kernel tweaks for ACPI (and other power management) support may have triggered a fix for this issue. If that's true, any distribution with a recent enough linux kernel should be fine.

Revision history for this message
Joonas Saarinen (jza) wrote :

But the head parking is part of the normal drive operation. So why avoid it?

It's actually beneficial as it unloads the head, thus protecting the disk from shocks (and saving some power). Not a heavy operation like starting/stopping the disk.

Revision history for this message
Yves-Eric Martin (yem-launchpad-net) wrote :

@JoonasSaarinen

It is normal only if done not too frequently. Because otherwise, it can kill a drive. And that is not just theoretical, it can happen much more quickly than you may think: I had a drive with that issue, but very quiet so I did not notice. The result: the drive died in a catastrophic failure after only 5 months of operations (and over 800,000 Load_Cycle_Count!).

I don't think destroying itself in 5 months qualifies as "normal drive operations."

Revision history for this message
Santiago Roland (santiago-roland) wrote :

I gave to my wife a new Samsung N150 Plus Netbook last year. Last month the hard drive died but the warranty covered a new hard drive, so it was fine. Now with the new hard drive i was able to hear every 6 seconds that the heads are parking, and i tried many things and i cannot make it stop. Now i wonder the first hard drive (the one that died 1 months ago and my wife lost tons of data) died because of this bug. I know that this is an old bug now, but in this netbook is defenitly back and i tried adding this command in /etc/init.d

sudo hdparm -B 255 /dev/sda

even i tried to edit the laptop_mode.conf settings to do no power management in this hard drive and i had no luck, the packages had changed over the last versions of ubuntu and i do not know where to edit to disable this powr management. Now this hard drive has over 16000 load cycle counts and it keeps growing.

Anyone has starting to experience this? how do i stop this power management in order to save this drive because the netbook warranty just expired this month?

regards

Revision history for this message
Santiago Roland (santiago-roland) wrote :

I forgot to say that the version of ubuntu is 11.10 oneiric and the drive has 660 power on hours. he 6 seconds interval between parks is when using battery

12 comments hidden view all 825 comments
Revision history for this message
In , Dimitrios (dimitrios-redhat-bugs) wrote :

Dear all, may I request that you reopen this bug?

On Fedora 17 I get the following on a 2 year used hdd:

# smartctl -A /dev/sda | grep ^193
193 Load_Cycle_Count 0x0012 064 064 000 Old_age Always - 366975

My hard disk is a Hitachi HTS545025B9A300, and as seen in the datasheet at [1] the expected lifetime is 600K load cycles. So I argue that this *is* a bug for Fedora, and the proper fix would be to "smartctl -B 254" when on AC and "smartctl -B 128" when on battery. I think that's the fix implemented in Debian/Ubuntu, see [2].

[1] http://www.hgst.com/tech/techlib.nsf/products/Travelstar_5K500.B
[2] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=448673

If you are interested I can come up with a patch, it seems pretty simple, as I think the proper place for running hdparm would be "/etc/pm/{power,sleep}.d/, at least to take care of the AC/battery switching. Can someone inform me if these directories are appropriately scanned and executed when systemd boots the system, or different hooks (where?) would be needed for that case?

Changed in somerville:
importance: Undecided → Low
status: New → Fix Released
no longer affects: dell
11 comments hidden view all 825 comments
Revision history for this message
Timothy R. Chavez (timrchavez) wrote :

The bug task for the somerville project has been removed by an automated script. This bug has been cloned on that project and is available here: https://bugs.launchpad.net/bugs/1305705

no longer affects: somerville
Revision history for this message
Aaahh Ahh (woohoomoo2u) wrote :

Back at it in Ubuntu 15.10

Revision history for this message
Ryan Waldroop (ryan.waldroop) wrote :

Seriously? That's how many years? Come on!

On Thu, Aug 27, 2015 at 9:21 PM, Aaahh Ahh <email address hidden> wrote:

> Back at it in Ubuntu 15.10
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/59695
>
> Title:
> High frequency of load/unload cycles on some hard disks may shorten
> lifetime
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/acpi-support/+bug/59695/+subscriptions
>

Revision history for this message
Brian Ealdwine (eode) wrote :

Right? This is just sad.
On Aug 27, 2015 9:41 PM, "Ryan Waldroop" <email address hidden> wrote:

> Seriously? That's how many years? Come on!
>
> On Thu, Aug 27, 2015 at 9:21 PM, Aaahh Ahh <email address hidden>
> wrote:
>
> > Back at it in Ubuntu 15.10
> >
> > --
> > You received this bug notification because you are subscribed to the bug
> > report.
> > https://bugs.launchpad.net/bugs/59695
> >
> > Title:
> > High frequency of load/unload cycles on some hard disks may shorten
> > lifetime
> >
> > To manage notifications about this bug go to:
> > https://bugs.launchpad.net/acpi-support/+bug/59695/+subscriptions
> >
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/59695
>
> Title:
> High frequency of load/unload cycles on some hard disks may shorten
> lifetime
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/acpi-support/+bug/59695/+subscriptions
>

Revision history for this message
ethanay (ethan-y-us) wrote :
Revision history for this message
Nick B. (futurepilot) wrote :

What is your test case? Are you sure this is the same bug?

On Friday, August 28, 2015 01:21:14 AM Aaahh Ahh wrote:
> Back at it in Ubuntu 15.10

Revision history for this message
ethanay (ethan-y-us) wrote :
Download full text (9.5 KiB)

For me, it's that the OS leaves insane hardware mfr defaults of hdparm
-B=128 in place even on AC power. I believe this was fixed in 12.04 but is
back for some reason in 14.04 for me... Installing TLP changes to B=254 on
AC and retains the B=128 on battery (with the addition of clustering hdd
writes to help prevent excessive disk activity and thus load/unload
cycles), so provides essentially the same fix with added benefits of actual
power saving on battery

ethan

“A society grows great when its elders plant trees whose shade they know
they shall never sit in.” -- an ironic Greek proverb

On Sat, Aug 29, 2015 at 6:48 AM, Nick B. <email address hidden> wrote:

> What is your test case? Are you sure this is the same bug?
>
> On Friday, August 28, 2015 01:21:14 AM Aaahh Ahh wrote:
> > Back at it in Ubuntu 15.10
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/59695
>
> Title:
> High frequency of load/unload cycles on some hard disks may shorten
> lifetime
>
> Status in acpi-support:
> Invalid
> Status in acpi-support package in Ubuntu:
> Fix Released
> Status in linux-meta package in Ubuntu:
> Invalid
> Status in pm-utils package in Ubuntu:
> Fix Released
> Status in acpi-support source package in Hardy:
> Fix Released
> Status in linux-meta source package in Hardy:
> Invalid
> Status in pm-utils source package in Hardy:
> Fix Released
> Status in acpi-support source package in Intrepid:
> Fix Released
> Status in linux-meta source package in Intrepid:
> Invalid
> Status in pm-utils source package in Intrepid:
> Fix Released
> Status in acpi-support source package in Jaunty:
> Fix Released
> Status in linux-meta source package in Jaunty:
> Invalid
> Status in pm-utils source package in Jaunty:
> Fix Released
> Status in acpi-support package in Baltix:
> Fix Released
> Status in acpi-support package in Debian:
> Fix Released
> Status in pm-utils package in Fedora:
> Invalid
> Status in laptop-mode-tools package in Mandriva:
> Unknown
> Status in Suse:
> Fix Released
>
> Bug description:
> The kernel wiki gathers info about drives with too aggressive power
> saving defaults. A script called "storage-fixup" is also available.
>
> https://ata.wiki.kernel.org/index.php/Known_issues#Drives_which_perform_frequent_head_unloads_under_Linux
>
>
> This is not a support forum. Please do not use it as such (even though
> it has been used as such already).
>
> You can scan through the bug for links to the Ubuntu forums where
> many, many different questions have been asked, answered, and re-
> answered. The temporary workaround is just below.
>
> See https://wiki.ubuntu.com/PowerManagement for an overview about what
> is involved and for a remedy.
>
> SRU justification: current behavior may lead to premature disk failure
> in laptops due to excessive unnecessary drive parking. Fix will
> disable disk cycling by default when on AC power, by correcting an
> error in the hdparm logic of acpi-support.
>
> For jaunty, this issue is addressed in acpi-support 0.115.
>
> TEST CASE:
>
> 1. With acpi-support 0.109 (hardy) o...

Read more...

Changed in pm-utils (Fedora):
importance: Unknown → Medium
Displaying first 40 and last 40 comments. View all 825 comments or add a comment.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.