I created a 'music' CPU Set and allocate MPD and vollibrespot to it.
Here's the script to create the 'music' CPU Set, install 'cset' and allocate CPU 0 to 'music', which just needs to be run once after installing Volumio:
Code: Select all
mkdir /sys/fs/cgroup/cpuset/music
apt-get update
apt-get install cpuset
cset set -c 0-0 music
cset set -m 0-0 music
Code: Select all
pids=$(pgrep -x mpd)
for pid in $pids
do
chrt -r -p 99 $pid
cset proc --move --threads --toset=music --force --pid=$pid
done
pids=$(pgrep -x vollibrespot)
for pid in $pids
do
chrt -r -p 99 $pid
cset proc --move --threads --toset=music --force --pid=$pid
done