I will rework the wiki.
http://pve.proxmox.com/wiki/Linux_Container
please give me some time.
I will tell you when it is updated.
Hi,
at the moment you have to this on command line.
Code:pct resize <vmid> <disk> <size> [OPTIONS]
You can resize disk images and containers FS, but only*increase* them.
We haven't implemented shrinking at that point, the risk of shooting yourself in the foot is too big, especially for virtual machines.
For container, when restoring a backup, you have the possibility of setting the rootfs size, and this is the recommend way to setup a smaller FS.
Manu, that is clear. What is the official process for extending LXC filesystems if 'pct resize' isn't working? I've seen a number of potential solutions using various system-level tools, including zfs' management commands. Is this what Proxmox is saying we have to use? Are staff aware that pct resize isn't working under 4.0.x? Is there a timeline to get that addressed? Thanks.
proxmox-ve: 4.0-16 (running kernel: 4.2.2-1-pve)
pve-manager: 4.0-48 (running version: 4.0-48/0d8559d0)
pve-kernel-4.2.2-1-pve: 4.2.2-16
lvm2: 2.02.116-pve1
corosync-pve: 2.3.5-1
libqb0: 0.17.2-1
pve-cluster: 4.0-22
qemu-server: 4.0-30
pve-firmware: 1.1-7
libpve-common-perl: 4.0-29
libpve-access-control: 4.0-9
libpve-storage-perl: 4.0-25
pve-libspice-server1: 0.12.5-1
vncterm: 1.2-1
pve-qemu-kvm: 2.4-9
pve-container: 1.0-6
pve-firewall: 2.0-12
pve-ha-manager: 1.0-9
ksm-control-daemon: 1.2-1
glusterfs-client: 3.5.2-2+deb8u1
lxc-pve: 1.1.3-1
lxcfs: 0.9-pve2
cgmanager: 0.37-pve2
criu: 1.6.0-1
zfsutils: 0.6.5-pve4~jessie
#Plex media server on Debian8
arch: amd64
cpulimit: 2
cpuunits: 1024
hostname: plex.aviate.org
memory: 4000
net0: bridge=vmbr0,gw=192.168.1.1,hwaddr=9A:63:CF:3E:92:1C,ip=192.168.1.100/24,ip6=auto,name=eth0,type=veth
ostype: ubuntu
rootfs: zfs-local:subvol-104-disk-1,size=250G
swap: 4000
I'm using PVE 6.2-4. Trying to shrink the disk size. Here is the output. Please help.
Code:root@pve:/# pct resize 101 rootfs 8G unable to shrink disk size
vzdump 100 --mode snapshot
zfs set refquota=8G rpool/data/subvol-100-disk-1
cat << EOF > 100.conf.diff
--- lxc/100.conf.orig 2021-01-03 12:58:03.000000000 +0100
+++ lxc/100.conf 2021-01-03 15:03:54.000000000 +0100
@@ -2,7 +2,7 @@
cores: 1
hostname: lcoovhdolp002
memory: 2048
-mp0: local-zfs:subvol-100-disk-1,mp=/var/lib/dolibarr,backup=1,size=88G
+mp0: local-zfs:subvol-100-disk-1,mp=/var/lib/dolibarr,backup=1,size=8G
nameserver: 94.23.248.5 213.186.33.99
net0: name=eth0,bridge=vmbr0,gw=94.23.248.254,gw6=2001:41d0:2:7bff:ff:ff:ff:ff,hwaddr=02:00:00:2d:95:91,ip=87.98.183.98/32,ip6=2001:41d0:2:7b05::1/128,type=veth
onboot: 1
EOF
patch -p0 lxc/100.conf 100.conf.diff