LXC High memory Usage without process using it

RedBlood9

Member
Apr 16, 2018
34
0
11
30
Hi,
I've a problem with the memory usage on LXC with proxmox VE.
I've noticed that proxmox sees that all of my LXC are using all ram assigned to them:
upload_2018-10-18_16-42-27.png

And even inside the CT I can see all the memory is used:
Code:
free -m
              total        used        free      shared  buff/cache   available
Mem:           2048        1925           3          62         119         122
Swap:          4096         660        3435
But trying to see what process is using it, I found that no one is using more than 50MB of ram:
Code:
ps aux  | awk '{print $6/1024 " MB\t\t" $11}'  | sort -n
0 MB        COMMAND
0.398438 MB        /usr/sbin/gssproxy
0.519531 MB        /sbin/agetty
0.578125 MB        /sbin/agetty
0.578125 MB        /sbin/agetty
0.824219 MB        /usr/sbin/crond
0.953125 MB        awk
1.29688 MB        /usr/lib/systemd/systemd-logind
1.35547 MB        /usr/bin/dbus-daemon
1.55859 MB        sort
1.61328 MB        /usr/sbin/zabbix_agentd
1.94531 MB        /usr/sbin/snmpd
2.07031 MB        /usr/sbin/zabbix_agentd:
3.14844 MB        /usr/libexec/postfix/master
3.23047 MB        ps
3.29297 MB        /usr/sbin/zabbix_agentd:
3.34766 MB        /sbin/init
3.44531 MB        qmgr
3.47656 MB        /usr/sbin/zabbix_agentd:
3.47656 MB        /usr/sbin/zabbix_agentd:
3.47656 MB        /usr/sbin/zabbix_agentd:
3.91797 MB        sshd:
4.26562 MB        su
4.47656 MB        /usr/sbin/sshd
4.5625 MB        -bash
4.83594 MB        -bash
6.23047 MB        /usr/bin/graylog-collector-sidecar
6.27734 MB        pickup
6.35547 MB        sudo
8.3125 MB        sshd:
10.6172 MB        /usr/bin/filebeat
16.6562 MB        /usr/sbin/rsyslogd
46.4258 MB        /usr/lib/systemd/systemd-journald
49.3359 MB        /usr/sbin/named


This is my VE:
Code:
pveversion -v
proxmox-ve: 5.1-42 (running kernel: 4.13.16-2-pve)
pve-manager: 5.1-51 (running version: 5.1-51/96be5354)
pve-kernel-4.13: 5.1-44
pve-kernel-4.13.16-2-pve: 4.13.16-47
pve-kernel-4.10.17-2-pve: 4.10.17-20
corosync: 2.4.2-pve4
criu: 2.11.1-1~bpo90
glusterfs-client: 3.8.8-1
ksm-control-daemon: 1.2-2
libjs-extjs: 6.0.1-2
libpve-access-control: 5.0-8
libpve-apiclient-perl: 2.0-4
libpve-common-perl: 5.0-30
libpve-guest-common-perl: 2.0-14
libpve-http-server-perl: 2.0-8
libpve-storage-perl: 5.0-18
libqb0: 1.0.1-1
lvm2: 2.02.168-pve6
lxc-pve: 3.0.0-2
lxcfs: 3.0.0-1
novnc-pve: 0.6-4
proxmox-widget-toolkit: 1.0-15
pve-cluster: 5.0-25
pve-container: 2.0-21
pve-docs: 5.1-17
pve-firewall: 3.0-8
pve-firmware: 2.0-4
pve-ha-manager: 2.0-5
pve-i18n: 1.0-4
pve-libspice-server1: 0.12.8-3
pve-qemu-kvm: 2.11.1-5
pve-xtermjs: 1.0-2
qemu-server: 5.0-25
smartmontools: 6.5+svn4324-1
spiceterm: 3.0-5
vncterm: 1.5-3
zfsutils-linux: 0.7.7-pve1~bpo9

Has anyone else had the same problem?
I've had this situation even on more update KVM, all present the same problem
 
Hi Richard,
This is what is showed inside the container's top:
Code:
Tasks:  31 total,   1 running,  30 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0,0 us,  0,0 sy,  0,0 ni,100,0 id,  0,0 wa,  0,0 hi,  0,0 si,  0,0 st
KiB Mem :  8388608 total,   900744 free,  6808632 used,   679232 buff/cache
KiB Swap:  8388604 total,  8336288 free,    52316 used.  1579976 avail Mem

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                                                                                                                      
23506 trend     20   0 8261832 1,026g  12004 S   1,0 12,8  89:50.33 java                                                                                                                                          
  282 root      20   0  127644  13264   8408 S   0,3  0,2   9:13.49 snmpd                                                                                                                                        
18251 user   20   0  155500   4248   3632 R   0,3  0,1   0:00.01 top                                                                                                                                          
    1 root      20   0  126172   5176   3328 S   0,0  0,1   0:19.46 systemd                                                                                                                                      
   38 root      20   0  246556  32668  32400 S   0,0  0,4   0:10.93 systemd-journal                                                                                                                              
   53 root      20   0  724348   6436   5928 S   0,0  0,1   1:03.98 rsyslogd                                                                                                                                      
   54 dbus      20   0   24412   2584   2340 S   0,0  0,0   0:10.51 dbus-daemon                                                                                                                                  
   56 root      20   0   24528   2924   2424 S   0,0  0,0   0:10.42 systemd-logind                                                                                                                                
   69 root      20   0    6468   1552   1548 S   0,0  0,0   0:00.00 agetty                                                                                                                                        
   71 root      20   0   22656   2028   1892 S   0,0  0,0   0:03.26 crond                                                                                                                                        
   76 root      20   0    6468   1572   1568 S   0,0  0,0   0:00.00 agetty                                                                                                                                        
   77 root      20   0    6468   1404   1400 S   0,0  0,0   0:00.00 agetty                                                                                                                                        
  283 root      20   0  106008   6648   6548 S   0,0  0,1   0:00.06 sshd                                                                                                                                          
  301 zabbix    20   0   84392   1968   1704 S   0,0  0,0   0:00.00 zabbix_agentd                                                                                                                                
  302 zabbix    20   0   84392   2280   1960 S   0,0  0,0   9:26.30 zabbix_agentd                                                                                                                                
  303 zabbix    20   0   84524   4904   4492 S   0,0  0,1   2:56.91 zabbix_agentd                                                                                                                                
  304 zabbix    20   0   84524   4940   4492 S   0,0  0,1   2:48.84 zabbix_agentd                                                                                                                                
  305 zabbix    20   0   84524   4940   4492 S   0,0  0,1   2:52.17 zabbix_agentd

As can you see nothing is using so much memory
 
Hi Richard,
This is what is showed inside the container's top:
Code:
Tasks:  31 total,   1 running,  30 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0,0 us,  0,0 sy,  0,0 ni,100,0 id,  0,0 wa,  0,0 hi,  0,0 si,  0,0 st
KiB Mem :  8388608 total,   900744 free,  6808632 used,   679232 buff/cache
KiB Swap:  8388604 total,  8336288 free,    52316 used.  1579976 avail Mem

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                                                                                                                     
23506 trend     20   0 8261832 1,026g  12004 S   1,0 12,8  89:50.33 java                                                                                                                                         
  282 root      20   0  127644  13264   8408 S   0,3  0,2   9:13.49 snmpd                                                                                                                                       
18251 user   20   0  155500   4248   3632 R   0,3  0,1   0:00.01 top                                                                                                                                         
    1 root      20   0  126172   5176   3328 S   0,0  0,1   0:19.46 systemd                                                                                                                                     
   38 root      20   0  246556  32668  32400 S   0,0  0,4   0:10.93 systemd-journal                                                                                                                             
   53 root      20   0  724348   6436   5928 S   0,0  0,1   1:03.98 rsyslogd                                                                                                                                     
   54 dbus      20   0   24412   2584   2340 S   0,0  0,0   0:10.51 dbus-daemon                                                                                                                                 
   56 root      20   0   24528   2924   2424 S   0,0  0,0   0:10.42 systemd-logind                                                                                                                               
   69 root      20   0    6468   1552   1548 S   0,0  0,0   0:00.00 agetty                                                                                                                                       
   71 root      20   0   22656   2028   1892 S   0,0  0,0   0:03.26 crond                                                                                                                                       
   76 root      20   0    6468   1572   1568 S   0,0  0,0   0:00.00 agetty                                                                                                                                       
   77 root      20   0    6468   1404   1400 S   0,0  0,0   0:00.00 agetty                                                                                                                                       
  283 root      20   0  106008   6648   6548 S   0,0  0,1   0:00.06 sshd                                                                                                                                         
  301 zabbix    20   0   84392   1968   1704 S   0,0  0,0   0:00.00 zabbix_agentd                                                                                                                               
  302 zabbix    20   0   84392   2280   1960 S   0,0  0,0   9:26.30 zabbix_agentd                                                                                                                               
  303 zabbix    20   0   84524   4904   4492 S   0,0  0,1   2:56.91 zabbix_agentd                                                                                                                               
  304 zabbix    20   0   84524   4940   4492 S   0,0  0,1   2:48.84 zabbix_agentd                                                                                                                               
  305 zabbix    20   0   84524   4940   4492 S   0,0  0,1   2:52.17 zabbix_agentd

As can you see nothing is using so much memory


Currently ~ 68/83 = 82%

To get more details install smem and check by

Code:
smem -t; smem -w
 
Hi,
This is the command output:
Code:
smem -t; smem -w
  PID User     Command                         Swap      USS      PSS      RSS
 6627 user  -bash                              0     3228     3409     5088
 6769 user  python /usr/bin/smem -t            0     6108     6321     8204
-------------------------------------------------------------------------------
    2 1                                           0     9336     9730    13292
Area                           Used      Cache   Noncache
firmware/hardware                 0          0          0
kernel image                      0          0          0
kernel dynamic memory     -27475212    -405308  -27069904
userspace memory           29538756     571452   28967304
free memory                   33608      33608          0
 
In order to get corresponding information run all the queries at the same time, like:

Code:
smem -t; smem -w;top -n 1 -b;free -m;ps aux  | awk '{print $6/1024 " MB\t\t" $11}'  | sort -n
 
Hi Richard,
Here's the requested output:
Code:
PID User     Command                         Swap      USS      PSS      RSS
110 root     /sbin/agetty --noclear --ke      100       24       76     1504
112 root     /sbin/agetty --noclear --ke      104       24       81     1616
111 root     /sbin/agetty --noclear --ke       84       40       98     1640
 92 root     /usr/sbin/gssproxy -D            460       68      159     2048
406 zabbix   /usr/sbin/zabbix_agentd -c       720       28      161     1892
932 root     nginx: master process /usr/      916       64      196     1128
113 root     /usr/sbin/crond -n               492      196      284     2156
410 zabbix   /usr/sbin/zabbix_agentd: co      672      256      400     2120
414 zabbix   /usr/sbin/zabbix_agentd: ac      756      116      409     3832
411 zabbix   /usr/sbin/zabbix_agentd: li      712      164      474     3952
413 zabbix   /usr/sbin/zabbix_agentd: li      708      168      478     3956
933 nginx    nginx: worker proces            1260      132      484     2960
934 nginx    nginx: worker proces            1208      132      484     2960
412 zabbix   /usr/sbin/zabbix_agentd: li      660      216      526     4004
 54 root     /usr/lib/systemd/systemd-lo      280      580      665     2636
425 smmsp    sendmail: Queue runner@01:0      988      544      672     1992
 58 dbus     /usr/bin/dbus-daemon --syst      288      596      851     3728
418 root     sendmail: accepting connect     1364      708      937     3248
381 root     /usr/sbin/sshd -D                788      308     1039     6328
27596 root     su -                               0      752     1275     4520
27536 user  sshd: e.ocone@pts/2                0      192     1335     4516
  1 root     /sbin/init                       336     2080     2196     4308
27595 root     sudo su -                          0     1676     2266     6644
27534 root     sshd: user [priv]               0      684     2428     8816
27597 root     -bash                              0     2096     2639     4728
27537 user  -bash                              0     2092     2781     5096
27533 nginx    php-fpm: pool www               3556      764     2979     8236
388 root     php-fpm: master process (/e     4164     2556     5093    12048
385 root     /usr/sbin/snmpd -LS0-6d -f     16372     6356     6848    11148
27653 root     python /bin/smem -t                0     7776     7855     9632
389 root     /usr/sbin/rsyslogd -n         140400     1480    23564    69836
384 telegraf /usr/bin/telegraf -config /     2852    33916    33974    35492
 35 root     /usr/lib/systemd/systemd-jo     5964    16440    57152   139172
-------------------------------------------------------------------------------
 33 7                                      186204    83224   160859   377892
Area                           Used      Cache   Noncache
firmware/hardware                 0          0          0
kernel image                      0          0          0
kernel dynamic memory     -27984328    -329324  -27655004
userspace memory           29955692     517088   29438604
free memory                  125788     125788          0
top - 12:00:29 up 29 days,  2:39,  1 user,  load average: 5.85, 4.03, 3.64
Tasks:  33 total,   1 running,  32 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.0 us,  0.0 sy,  0.0 ni,100.0 id,  0.0 wa,  0.0 hi,  0.0 si,  0.0 st
KiB Mem :  2097152 total,   129404 free,  1779868 used,   187880 buff/cache
KiB Swap:  3145728 total,  2731176 free,   414552 used.   317284 avail Mem

PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND
27655 root      20   0   56036   3668   3184 R 100.0  0.2   0:00.01 top
  1 root      20   0  190884   4308   3416 S   0.0  0.2   2:57.77 systemd
 35 root      20   0  238380 139172 139044 S   0.0  6.6   7:12.74 systemd-journal
 54 root      20   0   26520   2636   2488 S   0.0  0.1   0:54.83 systemd-logind
 58 dbus      20   0   58096   3728   3528 S   0.0  0.2   1:59.75 dbus-daemon
 92 root      20   0   91504   1776   1776 S   0.0  0.1   0:00.00 gssproxy
110 root      20   0    6512   1504   1480 S   0.0  0.1   0:00.00 agetty
111 root      20   0    6512   1640   1600 S   0.0  0.1   0:00.00 agetty
112 root      20   0    6512   1616   1592 S   0.0  0.1   0:00.00 agetty
113 root      20   0   22708   2156   2020 S   0.0  0.1   0:06.67 crond
381 root      20   0  112824   6256   6088 S   0.0  0.3   0:00.03 sshd
384 telegraf  20   0 1029512  34224   4960 S   0.0  1.6 197:58.08 telegraf
385 root      20   0  136164  11148   6924 S   0.0  0.5  19:03.92 snmpd
388 root      20   0  233624  12048  11424 S   0.0  0.6   3:25.82 php-fpm
389 root      20   0  520192  69580  68592 S   0.0  3.3   4:24.18 rsyslogd
406 zabbix    20   0   84480   1892   1716 S   0.0  0.1   0:00.00 zabbix_agentd
410 zabbix    20   0   84480   2120   1896 S   0.0  0.1  21:17.73 zabbix_agentd
411 zabbix    20   0   84612   3952   3648 S   0.0  0.2   5:52.99 zabbix_agentd
412 zabbix    20   0   84612   4004   3648 S   0.0  0.2   5:47.96 zabbix_agentd
413 zabbix    20   0   84612   3956   3648 S   0.0  0.2   5:51.68 zabbix_agentd
414 zabbix    20   0   84612   3828   3576 S   0.0  0.2   3:37.90 zabbix_agentd
418 root      20   0   92932   3248   2684 S   0.0  0.2   1:21.06 sendmail
425 smmsp     20   0   84224   1992   1448 S   0.0  0.1   0:00.53 sendmail
932 root      20   0   56728   1004    832 S   0.0  0.0   0:00.00 nginx
933 nginx     20   0   57132   1732   1492 S   0.0  0.1   0:40.48 nginx
934 nginx     20   0   57060   2828   2588 S   0.0  0.1   0:12.53 nginx
27533 nginx     20   0  233624   7472   6300 S   0.0  0.4   0:00.00 php-fpm
27534 root      20   0  148432   8816   7540 S   0.0  0.4   0:00.04 sshd
27536 user   20   0  148432   4196   2920 S   0.0  0.2   0:00.17 sshd
27537 user   20   0  117040   5096   3040 S   0.0  0.2   0:00.19 bash
27595 root      20   0  210348   6640   5632 S   0.0  0.3   0:00.01 sudo
27596 root      20   0  185584   4504   3956 S   0.0  0.2   0:00.01 su
27597 root      20   0   13548   4728   2632 S   0.0  0.2   0:00.17 bash
            total        used        free      shared  buff/cache   available
Mem:           2048        1738         126         846         183         309
Swap:          3072         404        2667
0 MB        COMMAND
0.898438 MB        awk
0.980469 MB        nginx:
1.46875 MB        /sbin/agetty
1.57812 MB        /sbin/agetty
1.60156 MB        /sbin/agetty
1.69141 MB        nginx:
1.73438 MB        /usr/sbin/gssproxy
1.74219 MB        sort
1.84766 MB        /usr/sbin/zabbix_agentd
1.94531 MB        sendmail:
2.07031 MB        /usr/sbin/zabbix_agentd:
2.10547 MB        /usr/sbin/crond
2.57422 MB        /usr/lib/systemd/systemd-logind
2.76172 MB        nginx:
3.17188 MB        sendmail:
3.42188 MB        ps
3.64062 MB        /usr/bin/dbus-daemon
3.73828 MB        /usr/sbin/zabbix_agentd:
3.85938 MB        /usr/sbin/zabbix_agentd:
3.86328 MB        /usr/sbin/zabbix_agentd:
3.91016 MB        /usr/sbin/zabbix_agentd:
4.09766 MB        sshd:
4.20703 MB        /sbin/init
4.39844 MB        su
4.61719 MB        -bash
4.97656 MB        -bash
6.10938 MB        /usr/sbin/sshd
6.48438 MB        sudo
7.29688 MB        php-fpm:
8.60938 MB        sshd:
10.8867 MB        /usr/sbin/snmpd
11.7656 MB        php-fpm:
33.4219 MB        /usr/bin/telegraf
67.9492 MB        /usr/sbin/rsyslogd
135.91 MB        /usr/lib/systemd/systemd-journald
 
Looks like a memory leak caused by one of your applications running inside the container.
 
I've launched the same command on another CT with the same problem, but i can't find any application using my memory:
Code:
PID User     Command                         Swap      USS      PSS      RSS
 86 root     /sbin/agetty --noclear --ke      124        4       23      592
 87 root     /sbin/agetty --noclear --ke      124        4       23      596
 88 root     /sbin/agetty --noclear --ke      124        4       23      592
 75 root     /usr/sbin/gssproxy -D            460       52       71      636
28981 zabbix   /usr/sbin/zabbix_agentd -c       824        4      124     1652
 89 root     /usr/sbin/crond -n               512      140      163      824
29846 root     /usr/libexec/postfix/master      964      132      376     3220
28986 zabbix   /usr/sbin/zabbix_agentd: ac      840      108      394     3372
28983 zabbix   /usr/sbin/zabbix_agentd: li      796      160      467     3560
28984 zabbix   /usr/sbin/zabbix_agentd: li      792      160      467     3560
28985 zabbix   /usr/sbin/zabbix_agentd: li      792      160      467     3560
28982 zabbix   /usr/sbin/zabbix_agentd: co      768      404      539     2120
29848 postfix  qmgr -l -t unix -u               984      156      543     4176
 56 dbus     /usr/bin/dbus-daemon --syst      324      540      596     1364
 55 root     /usr/lib/systemd/systemd-lo      532      608      633     1348
23399 root     /usr/sbin/sshd -D                920      112      707     4876
11188 user  sshd: userone@pts/2                0      216     1355     4360
11280 root     su -                               0      684     1363     4336
397 root     /usr/sbin/snmpd -LS0-6d -f     96280     1664     1690     2388
11279 root     sudo su -                          0     1672     2352     6480
  1 root     /sbin/init                       608     2284     2355     3460
11186 root     sshd: user [priv]               0      660     2558     8464
10979 postfix  pickup -l -t unix -u               0     2148     2580     6312
11281 root     -bash                              0     2024     2581     4604
11189 user  -bash                              0     2060     2767     5000
12567 root     /usr/bin/graylog-collector-      852     6880     6921     7828
11445 root     python /bin/smem -t                0     7404     7503     9212
3406 root     /usr/sbin/rsyslogd -n         447996      840     7605    21416
12663 root     /usr/bin/filebeat -c /etc/g     2260    10000    10043    11020
 37 root     /usr/lib/systemd/systemd-jo    71868    19528    34272    59220
12685 named    /usr/sbin/named -u named -c   177132    51996    52376    55316
-------------------------------------------------------------------------------
 31 6                                      806876   112808   143937   245464
Area                           Used      Cache   Noncache
firmware/hardware                 0          0          0
kernel image                      0          0          0
kernel dynamic memory      -7168148     -84080   -7084068
userspace memory            9203144     375160    8827984
free memory                   62156      62156          0
top - 12:17:14 up 168 days,  4:16,  1 user,  load average: 4.12, 3.95, 4.00
Tasks:  31 total,   1 running,  30 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.0 us,  0.0 sy,  0.0 ni,100.0 id,  0.0 wa,  0.0 hi,  0.0 si,  0.0 st
KiB Mem :  2097152 total,    65796 free,  1740260 used,   291096 buff/cache
KiB Swap:  4194304 total,  3096128 free,  1098176 used.   356892 avail Mem

PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND
12685 named     20   0 1434524  54700   4768 S  1600  2.6   7133:52 named
  1 root      20   0  191120   3460   2504 S   0.0  0.2   3:44.88 systemd
 37 root      20   0  182960  59216  59092 S   0.0  2.8   8:32.40 systemd-journal
 55 root      20   0   26760   1348   1160 S   0.0  0.1   1:31.73 systemd-logind
 56 dbus      20   0   58076   1364   1156 S   0.0  0.1   2:23.82 dbus-daemon
 75 root      20   0   91504    364    344 S   0.0  0.0   0:00.07 gssproxy
 86 root      20   0    6512    592    588 S   0.0  0.0   0:00.00 agetty
 87 root      20   0    6512    532    528 S   0.0  0.0   0:00.00 agetty
 88 root      20   0    6512    592    588 S   0.0  0.0   0:00.00 agetty
 89 root      20   0   22704    824    724 S   0.0  0.0   0:28.82 crond
397 root      20   0  213152   2388   1108 S   0.0  0.1  93:01.71 snmpd
3406 root      20   0  737000  20812  20388 S   0.0  1.0   8:08.62 rsyslogd
10979 postfix   20   0   89748   6308   5304 S   0.0  0.3   0:00.00 pickup
11186 root      20   0  148432   8464   7188 S   0.0  0.4   0:00.02 sshd
11188 user   20   0  148432   4036   2760 S   0.0  0.2   0:00.13 sshd
11189 user   20   0  117032   5000   2980 S   0.0  0.2   0:00.12 bash
11279 root      20   0  210348   6476   5472 S   0.0  0.3   0:00.00 sudo
11280 root      20   0  185584   4320   3772 S   0.0  0.2   0:00.00 su
11281 root      20   0   13412   4604   2580 S   0.0  0.2   0:00.13 bash
11447 root      20   0   56036   3568   3092 R   0.0  0.2   0:00.00 top
12567 root      20   0  439008   5708   2268 S   0.0  0.3  67:46.37 graylog-collect
12663 root      20   0  416696   9864   3248 S   0.0  0.5  42:05.75 filebeat
23399 root      20   0  112824   4356   4328 S   0.0  0.2   0:00.04 sshd
28981 zabbix    20   0   83908   1652   1580 S   0.0  0.1   0:00.00 zabbix_agentd
28982 zabbix    20   0   83908   2120   1992 S   0.0  0.1  37:41.74 zabbix_agentd
28983 zabbix    20   0   84040   3560   3336 S   0.0  0.2  12:40.42 zabbix_agentd
28984 zabbix    20   0   84040   3560   3336 S   0.0  0.2  12:24.44 zabbix_agentd
28985 zabbix    20   0   84040   3560   3336 S   0.0  0.2  12:34.78 zabbix_agentd
28986 zabbix    20   0   84040   3372   3200 S   0.0  0.2   7:06.67 zabbix_agentd
29846 root      20   0   89644   3220   3148 S   0.0  0.2   0:33.38 master
29848 postfix   20   0   89924   4160   4092 S   0.0  0.2   0:07.14 qmgr
            total        used        free      shared  buff/cache   available
Mem:           2048        1699          64          75         284         348
Swap:          4096        1072        3023
0 MB        COMMAND
0.355469 MB        /usr/sbin/gssproxy
0.519531 MB        /sbin/agetty
0.578125 MB        /sbin/agetty
0.578125 MB        /sbin/agetty
0.804688 MB        /usr/sbin/crond
0.839844 MB        awk
1.31641 MB        /usr/lib/systemd/systemd-logind
1.33203 MB        /usr/bin/dbus-daemon
1.61328 MB        /usr/sbin/zabbix_agentd
1.75781 MB        sort
2.07031 MB        /usr/sbin/zabbix_agentd:
2.33203 MB        /usr/sbin/snmpd
3.14453 MB        /usr/libexec/postfix/master
3.25781 MB        ps
3.29297 MB        /usr/sbin/zabbix_agentd:
3.37891 MB        /sbin/init
3.47656 MB        /usr/sbin/zabbix_agentd:
3.47656 MB        /usr/sbin/zabbix_agentd:
3.47656 MB        /usr/sbin/zabbix_agentd:
3.94141 MB        sshd:
4.0625 MB        qmgr
4.21875 MB        su
4.25391 MB        /usr/sbin/sshd
4.49609 MB        -bash
4.88281 MB        -bash
5.57422 MB        /usr/bin/graylog-collector-sidecar
6.16016 MB        pickup
6.32422 MB        sudo
8.26562 MB        sshd:
9.63281 MB        /usr/bin/filebeat
20.3242 MB        /usr/sbin/rsyslogd
53.418 MB        /usr/sbin/named
57.8281 MB        /usr/lib/systemd/systemd-journald

I've create even identical VPS with same hardware conf and software, and while the CT is using all the memory, the VM is using only 500MB
 
Start the container (or a copy of it) and observe the memory periodically (In the container and in the host as well). Start the applications step by step in order to figure out which one may cause the problem.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!