Re: Limit CPU usage of a process?

2018-05-30 Thread Kevin Chadwick
On Wed, 30 May 2018 11:49:04 +0200 > Are these commandline options or stuff you have to program into your > apps? They also seem to be more geared towards giving different > processes different priorities of which gets to use the highest CPU. > You could set your processor performance low with

Re: Limit CPU usage of a process?

2018-05-30 Thread BergenBergen BergenBergen
Are these commandline options or stuff you have to program into your apps? They also seem to be more geared towards giving different processes different priorities of which gets to use the highest CPU. This doesn't seem to be very helpful for us who are looking for a simple commandline option

Re: Limit CPU usage of a process?

2018-05-29 Thread Raul Miller
There's https://man.openbsd.org/nice.1 You might be describing https://man.openbsd.org/setrlimit.2 or the ulimit shell builtin (ulimit -t). But you might not want what you are describing, if that is the case. -- Raul On Tue, May 29, 2018 at 2:35 PM, BergenBergen BergenBergen wrote: > Browser

Re: Limit CPU usage of a process?

2018-05-29 Thread BergenBergen BergenBergen
Browser or not, how *does* one cap CPU resources though? I think it's a very interesting question, and I'm sorta baffled by the fact that the demand for this kinda thing hasn't been any higher. All the best, Murk On Tue, May 29, 2018 at 8:10 PM, Dumitru Mișu Moldovan wrote: > On 05/27/18

Re: Limit CPU usage of a process?

2018-05-29 Thread Dumitru Mișu Moldovan
On 05/27/18 13:07, Maximilian Pichler wrote: Is it possible to limit the CPU usage of a given process to, say, 20%? I'd like to slow down the web browser since it is draining my laptop's battery. With enough tabs open it's often consuming ~50% of CPU but not doing anything productive.

Re: Limit CPU usage of a process?

2018-05-27 Thread Tom Smyth
would the renice command be of any use ... to change the priority of the process ? On 27 May 2018 at 22:09, BergenBergen BergenBergen wrote: > I'd much rather prefer a generic tool that could limit any process, rather > than trying to come up with ways to strip down

Re: Limit CPU usage of a process?

2018-05-27 Thread e
On 05/27/2018 10:02 PM, Kevin Chadwick wrote: Umatrix is a good javascript control extension. Some websites are even running bitcoin mining without asking your permission. Theft of electricity in my book. Once I encountered a mining site. The mining itself got annoying pretty fast. The

Re: Limit CPU usage of a process?

2018-05-27 Thread BergenBergen BergenBergen
I'd much rather prefer a generic tool that could limit any process, rather than trying to come up with ways to strip down ones browser. FreeBSD has a cpulimit (https://github.com/opsengine/cpulimit/) port, and it would be nice if OpenBSD could too. I'm not skilled enough to make one, but I'd

Re: Limit CPU usage of a process?

2018-05-27 Thread Consus
On 20:02 Sun 27 May, Kevin Chadwick wrote: > Umatrix is a good javascript control extension. Some websites are even > running bitcoin mining without asking your permission. Theft of > electricity in my book. Hell, javascript itself is a theft of electricity.

Re: Limit CPU usage of a process?

2018-05-27 Thread Kevin Chadwick
Umatrix is a good javascript control extension. Some websites are even running bitcoin mining without asking your permission. Theft of electricity in my book.

Re: Limit CPU usage of a process?

2018-05-27 Thread Thomas Huber
ksh(1) has ulimit comand to limit process in certain way. just search for ulimit on the ksh man-page. On 27 May 2018 at 18:28, Luke A. Call wrote: > I had that problem but turning off javascript (as someone else said), > turning off images most of the time, and bookmarking

Re: Limit CPU usage of a process?

2018-05-27 Thread Luke A. Call
I had that problem but turning off javascript (as someone else said), turning off images most of the time, and bookmarking the tab group then closing as many tabs as I wasn't actually going to use soonest (especially any viewing PDF files), dropped it down to ~4%. On 05-27 12:07:16+0200,

Re: Limit CPU usage of a process?

2018-05-27 Thread BergenBergen BergenBergen
Have a look at http://openbsd-archive.7691.n7.nabble.com/Port-request-cpulimit-td267083.html and please let me know how it went! All the best, Murk On Sun, May 27, 2018 at 12:07 PM, Maximilian Pichler < maxim.pich...@gmail.com> wrote: > Is it possible to limit the CPU usage of a given process

Re: Limit CPU usage of a process?

2018-05-27 Thread justina colmena
On May 27, 2018 2:07:16 AM AKDT, Maximilian Pichler wrote: >Is it possible to limit the CPU usage of a given process to, say, 20%? > >I'd like to slow down the web browser since it is draining my laptop's >battery. With enough tabs open it's often consuming ~50% of CPU

Limit CPU usage of a process?

2018-05-27 Thread Maximilian Pichler
Is it possible to limit the CPU usage of a given process to, say, 20%? I'd like to slow down the web browser since it is draining my laptop's battery. With enough tabs open it's often consuming ~50% of CPU but not doing anything productive. Apparently with RLIMIT_CPU in setrlimit(2) the total CPU