views:

68

answers:

1

I need to run two programs on the same core of a CPU. The second one always runs on another core because the first program uses 50% of the first core. How can I force Linux to run a program on a core?

+2  A: 
schedtool -a 0x1 -e program1
schedtool -a 0x1 -e program2

See schedtool manual for details.

Roman Cheplyaka
As i can see, this tool sets affinity of already running process (or am i wrong?). I need some tool to be able to start process on the determined CPU core.
dscTobi
No, it allows to start processes using `-e` flag. Oops, missed the flag in my example, now fixed.
Roman Cheplyaka