High CPU load

Timon Michel

Member
Nov 29, 2017
8
1
23
25
Hello,

i've already had some performance problems that i've accused my processor for. (i7-7700)
Today i wanted to do some testing with KVM/LXC performance and compare both.
But i realized that a KVM VM has ~50% CPU load on idle while htop on the VM says 0.0 to 1.0%.
I am using PVE 4.4-18/ef2610e8.

Guest:
lk3y66g.png


Host:
ZgPjBaR.png


I guess that's not normal, right?

Thanks,
Timon Michel
 
Hi,

which process consumes the cpu on the Host?
Pleas send a top from the host.
 
Code:
top - 22:53:18 up 98 days,  4:11, 22 users,  load average: 3.99, 3.44, 3.18
Tasks: 439 total,   1 running, 438 sleeping,   0 stopped,   0 zombie
%Cpu(s): 23.3 us,  4.4 sy,  0.0 ni, 72.1 id,  0.1 wa,  0.0 hi,  0.1 si,  0.0 st
KiB Mem:  65765700 total, 56279440 used,  9486260 free,  1888676 buffers
KiB Swap:  6291452 total,   486044 used,  5805408 free. 44767888 cached Mem

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND
11488 root      20   0 7895008 1.296g  21480 S  81.4  2.1   1712:29 java
25968 root      20   0 9415048 2.071g  19264 S  34.6  3.3 126:22.03 java
5966 root      20   0 1639744 289432  11280 S  21.9  0.4 655:45.71 kvm
11249 1023      20   0 4485816 364244  19804 S  16.6  0.6  46:34.64 java
27854 1001      20   0  831152  30564  11984 S  10.6  0.0   3055:12 sinusbot
12626 1001      20   0 1332876  27696  16580 S   7.3  0.0   1123:21 ts3client_linux
20617 104       20   0 1859192  67660  23016 S   7.3  0.1 397:10.98 sinusbot
11907 104       20   0 1170128  43284  33932 S   5.7  0.1 231:01.20 ts3client_linux
23411 1001      20   0 1205880 152176  21244 S   4.3  0.2 880:40.88 sinusbot
32698 104       20   0 1068664  42108  33060 S   4.0  0.1 205:23.43 ts3client_linux
17019 1001      20   0 2262120  96472  59532 S   3.7  0.1 255:47.78 ts3client_linux
 1428 root      20   0  249956  70424  12300 S   3.0  0.1 945:01.01 pvestatd
21010 1001      20   0 2370184 104524  59984 S   3.0  0.2 629:06.28 ts3client_linux
26424 1003      20   0 5246092 1.044g  13672 S   2.7  1.7   2178:54 java
30152 1001      20   0 1018224  60236  22268 S   2.7  0.1   6:55.05 sinusbot
 3459 root      20   0 1127656  24104  10924 S   2.0  0.0   3:10.88 ts3server
16232 root      20   0 1151452  22952  11152 S   1.3  0.0 140:41.75 ts3server
18020 1009      20   0 4166004 386436  17640 S   1.0  0.6   4:51.30 java
26328 root      20   0 1135024  10904   5368 S   0.7  0.0 508:11.17 ts3server
30090 root      20   0 1127876  23056  10800 S   0.7  0.0  25:25.69 ts3server
 1276 root      20   0 1227624   2548   2148 S   0.3  0.0 123:29.47 rrdcached
11440 root      20   0 3215212  71888  16660 S   0.3  0.1  11:40.39 java
14659 statd     20   0  755476  44868   5284 S   0.3  0.1  49:15.02 mysqld
14810 root      20   0   36168   3496   3400 S   0.3  0.0   0:11.35 master
26946 root      20   0       0      0      0 S   0.3  0.0   0:00.54 kworker/u16:1
31906 root      20   0  549272  43316  34508 S   0.3  0.1   5:03.64 pmxcfs
    1 root      20   0  177556   5712   3040 S   0.0  0.0   4:02.44 systemd
    2 root      20   0       0      0      0 S   0.0  0.0   0:03.15 kthreadd
    3 root      20   0       0      0      0 S   0.0  0.0 142:29.42 ksoftirqd/0
    5 root       0 -20       0      0      0 S   0.0  0.0   0:00.00 kworker/0:0H
    7 root      20   0       0      0      0 S   0.0  0.0 270:12.12 rcu_sched
    8 root      20   0       0      0      0 S   0.0  0.0   0:00.08 rcu_bh
    9 root      rt   0       0      0      0 S   0.0  0.0   0:23.70 migration/0
   10 root      rt   0       0      0      0 S   0.0  0.0   1:41.74 watchdog/0
   11 root      rt   0       0      0      0 S   0.0  0.0   1:22.85 watchdog/1
   12 root      rt   0       0      0      0 S   0.0  0.0   0:22.88 migration/1
   13 root      20   0       0      0      0 S   0.0  0.0  41:16.42 ksoftirqd/1
   15 root       0 -20       0      0      0 S   0.0  0.0   0:00.00 kworker/1:0H
   16 root      rt   0       0      0      0 S   0.0  0.0   1:28.26 watchdog/2
   17 root      rt   0       0      0      0 S   0.0  0.0   0:22.43 migration/2
   18 root      20   0       0      0      0 S   0.0  0.0  14:33.76 ksoftirqd/2
   20 root       0 -20       0      0      0 S   0.0  0.0   0:00.00 kworker/2:0H
   21 root      rt   0       0      0      0 S   0.0  0.0   0:47.76 watchdog/3
   22 root      rt   0       0      0      0 S   0.0  0.0   0:12.38 migration/3
   23 root      20   0       0      0      0 S   0.0  0.0  11:30.13 ksoftirqd/3
   25 root       0 -20       0      0      0 S   0.0  0.0   0:00.00 kworker/3:0H
   26 root      rt   0       0      0      0 S   0.0  0.0   0:54.62 watchdog/4
   27 root      rt   0       0      0      0 S   0.0  0.0   0:17.92 migration/4
   28 root      20   0       0      0      0 S   0.0  0.0  39:52.26 ksoftirqd/4
   30 root       0 -20       0      0      0 S   0.0  0.0   0:00.00 kworker/4:0H
   31 root      rt   0       0      0      0 S   0.0  0.0   1:15.30 watchdog/5

Some processes like java or ts3server are from LXC machines, that's also a big performance issue.
What's strange: Exactly the same java processes run fine with <5% usage on any other VPS, but for me it's causing 80% usage...
 
I would analyze your java program may be it can't get needed resources.
 
It's not about java, it's about that KVM process:
Code:
5966 root      20   0 1639744 289432  11280 S  21.9  0.4 655:45.71 kvm
It's debian 9 in idle on an i7-7700
As i am using pve 4.4, maybe it doesn't support an intel core 7th generation?