processes:change_process_priority:change_process_priority
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
processes:change_process_priority:change_process_priority [2016/11/23 19:04] – peter | processes:change_process_priority:change_process_priority [2019/12/01 22:31] (current) – removed peter | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Processes - Change process priority ====== | ||
- | |||
- | Use **nice** and **renice** commands. -20 highest priority, | ||
- | |||
- | |||
- | ===== Start process at lowest priority ===== | ||
- | |||
- | <code bash> | ||
- | nice -n 19 ./ | ||
- | </ | ||
- | |||
- | |||
- | ===== Change priority of running process ===== | ||
- | |||
- | Assuming the PID of the process to change is 123: | ||
- | |||
- | <code bash> | ||
- | renice -1 123 | ||
- | </ | ||
- | |||
- | This will set the priority of process id no 2345 to -4, which will in turn increase its priority over others. | ||
- | |||
- | <code bash> | ||
- | renice -4 -p 2345 | ||
- | </ | ||
- | |||
- | |||
- | This will set the priority of the process id 3456 to 13, and all the process owned by user " | ||
- | <code bash> | ||
- | renice 13 -p 3456 -u john 15 | ||
- | </ | ||
- | |||
- | |||
- | This will set all process owned by " | ||
- | |||
- | <code bash> | ||
- | renice 14 -u john,peter -g custom | ||
- | </ | ||
processes/change_process_priority/change_process_priority.1479927899.txt.gz · Last modified: 2020/07/15 09:30 (external edit)