# Dell laptop overheats while compiling



## zodias (Jul 8, 2012)

Hi,

I installed 9.0-RELEASE on Dell Inspiron n5010 and downloaded sources to build 9-STABLE. While building the world the laptop is shut down by FreeBSD for reaching high CPU operating temperature.
I added:

```
powerd_enable="YES"
powerd_flags="-a maximum -b adaptive -i 85 -r 60 -p 100"
```
in /etc/rc.conf, did 
	
	



```
# /etc/etc/powerd restart
```
 but with no effect.

What am I missing? Is there a possibility to control a CPU fan speed in FreeBSD?


----------



## jrm@ (Jul 9, 2012)

Are you blocking any of the air vents?  You might try opening up the laptop and checking if there is excessive dust.  Are all fans working properly?


----------



## zodias (Jul 9, 2012)

jrm said:
			
		

> Are you blocking any of the air vents?  You might try opening up the laptop and checking is there is excessive dust.  Are all fans working properly?



It is clean and works great with MS Windows 7 Home Premium.


----------



## jrm@ (Jul 9, 2012)

Even if you push the CPU in Windows by, e.g., compiling something large you don't get the overheating?


----------



## zodias (Jul 9, 2012)

jrm said:
			
		

> Even if you push the CPU in Windows by, e.g., compiling something large you don't get the overheating?



That's right. I don't get the overheating in MS Windows 7 when executing 
	
	



```
# make -j8 buildworld
```
 in VirtualBox-ed FreeBSD.


----------



## jrm@ (Jul 9, 2012)

You could try monitoring CPU frequency, temperature and fan speed in both windows and FreeBSD.  Also, have a look at sysctl().  For example, on my old IBM laptop I see variables such as dev.acpi_ibm.0.fan_speed and hw.acpi.thermal.tz0.temperature.


You might have acpi issues preventing your fan from speeding up when it should.


----------



## wblock@ (Jul 9, 2012)

Remove -i 85 -r 60 -p 100 from powerd_flags and try again.  Otherwise, it's probably ACPI problems as jrm suggests, and the freebsd-acpi mailing list is the place to go.


----------



## zodias (Jul 10, 2012)

wblock@ said:
			
		

> Remove -i 85 -r 60 -p 100 from powerd_flags and try again.  Otherwise, it's probably ACPI problems as jrm suggests, and the freebsd-acpi is the place to go.



I tried, but with no effect.

```
Jul 10 15:28:15 localhost root: WARNING: system temperature too high, shutting down soon!
Jul 10 15:28:18 localhost kernel: acpi_tz0: WARNING - current temperature (88.1C) exceeds safe limits
```

However I noticed this in dmesg:

```
Jul 10 15:06:18 localhost kernel: ACPI APIC Table: <DELL   WN09    >
Jul 10 15:06:18 localhost kernel: FreeBSD/SMP: Multiprocessor System Detected: 4 CPUs
Jul 10 15:06:18 localhost kernel: FreeBSD/SMP: 1 package(s) x 2 core(s) x 2 SMT threads
Jul 10 15:06:18 localhost kernel: cpu0 (BSP): APIC ID:  0
Jul 10 15:06:18 localhost kernel: cpu1 (AP): APIC ID:  1
Jul 10 15:06:18 localhost kernel: cpu2 (AP): APIC ID:  4
Jul 10 15:06:18 localhost kernel: cpu3 (AP): APIC ID:  5
[B]Jul 10 15:06:18 localhost kernel: ACPI Warning: 32/64X FACS address mismatch in FADT - 0xB762CF4[/B]
0/0x00000000B762CF80, using 32 (20110527/tbfadt-517)
Jul 10 15:06:18 localhost kernel: ioapic0 <Version 2.0> irqs 0-23 on motherboard
Jul 10 15:06:18 localhost kernel: kbd1 at kbdmux0
Jul 10 15:06:18 localhost kernel: acpi0: <DELL WN09   > on motherboard
Jul 10 15:06:18 localhost kernel: acpi0: Power Button (fixed)
```


----------



## jrm@ (Jul 10, 2012)

Most laptops will have some acpi warnings.  Have you seen Using and Debugging FreeBSD ACPI?  It directs you to the same mailing list @wblock suggested.


----------



## zodias (Jul 10, 2012)

I just restricted the maximum CPU frequency to 1,6GHz in /etc/rc.conf:


```
powerd_flags="-a adaptive -b minimum -M 1600"
```

Now the laptop is doing 

```
# make -j8 buildworld && make -j8 buildkernel
```
and the temperature is between 60 and 70 grades in Celsius.

```
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 66,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 62,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 62,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 65,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 61,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 62,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 68,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 68,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 68,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 68,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 68,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 68,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 68,5C
localhost# sysctl hw.acpi.thermal.tz0.temperature
hw.acpi.thermal.tz0.temperature: 66,5C
localhost#
```


----------



## da1 (Jul 18, 2012)

My Lenovo T420s goes to 97 degrees when compiling world .


----------



## SR_Ind (Jul 18, 2012)

zodias,

There are couple of old threads reporting this issue.

It is FreeBSD 9 only problem. I used to have this problem when running FreeBSD 9. This issue seem to have disappeared in FreeBSD 10.

Interestingly, I used think that HP/Compaq laptops are affected. But thread indicates even Dell and Lenovo users are affected.


----------

