Is Proxmox swap shared by containers?

AaronWalker

New Member
Feb 18, 2017
25
2
3
30
Whether or not I allocate swap to a container, the container still shows the swap size of the physical server.
Software such as NextCloud reports memory usage by adding Mem and Swap together.

/proc/meminfo
Code:
MemTotal:         262144 kB
MemFree:          218196 kB
MemAvailable:     218196 kB
...
SwapCached:            0 kB
SwapTotal:       7340028 kB
SwapFree:        7340028 kB


Is swap allocated inside the container or is it allocated to the already created physical machine's swap?
Is it intentional for /proc/meminfo to show the actual swap size rather than the virtual swap size?
 
Last edited:
are you running the current version (please always include "pveversion -v")? also, I think you mean /proc/meminfo and not /etc/meminfo ?
 
pveversion -v
Code:
proxmox-ve: 4.4-76 (running kernel: 4.4.35-1-pve)
pve-manager: 4.4-1 (running version: 4.4-1/eb2d6f1e)
pve-kernel-4.4.35-1-pve: 4.4.35-76
lvm2: 2.02.116-pve3
corosync-pve: 2.4.0-1
libqb0: 1.0-1
pve-cluster: 4.0-48
qemu-server: 4.0-101
pve-firmware: 1.1-10
libpve-common-perl: 4.0-83
libpve-access-control: 4.0-19
libpve-storage-perl: 4.0-70
pve-libspice-server1: 0.12.8-1
vncterm: 1.2-1
pve-docs: 4.4-1
pve-qemu-kvm: 2.7.0-9
pve-container: 1.0-88
pve-firewall: 2.0-33
pve-ha-manager: 1.0-38
ksm-control-daemon: 1.2-1
glusterfs-client: 3.5.2-2+deb8u3
lxc-pve: 2.0.6-2
lxcfs: 2.0.5-pve1
criu: 1.6.0-1
novnc-pve: 0.5-8
smartmontools: 6.5+svn4324-1~pve80
zfsutils: 0.6.5.8-pve13~bpo80

My apologies. Yes, I meant /proc/meminfo.
 
please upgrade to the current version..