Right before I start, I say sorry. I know It’s a little off topic, but didn’t find a better place for my question. Second, I know, I shouldn’t have done that, but I used pamac with sudo.
I did that to install amarok, which didn’t work either with yay nor with pamac, but worked just fine using pamac with sudo.
I had htop running while building the package and installing it. I like to do that, just for getting to know my stuff better. At least I am still learning Linux an IT in general. I watched the CPU workload and witnessed the following: When I tried to install amarok with yay or pamac without sudo, all 14 cores (all 20 threads) were at 100% all the time. When I used sudo pamac all cores were at less then 5% permanently. I repeated the whole thing several times. Allways the same. Can anyone explain that to me?
(base) [timok@VivoLinux ~]$ grep "MAKEFLAGS" /etc/makepkg.conf
MAKEFLAGS="-j2"
#-- If using DistCC, your MAKEFLAGS will also need modification. In addition,
(base) [timok@VivoLinux ~]$ grep "MAKEFLAGS" $HOME/.makepkg.conf
MAKEFLAGS="-j$(($(nproc)+1))"
#-- If using DistCC, your MAKEFLAGS will also need modification. In addition,
You are telling the compiler to use one more processor core than what you actually have
with:
This is even often recommended, but also can lead to failures - as you learned.
Use a lower, safer number (like the default MAKEFLAGS="-j2")
or give it the number of actual cores that your processor has got as a maximum.
That lower number will not saturate the processor cores but of course will make the compilation take longer.