I’ve recently installed manjaro after coming from OpenSuse and to a lesser extend kde neon (aka Ubuntu 22.04).
I got my build environment setup, but when compiling a large program, eg ardupilot, any audio that is running, eg spotify, teams, vlc… , begins to stutter before eventually just crapping out.
In this case the build environment uses waf to spawn multiple compilation threads (gcc/g++).
This occurs even if I limit the number of cpu’s that the compilation takes, i.e. nproc reports 16 processors, so if I limit the multiprocess compilations to 6, I still get the issue.
I noticed that the kswap process owned by root is taking an exceptionally large amount of cpu, but I have no idea if this is normal in manjaro.
Historically, I’ve used pulse and not pipewire, so I’m not sure how to restart pipewire while logged in, so I’ve been having to log out and log back in whenever this occurs which is not super efficient.
Since I like to listen to music while I work, or participate in work meetings, this is a bit of an issue.
For what its worth, the issue is more about the interference with pipewire.
I suspect its because the build is taking a lot of resources, but I would perhaps expect a bit of stuttering while the build is running, but pipewire/sound remains hosed after the build completes.
I now suspect that I’m running out of memory and the system is randomly shutting down important processes.
For example, eclipse (my ide) keeps shutting down, even when I’m not compiling. Additionally, something to shutdown Kate, but because I had an unsaved document in it, a popup asked me to save it. I wasn’t even on the kate window.
I noticed during installation that I was informed about using a swap file instead of a partition.
Is there a way to manage that?
Worth considering - /tmp default to tmpfs which initialize to half your RAM size - so when compiling you may run out of memory - especially on compiling large sources.
Comment the tmp in your fstab - that will change your /tmp to be on the physical disk - that may improve on your system responsiveness during compilation.
Decoding video may not be offloaded to GPU but instead done by CPU - depending on configuration.
I chose swapfile, but apparently a swapfile wasn’t created, or if it was, it wasn’t “mounted” via /etc/fstab. I’ve gone ahead and manally created the swapfile and added it to fstab.
Ah, thats a good tip, it is indeed setup to half my ram. Thanks.
Is there a way to set up /tmp to behave like a swapfile, eg I like that it is in fact temporary when in ram, but I don’t want to sacrifice the ram. Ideally create a /tmpfile that tmp is mounted to similar to /swapfile.