Re: [SLUG] process CPU use

From: Ian C. Blenke (ian@blenke.com)
Date: Fri May 12 2006 - 17:44:12 EDT


Eben King wrote:
> Is there a way to launch a process (or modify an existing one) to
> force it to use no more than X% of the CPU? With continual 100% use
> my CPU gets rather warm. Sure, I can "nice" it, but that only makes
> it more readily yield the CPU to other processes; if nothing else
> demands the CPU it'll still use 100%. Is the only solution in
> hardware, something like a Peltier device and a big honkin' heat sink?

The most "appropriate" way is to put your machine into a power saving mode.

You can use cpufreq to control the power saving of your CPU with
something like powernowd to control it via the /sysfs interface

While you _could_ change the CPU scheduler to ensure a process only get
some % of the CPU's time, it will still likely be running full power the
entire time (though with CPU halts between the scheduling bursts).
Honesty, fiddling with schedulers for CPU guarantees is something you
only do with something like vserver as a service provider to ensure no
customer can abuse their fair share of the hardware.

Look into ACPI for power saving modes and/or cpufreq for putting your
CPU into a lower speed power saving mode when you're not using it.

You don't need to have a laptop to use power saving features of modern
hardware.

- Ian C. Blenke <ian@blenke.com> http://ian.blenke.com/



-----------------------------------------------------------------------
This list is provided as an unmoderated internet service by Networked
Knowledge Systems (NKS). Views and opinions expressed in messages
posted are those of the author and do not necessarily reflect the
official policy or position of NKS or any of its employees.



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 18:55:06 EDT