mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-03-07 10:57:09 +00:00
Update cheatsheets
This commit is contained in:
@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Get a running process' CPU affinity by PID:
|
||||
|
||||
`taskset --pid --cpu-list {{pid}}`
|
||||
`taskset {{[-p|--pid]}} {{[-c|--cpu-list]}} {{pid}}`
|
||||
|
||||
- Set a running process' CPU affinity by PID:
|
||||
|
||||
`taskset --pid --cpu-list {{cpu_id}} {{pid}}`
|
||||
`taskset {{[-p|--pid]}} {{[-c|--cpu-list]}} {{cpu_id}} {{pid}}`
|
||||
|
||||
- Start a new process with affinity for a single CPU:
|
||||
|
||||
`taskset --cpu-list {{cpu_id}} {{command}}`
|
||||
`taskset {{[-c|--cpu-list]}} {{cpu_id}} {{command}}`
|
||||
|
||||
- Start a new process with affinity for multiple non-sequential CPUs:
|
||||
|
||||
`taskset --cpu-list {{cpu_id_1}},{{cpu_id_2}},{{cpu_id_3}}`
|
||||
`taskset {{[-c|--cpu-list]}} {{cpu_id_1}},{{cpu_id_2}},{{cpu_id_3}}`
|
||||
|
||||
- Start a new process with affinity for CPUs 1 through 4:
|
||||
|
||||
`taskset --cpu-list {{cpu_id_1}}-{{cpu_id_4}}`
|
||||
`taskset {{[-c|--cpu-list]}} {{cpu_id_1}}-{{cpu_id_4}}`
|
||||
|
||||
Reference in New Issue
Block a user