CT: unable to change memory online

dale

Renowned Member
Mar 19, 2010
34
0
71
Hello, this is running containers only related (VMs - OK), webui result - the same.

~# pct set 120 --memory 10240
400 Parameter verification failed.
memory: unable to hotplug memory: closing file '/sys/fs/cgroup/memory///lxc/120/memory.limit_in_bytes' failed - Invalid argument

pct set <vmid> [OPTIONS]

or

~# echo 10737418240 >/sys/fs/cgroup/memory///lxc/120/memory.limit_in_bytes
bash: echo: write error: Invalid argument

~# pveversion -v
proxmox-ve: 6.2-1 (running kernel: 5.4.41-1-pve)
pve-manager: 6.2-6 (running version: 6.2-6/ee1d7754)
pve-kernel-5.4: 6.2-2
pve-kernel-helper: 6.2-2
pve-kernel-5.4.41-1-pve: 5.4.41-1
ceph-fuse: 14.2.9-pve1
corosync: 3.0.3-pve1
criu: 3.11-3
glusterfs-client: 5.5-3
ifupdown2: 3.0.0-1+pve2
ksm-control-daemon: 1.3-1
libjs-extjs: 6.0.1-10
libknet1: 1.15-pve1
libproxmox-acme-perl: 1.0.4
libpve-access-control: 6.1-1
libpve-apiclient-perl: 3.0-3
libpve-common-perl: 6.1-3
libpve-guest-common-perl: 3.0-10
libpve-http-server-perl: 3.0-5
libpve-storage-perl: 6.1-8
libqb0: 1.0.5-1
libspice-server1: 0.14.2-4~pve6+1
lvm2: 2.03.02-pve4
lxc-pve: 4.0.2-1
lxcfs: 4.0.3-pve2
novnc-pve: 1.1.0-1
openvswitch-switch: 2.12.0-1
proxmox-mini-journalreader: 1.1-1
proxmox-widget-toolkit: 2.2-7
pve-cluster: 6.1-8
pve-container: 3.1-8
pve-docs: 6.2-4
pve-edk2-firmware: 2.20200229-1
pve-firewall: 4.1-2
pve-firmware: 3.1-1
pve-ha-manager: 3.0-9
pve-i18n: 2.1-3
pve-qemu-kvm: 5.0.0-4
pve-xtermjs: 4.3.0-1
qemu-server: 6.2-3
smartmontools: 7.1-pve2
spiceterm: 3.1-1
vncterm: 1.6-1
zfsutils-linux: 0.8.4-pve1
 
hi,

i was able to reproduce the error, i will take a look at fixing it.

in my testing it only happened when the memory was set to more than what the host has.

what is the output of free -h ?

does it work if you set to a lower amount?
 
In my case :(

~# free -h
total used free shared buff/cache available
Mem: 125Gi 43Gi 67Gi 121Mi 15Gi 81Gi
Swap: 19Gi 10Mi 19Gi

~# cat /sys/fs/cgroup/memory///lxc/120/memory.limit_in_bytes
8590983168
~# echo $((8589934592+1024*1024*512)) >/sys/fs/cgroup/memory///lxc/120/memory.limit_in_bytes
9126805504

~# echo $((8589934592+1024*1024*513)) >/sys/fs/cgroup/memory///lxc/120/memory.limit_in_bytes
bash: echo: write error: Invalid argument

512MB max memory increment

Best regards,
dale.
 
Last edited:

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!