Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Here is the deal. When using 12.04 laptop runs so cool and quiet but immediately I plug in, the temperature of the Hard drive starts to go up. (hitting 60•C in no time). However when I unplug the AC cable, the temperature drops to normal levels (45-50•C). What could be done to correct this? Thanks in advance

HP PAVILION DV6700 Intel Core Duo 2.0Ghz 4gb RAM 250 GB HDD

Here are pastebins of hdparm and smartctl on my ubuntu partition sda3:

sudo smartctl -a /dev/sda3 (on battery)

sudo smartctl -a /dev/sda3 (on AC)

sudo hdparm -I /dev/sda3 (on battery)

sudo hdparm -I /dev/sda3 (on AC )

sudo hdparm -i /dev/sda3 (on battery)

sudo hdparm -i /dev/sda3 (on AC)

share|improve this question
    
Make sure your vents and fans are not clogged and working. –  psusi May 23 '12 at 19:23
1  
Vents are not clogged and fans are working well. HD ONLY overheats on AC so it ain't a fan/vent issue –  Mysterio May 23 '12 at 19:48
3  
In an effort to save battery power your system is probably spinning down the disk when not in use for some period of time. When on AC it may be keeping it spun up for maximum performance -- generating higher temp. I believe but can't confirm that Linux has configuration parameters for this. The default power preferences in 12.04 don't offer control of this to the user. I've seen but can't recall the source, power managers with more detailed control. That is where I'd look for a solution. –  fragos May 26 '12 at 21:17
    
If only I could change these parameters so the hard drive will behave exactly as it does on battery –  Mysterio May 26 '12 at 23:40
    
In my experience, heat issues generally boil down to electrical issues. How old is this laptop? –  Huckle May 28 '12 at 5:20
show 1 more comment

5 Answers 5

up vote 5 down vote accepted
+50

Here's the solution:

laptop-mode-tools is controlling power management for your hard drive, and you need to configure it appropriately for your situation.

Open /etc/laptop-mode/laptop-mode.conf for editing with root privileges, and around line 276 (on Ubuntu 12.04), change this value to 600

NOLM_HD_IDLE_TIMEOUT_SECONDS=7200

This is the amount of time before your drive is told to "spin down" or idle on AC power. 10 minutes with no read/write activity is reasonable.

And around lines 290-291 (on Ubuntu 12.04), change both these values to 1:

LM_AC_HD_POWERMGMT=254

NOLM_AC_HD_POWERMGMT=254

These set the power management level granted to the drive, with 1 being "full" power management, and 254 being "almost zero" power management. The latter setting is the reason for your temperatures, because you can set the level, but how the drive manages power at a level is entirely up to it -- it completely depends on the implementation in the drive's firmware, and can vary by model, manufacturer, etc.

With the changes, we are now telling the drive to perform the same power management it does while on battery (which is satisfactory for you). This is different from simply allowing the drive to spindown while on AC (as in @EliahKagan's answer), because that would still leave the drive's power management set to near zero at level 254.

How to determine power management level

To find out the current level, while on battery, AC, or any other situation:

sudo hdparm -I /dev/sda | grep Advanced (replace sda appropriately)

share|improve this answer
1  
Edited answer with further tests :) –  izx May 30 '12 at 19:56
    
No problem, depending on what works we can then make it persistent. –  izx May 30 '12 at 21:56
1  
That's expected because these only last until you switch the power source :) I'll post a persistent answer tonight. -B 1 enables HDD power management while -B 254 pretty much disables it. –  izx May 31 '12 at 15:35
1  
(don't do 1.9 tweak - leave the old values as you did, btw) –  izx Jun 1 '12 at 14:35
1  
darn, it's laptop-mode that's overriding the raw hdparm settings: if 1.99 doesn't work, edit /etc/laptop-mode/laptop-mode.conf and change NOLM_HD_IDLE_TIMEOUT_SECONDS=7200 to 60, LM_AC_HD_POWERMGMT=254 to 1 and NOLM_AC_HD_POWERMGMT=254 also to 1. Reboot and try -- THAT should do it. –  izx Jun 1 '12 at 14:49
show 11 more comments

Have you tried installing Jupiter? (http://www.webupd8.org/2011/09/jupiter-applet-finally-available-for.html)

set it continuously to 'power on demand' or 'power saving', maybe that spins down the HD

I have it on Precise Pangoling 12.04, works great (although i don't really have your overheating problem...)

Hope it helps

share|improve this answer
    
Jupiter & Powertop are both installed –  Mysterio May 29 '12 at 16:09
add comment

I would like to request you to test this on some other version of Ubuntu (like ubuntu 10.4 or 11.04 or 11.10 - you can use live version of those distro). If the problem still persists,

A. first check your earthing connection because improper earthing always leads to the overheating problem

B. check your A/C adapter because it may be damaged and causing hdd over heat while plugging into the ac source.

c. Check your laptop battery a failing battery caused the problem with the adapter because it could be attempting to "overcharge" the battery, which doesn’t increase the battery’s charge, but, rather radiates the charge as heat energy (this is what is causing your overheating).

i will ask you to remove your laptop battery and then plug it into ac source in-order to check the battery.

share|improve this answer
    
It took me 2 days to download 12.04 (crappy Internet access) but I will try it and report –  Mysterio May 27 '12 at 20:25
    
BTW it's super horrible in 11.10 I had to stay away from Ubuntu as the laptop was literally too hot to handle –  Mysterio May 27 '12 at 20:27
    
there are 3 possible reason which could be the result of your problem. i am adding them to my my answer, i hope this fix your problem. –  Arkaprovo Bhattacharjee May 28 '12 at 0:28
1  
@ArkaprovoBhattacharjee: Sorry, but to be brutally honest this sort of Electronics 101 advice is nonsense considering OP's question. (a) Almost every laptop AC adapter is a switching converter which has nothing to do with ground/earth -- in fact, a lot of them do have 2-pin plugs with no connection for ground/earth! (b) No AC adapter damage is going to only affect the hard drive causing "over heat" -- the only possible damage is overvoltage at the output, and the laptop/motherboard's own power conditioning will lead to either failing gracefully (shut down/refuse to start) (continued) –  izx May 28 '12 at 7:24
1  
@ArkaprovoBhattacharjee: (continued)... or ungracefully (something will fail, leaving laptop unable to start) (c) This is also a useless suggestion based on the situation described -- he is monitoring his HD temps, not his battery or overall system temps. The HD temp monitor (internal) is NEVER going to be affected so much by external heat (like a battery overcharging or whatever) to report almost instantaneous 10 deg C swings in temperature. –  izx May 28 '12 at 7:25
show 2 more comments

Charging your laptop battery generates heat. So when you plug in your AC power, and your laptop battery isn't fully charged (it's previously been running off battery), it will start charging the battery, thus generating heat.

This is why you usually get the fan spinning up when switching to AC power after being on battery, and inevitably the system components will heat up due to the heat from the battery.

The hard drive, being reasonably close to the battery, will probably heat up a bit too. This therefore is a plausible explanation of what you are observing.

There are other things that would cause your laptop to get warmer when it's on AC power, such as various components coming out of a "low power" mode, but the battery charging, IMHO, is a much more significant factor.

You say that your hard drive is "overheating" but only mention that it reaches 60 degrees. In reality, manufacturers usually list 60 degrees as the top of the "safe operating temperature" for 2.5 inch drives. Your laptop manufacturer will have designed your laptop's cooling system so that the most extreme situation (charging battery while stressing CPU, etc) should still cause all components to remain within their safe operating temperature. However, they make a number of assumptions. They assume that your room temperature is a certain value, that you're using the laptop on a solid, flat surface, its ventilation holes aren't blocked, etc. If it's 28 degrees inside and you have the laptop on your lap, then components will exceed their safe operating temperature. Similarly, if the fan fails or is blocked, then it will also.

It's also not unusual for laptops simply to run too hot because they have poor thermal design from the start.

The hard drive manufacturer will have given some "breathing room" in specifying 60 degrees as the top safe operating temperature, which will partially make up for non-ideal cooling situations. That is, if you go up to 65 it shouldn't be "too bad". You probably don't need to worry about imminent death of your laptop. But any heat will reduce the life of your components and the cooler the better. You should look into whether the fan is operating correctly, whether you're using the laptop in a hotter environment than a typical room temperature, and whether you have the laptop on a soft or warm surface or one which will press against the air vents. If using the laptop on your lap, get a solid tray/stand for it to sit on. Some companies sell these with built-in cooling fans which I think is overkill.

share|improve this answer
2  
What I'm looking for is to make the Hard Drive behave like it does on battery when using the AC. –  Mysterio May 28 '12 at 14:28
    
Behave in what way? Your original question only mentions the heat issue which I've written about above. Do you want to clarify? –  neon_overload May 28 '12 at 16:02
    
Meant how cool the temperature is on battery. I want that when running on AC –  Mysterio May 28 '12 at 23:31
    
With all due respect, did you read my above answer at all? –  neon_overload May 29 '12 at 1:59
1  
How do you propose that this heat is generated then? By a fault in the hard drive that somehow manifests when the laptop is on AC power? I'm almost certain it'll simply just be heat from the battery charging. It won't be instantaneous, but it'll be noticeable within minutes. –  neon_overload May 29 '12 at 6:53
show 10 more comments

To enable hard drive spindown even when running on AC power, press Alt+F2, and run this command:

gconf-editor /apps/gnome-power-manager/disks

This will open the Configuration Editor and bring you directly to the options for automatically spinning down disks. Make sure spindown_enable_ac is checked as well as spindown_enable_battery.

share|improve this answer
    
Are there any potential negative effects with this tweak? –  Mysterio May 28 '12 at 23:43
    
@Mysterio I'm not aware of any negative effects of spinning down when running from AC power, that would not also apply to spinning down when running from battery. As for spindown generally, theoretically spinning your hard drives down (an back up again) frequently could shorten their life by putting more wear on the motor...if they spin up and down a lot. (Otherwise, it should make them last longer, because the motor is not running as much.) The only real caveat I can think to add to this tweak is that I am not 100% certain it'll work, as there may be other factors preventing spindown. –  Eliah Kagan May 29 '12 at 0:23
    
Thanks for the info. It's half past midnight over here so I'll try it out and report in the morning. Hope it works :) –  Mysterio May 29 '12 at 0:28
    
I would be cautious about this given this bug report. Lower-level APM/acoustic tweaking (see my answer) may achieve similar results without setting AC spindown to the same value as battery spindown. –  izx May 29 '12 at 13:27
1  
@EliahKagan : I'm trying to take the low-level approach to your high-level, trying to explicitly set hdparm settings triggered on AC to those that are triggered on battery, or similar, to come up with a temp/performance balance the OP finds acceptable :-) –  izx May 29 '12 at 15:39
show 3 more comments

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.