System extremely slow under light load
freebsd at chillt.de
Mon Apr 25 23:03:04 UTC 2011
> If you boot into another operating system such as Linux or Windows, do
> you see the same overall behaviour? Linux might be easier and might
> have some built-in way to get at CPU temperatures (via /proc?).
I finally found a working USB Linux image and have run some tests:
Linux power management is quite different from FreeBSD. It clocks all
cores at 933 MHz by default. When I start exercising the CPU, only the
cores actually working hard get clocked up all the way to 1.7 GHz. This
seems like a good idea but is not possible on FreeBSD right now as the
only frequency sysctl is dev.cpu.0.freq.
With the CPU idling at 933 MHz, the temperature is about 68°C. I am
running FreeBSD with powerd -M 933 right now and the CPU is idling at
76°C while being clocked down to about 200 MHz most of the time. So
Linux does something better here and manages to shave off about 10°C.
As recommended by Kevin, I tried running md5 on a large chunk of data. I
chose a Linux ISO file instead of /dev/random output to have
reproducible input. Under FreeBSD, the machine currently is not sluggish
and an md5 run completes in 5.7 seconds. I will retry the md5 experiment
when the box becomes sluggish and will see whether I can detect TCC
kicking in. Under Linux, the same md5 run took 12.6 seconds. This is
surprising on the one hand as Linux clocked up all the way to 1.7 GHz
while under FreeBSD, I was limiting the CPU to 1.199 GHz. On the other
hand, Linux was running from a USB key while FreeBSD is properly installed.
I tried running multiple copies of md5 in parallel to exercise multiple
cores to the maximum under Linux. This actually made the temperature
climb very quickly up to 95°-98°C. At 95°C, the fan audibly switched
into a higher gear. I now remember that I have heard this under FreeBSD
before as well. The fan seems to be controlled by the BIOS after all so
when the CPU reaches 95°C, the BIOS turns up the fan, irrespective of
the OS I am running.
The great difference between FreeBSD and Linux was that I did not get
any of the sluggishness and non-interactive response. Even under high
load with a CPU temperature of 95°C and the fan in high gear, KDE was
responsive and usable. I did have a few system stalls but according to
the console, those were due to problems with reading from the USB key.
There seemed to be no sudden breakdown of interactive performance even
under load and thermal stress. So something is off under FreeBSD...
More information about the freebsd-stable