tuned icon indicating copy to clipboard operation
tuned copied to clipboard

RFE: Introduce plugin for cores isolation

Open yarda opened this issue 7 years ago • 4 comments

At the moment Tuned uses Tuna for cores isolation, but it's not flexible enough. It would be better to have this functionality in Tuned plugin (CPU plugin?, scheduler plugin?, or different plugin?). It would provide better performance and flexibility for e.g. process whitelisting.

yarda avatar Mar 27 '17 13:03 yarda

I used the scheduler plugin in a whitepaper to do core affinity for a netperf test. It needs more flexibility, and at least to me the syntax was a bit difficult. If you look at /etc/rtgroups syntax, I bet we need something similar.

Look at the syntax of this file. It lets you create a comprehensive map of both user and kernel threads.

This tuning was laid down by the rtctl system service.

kthreads:*:1:*:\[.*\]$
watchdog:f:99:*:\[watchdog.*\]
migration:f:99:*:\[migration\/.*\]
softirq:f:70:*:\[.*(softirq|sirq).*\]
softirq-net-tx:f:75:*:\[(softirq|sirq)-net-tx.*\]
softirq-net-rx:f:75:*:\[(softirq|sirq)-net-rx.*\]
softirq-sched:f:1:*:\[(softirq|sirq)-sched\/.*\]
rpciod:f:65:*:\[rpciod.*\]
lockd:f:65:*:\[lockd.*\]
nfsd:f:65:*:\[nfsd.*\]
hardirq:f:85:*:\[(irq|IRQ)[\-_/].*\]

https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_MRG/1.3/html/Realtime_Tuning_Guide/chap-Realtime_Tuning_Guide-Realtime_Specific_Tuning.html#sect-Realtime_Tuning_Guide-Realtime_Specific_Tuning-Setting_Scheduler_Priorities

jeremyeder avatar Mar 27 '17 14:03 jeremyeder

IIRC we have created scheduler plugin syntax according to /etc/rtgroups. I.e. the only difference should be that the group name starts with 'group.'

yarda avatar Mar 27 '17 14:03 yarda

I checked our IRC logs, and you're right, we did. Your memory is better than mine :+1:

jeremyeder avatar Mar 27 '17 14:03 jeremyeder

Am I missing something, or do the isolated_cores, ps_blacklist and ps_whitelist options of the scheduler plugin provide the required functionality? These have been introduced in commit ac78f90c773cc97573844f521c2f67291f15d354.

olysonek avatar Mar 07 '19 10:03 olysonek