Otherwise, a process running on isolated CPUs will be interrupted by timers or unwanted VM exists. Resolves: rhbz#1395855 Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
30 lines
848 B
Bash
Executable file
30 lines
848 B
Bash
Executable file
#!/bin/sh
|
|
|
|
. /usr/lib/tuned/functions
|
|
|
|
start() {
|
|
python /usr/libexec/tuned/defirqaffinity.py "remove" "$TUNED_isolated_cores_expanded" &&
|
|
tuna -c "$TUNED_isolated_cores_expanded" -i
|
|
sed -i '/^IRQBALANCE_BANNED_CPUS=/d' /etc/sysconfig/irqbalance
|
|
echo "IRQBALANCE_BANNED_CPUS=$TUNED_isolated_cpumask" >>/etc/sysconfig/irqbalance
|
|
setup_kvm_mod_low_latency
|
|
return "$?"
|
|
}
|
|
|
|
stop() {
|
|
tuna -c "$TUNED_isolated_cores_expanded" -I &&
|
|
python /usr/libexec/tuned/defirqaffinity.py "add" "$TUNED_isolated_cores_expanded"
|
|
if [ "$1" = "profile_switch" ]
|
|
then
|
|
sed -i '/^IRQBALANCE_BANNED_CPUS=/d' /etc/sysconfig/irqbalance
|
|
teardown_kvm_mod_low_latency
|
|
fi
|
|
return "$?"
|
|
}
|
|
|
|
verify() {
|
|
python /usr/libexec/tuned/defirqaffinity.py "verify" "$TUNED_isolated_cores_expanded"
|
|
return "$?"
|
|
}
|
|
|
|
process $@
|