taskset Command Examples

Get or set a process' CPU affinity or start a new process with a defined CPU affinity. More information: https://manned.org/taskset.

taskset {{[-p|--pid]}} {{[-c|--cpu-list]}} {{pid}}

taskset {{[-p|--pid]}} {{[-c|--cpu-list]}} {{cpu_id}} {{pid}}

taskset {{[-c|--cpu-list]}} {{cpu_id}} {{command}}

taskset {{[-c|--cpu-list]}} {{cpu_id_1}},{{cpu_id_2}},{{cpu_id_3}}

taskset {{[-c|--cpu-list]}} {{cpu_id_1}}-{{cpu_id_4}}