container can't see free disk space

mathx

Renowned Member
Jan 15, 2014
177
3
83
Finally figured out how to create a container on pve 4.1. (I had installed PVE4.1 on a ZFS mirror, not sure if that has anything to do with it, but I had to go and create myself another datastore, which I did as ZFS).

The datastore is CTDATA:
enabled, active, content = disk image,container, type: zfs, shared: no, size: 3.45TB, used: 416gb, free: 3.04TB

I created a container from a .tar.gz template i had tuned up for my 3.2/3.3/3.4 ct's and it worked fine. I can enter/console into it, etc etc.

I chose ctdata as the disk store for the container, now in options for the container it says:

root disk: ctdata:subvol-100-disk-1,size=12G

that's all fine. Inside the container I see:

foo:~# df -h /
Filesystem Size Used Avail Use% Mounted on
rpool/ROOT 3.1T 273M 3.1T 1% /

Why does it see the whole 3.1TB free?

[detail]
proxmox-ve: 4.1-34 (running kernel: 4.2.6-1-pve)
pve-manager: 4.1-5 (running version: 4.1-5/f910ef5c)
pve-kernel-4.2.6-1-pve: 4.2.6-34
pve-kernel-4.2.2-1-pve: 4.2.2-16
lvm2: 2.02.116-pve2
corosync-pve: 2.3.5-2
libqb0: 0.17.2-1
pve-cluster: 4.0-31
qemu-server: 4.0-49
pve-firmware: 1.1-7
libpve-common-perl: 4.0-45
libpve-access-control: 4.0-11
libpve-storage-perl: 4.0-38
pve-libspice-server1: 0.12.5-2
vncterm: 1.2-1
pve-qemu-kvm: 2.5-3
pve-container: 1.0-39
pve-firewall: 2.0-15
pve-ha-manager: 1.0-19
ksm-control-daemon: 1.2-1
glusterfs-client: 3.5.2-2+deb8u1
lxc-pve: 1.1.5-6
lxcfs: 0.13-pve3
cgmanager: 0.39-pve1
criu: 1.6.0-1
zfsutils: 0.6.5-pve7~jessie
 
Hi,
please use zfs list and zpool list to see the real diskusage for zfs pools
 
Sure - outside the container, but this is inside -- will the container be limited at 12GB? And even if it is, why can't the users of the container see that they're limited to 12GB in the df, like with openVZ containers in 3.4?
 
Yes you are restrict to 12 GB but you see inside the hole space.
This is correct.
If you want check this you can call on the host
Code:
zfs get refquota
 
(ie, he cant. which is a reduction in features from a VZ container where df showed the proper limit.)
 
This is still not solved - anyone running any internal monitoring services on the CT will not be able to monitor their diskspace without direct cooperation/exposure from the host. Is there any work around for this?
 

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!