Tuesday 29 June 2010

Setting processor affinity

http://www.cyberciti.biz/tips/setting-processor-affinity-certain-task-or-process.html


apt-get install schedutils

taskset -c -p 1 13545

where 1 is the core number and 13545 is the process ID number.

To launch a program on core 3:

taskset -c 3 python

for example.

---------- Tips ----------

$ top

and press `1' to get SMP view, showing per processor results.

$ taskset -p 12345

returns the affinity of process 12345

No comments:

Post a Comment