CPU Isolation
Andrey V. Elsukov
bu7cher at yandex.ru
Mon Jan 28 21:05:00 UTC 2019
On 28.01.2019 22:25, Mark Saad wrote:
> All
> Thanks for the replies, I had experimented with the init script
> method but ; I kept thinking that I was doing this wrong. I think that
> adding a loader option to
> isolate cpus from the scheduler would be useful; but I have no idea
> how to get there. My current plans are to setup init to use cpus 0-4
> and to use 5-7 for my applications
> and see how it goes. The other test I want to try is to run some
> kernel threads on dedicated cores. Let me try to break stuff now.
As r331723 says, now kernel threads belong to cpuset #2, all other
processes belong to cpuset 1. So, you can try to use commands:
Limit all userlevel application to use only CPU cores 0-4:
# cpuset -s 1 -l 0-4
Limit kernel level threads to use CPU only CPU cores 0-4:
# cpuset -s 2 -l 0-4
and then dedicate CPUs 5-7 for your application with pid PID
# cpuset -l 5-7 -p PID
--
WBR, Andrey V. Elsukov
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 554 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-hackers/attachments/20190129/fb8e58ef/attachment.sig>
More information about the freebsd-hackers
mailing list