Tag Info

Hot answers tagged

11

What does a niceness of (-) indicate? Notice those also have a PRI score of -100; this indicates the process is scheduled as a realtime process. Realtime processes do not use nice scores and always have a higher priority than normal ones, but still differ with respect to one another. You can view details per process with the chrt command (e.g. chrt -p ...


5

To quote Robert Love: The scheduler does not magically know whether a process is interactive. It requires some heuristic that is capable of accurately reflecting whether a task is I/O-bound or processor-bound. The most indicative metric is how long the task sleeps. If a task spends most of its time asleep it is I/O-bound. If a task spends more ...


4

@Goldlilock's answer directed me to do the research in the right path. This is my research details. Scheduling Algorithms available for processes Linux supports 3 scheduling policies. SCHED_FIFO, SCHED_RR, and SCHED_OTHER. SCHED_OTHER is the default universal time-sharing scheduler policy used by most processes; SCHED_FIFO and SCHED_RR are intended for ...


4

I am wondering why top and htop don't display -100 for higest priority real time processes ? That's because SCHED_RR and SCHED_FIFO have fixed static priorities from 1-99: Source For realtime priorities, the order is reversed: 99 is indeed the highest one, contrary to the ususal "lower is higher". Per your comment I misunderstood your question, ...


4

Under Linux, by default, a process's IO priority is derived from its CPU priority according to the formula io_priority = (cpu_nice + 20) / 5 IO priority ranges from 0 to 7 with 0 being the highest priority. CPU niceness ranges from -20 to 19 with -20 being the highest priority. You can use the ionice command to change a process's IO priority. If you want ...


3

Have a look at cgroups, it should provide exactly what you need - CPU reservations (and more). I'd suggest reading controlling priority of applications using cgroups. That said, put the important yet often idle processes into group with allocated 95% of CPU and your other applications into another one with allocated 5% - you'll get (almost) all of the power ...


2

I suspect that the most common use case is when you start a program with the default priority, then realize that you meant to run it with a low priority. renice can also be useful if there are certain times when you want to give certain programs a higher priority (e.g. to give the logged-in user's programs a higher priority than that of other users'), but ...


1

Typically I've only looked at renice when there is a potentially long running process that could bog down the system. For instance when running ffmpeg video conversions I renice those processes so that it doesn't bog down apache for serving web requests. Now in a proper environment the ffmpeg conversions would be running on another server and could not ...


1

As a component of the kernel, the process scheduler, makes the decisions to divide up processor time between processes on a given system using a priority-based scheduling algorithm. Starting with an initial base or default priority of zero (I believe) the scheduler can dynamically increase or decrease priority to fulfill scheduling objectives based on ...


1

In order to make your CPU use less battery, you need it to run slower. The total amount of CPU instructions needed to execute your program do not depend on the speed at which it runs, so limiting the proportion of CPU time used by your program would make it use more CPU, not less. When your CPU is doing nothing instead of running your program, it's still ...



Only top voted, non community-wiki answers of a minimum length are eligible