chrt
chrt
The chrt
command in Linux can be used to change the scheduling policy of a process. The scheduling policy is the way that the processor time is allocated to a process.
To use the chrt
command, you use the following syntax:
policy
is the scheduling policy for the process.priority
is the priority of the process.pid
is the process ID.
policy
has the following options:
BE
: Background priorityRT
: Real-time priorityFIFO
: First-in, first-out priorityRR
: Round-robin priority
priority
can be a value from 0 to 99. The higher the value, the higher the priority of the process.
pid
is the process ID. You can find the process ID using the ps
command.
For example, to change the scheduling policy of the firefox
process with PID 1234 to background priority, you would use the following command:
To change the priority of the firefox
process with PID 1234 to 10, you would use the following command:
The chrt
command can be used to change the scheduling policy of a process to improve the performance of the process.
help
Last updated