[Arch Linux + i3] High CPU usage after closing windows

163 views
Skip to first unread message

andr...@gmail.com

unread,
Mar 19, 2017, 9:18:46 AM3/19/17
to qubes-users
Hello!

When I close all terminals from a VM, CPU usage for that VM goes to around 50% (shown by Qubes Manager) and stays there until I open another terminal to the same VM. The problem only happens if I close the terminal using Ctrl+d, not if I kill the window using i3.

This happens both with Arch Linux template or appvms based on it. Doesn't happens with Fedora.

Example of commands that I used to open the terminals:

qvm-run -a archlinux "xterm /bin/bash"
qvm-run -a archappvm "xfce4-terminal -x /bin/zsh"

(both bash or zsh, xterm or xfce4-terminal)

I thought it could be some zsh config, but the problem persists even commenting .zshrc content, or using bash (default configs).

It also happens if I open Vim with something like:
qvm-run -a archappvm "xfce4-terminal -x vim"
and close it using ":q". If I close Vim killing the window (i3 hotkey), it doesn't happens).

I tried to log CPU usage from inside the VM using "ps", but it doesn't seem to increase (no reported process started to consume more CPU). I thought it could be a problem with Qubes Manager (displaying false high CPU usage), but the fan do start to make more noise, so it must be using more CPU.

Any ideas?

Thanks for the attention!

Olivier Médoc

unread,
Mar 19, 2017, 9:54:07 AM3/19/17
to qubes...@googlegroups.com
Is it related to https://github.com/QubesOS/qubes-issues/issues/2702 ?

Try running as root:
# echo core > /proc/sys/kernel/core_pattern

When shutting down a VM, some service is apparently crashing, causing a
high CPU usage.

Andres MRM

unread,
Mar 19, 2017, 10:52:40 AM3/19/17
to Olivier Médoc, qubes...@googlegroups.com
Thanks for the fast reply, Olivier!
But no, I don't think it's related.
The problem seems indeed to be with zsh cofig, but it only showed up
after VM reboot. Sorry for the confusion.
It seems the command that was causing the problem was "xset r rate 200 45".
(no reason for running it in a VM since it should be configured in dom0,
right?)

And, yes, I know such command shouldn't be placed in .zshrc, but
.xinitrc is not being run at X startup... Any ideas about where to place
a "xmodmap ~/.Xmodmap"? rc.local seems not to work for this (maybe it is
run before X startup?


Thanks!

turb...@gmail.com

unread,
Mar 19, 2017, 5:04:23 PM3/19/17
to qubes-users, andr...@gmail.com
Hi, guys. Can you help me with this error ?


Curl: (22) The requested URL returned error: 404 non found

sudo pacman -Suy
:: Synchronizing package databases...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 4030 100 4030 0 0 8968 0 --:--:-- --:--:-- --:--:-- 8975
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 287 100 287 0 0 641 0 --:--:-- --:--:-- --:--:-- 640
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 123k 100 123k 0 0 367k 0 --:--:-- --:--:-- --:--:-- 368k
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404 Not Found
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 1678k 100 1678k 0 0 1225k 0 0:00:01 0:00:01 --:--:-- 1226k
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404 Not Found
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 3859k 100 3859k 0 0 2373k 0 0:00:01 0:00:01 --:--:-- 2375k
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404 Not Found
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 176k 100 176k 0 0 516k 0 --:--:-- --:--:-- --:--:-- 517k
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404 Not Found
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 51620 100 51620 0 0 51919 0 --:--:-- --:--:-- --:--:-- 51879
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 566 100 566 0 0 965 0 --:--:-- --:--:-- --:--:-- 964
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 15756 100 15756 0 0 59804 0 --:--:-- --:--:-- --:--:-- 59908
:: Starting full system upgrade...
there is nothing to do
archlinux%


Andres MRM

unread,
Mar 19, 2017, 8:37:54 PM3/19/17
to turb...@gmail.com, qubes-users
[2017-03-19 18:04] :
> Hi, guys. Can you help me with this error ?
>
> Curl: (22) The requested URL returned error: 404 non found

Hi! Does the VM has internet connection? Can you ping something?
If not, maybe you need to change settings (QubesManager) so it connects
through a NetVM.


Me:
> Any ideas about where to place a "xmodmap ~/.Xmodmap"?

I added a .desktop to .config/autostart/, but it's not really good.
It required a "sleep 1" before "xmodmap ~/.Xmodmap" for it to work...

Reply all
Reply to author
Forward
0 new messages