Why is my filesystem shrinking?
Hello,
I am pretty new to FreeBSD and zfs. I have a VM where I have a 12GB Disk for my root disk. But currently the root partition seems to shrink. When I do a zpool list I see the zroot is 11GB
askr# zpool list
NAME SIZE ALLOC FREE CKPOINT EXPANDSZ FRAG CAP DEDUP HEALTH ALTROOT
zroot 10.9G 10.5G 378M - - 92% 96% 1.00x ONLINE -
But df show the following
askr# df -h
Filesystem Size Used Avail Capacity Mounted on
zroot/ROOT/default 3.7G 3.6G 36M 99% /
devfs 1.0K 0B 1.0K 0% /dev
zroot 36M 24K 36M 0% /zroot
Now when I go ahead and delete like 100MB zroot/ROOT/default shrinks by this 100MB
askr# df -h
Filesystem Size Used Avail Capacity Mounted on
zroot/ROOT/default 3.6G 3.5G 35M 99% /
devfs 1.0K 0B 1.0K 0% /dev
zroot 35M 24K 35M 0% /zroot
I already tried to resize the VM Disk and then the pool but the pool doesn't expand despite autoexpand being online. I did the following
askr# gpart resize -i 4 /dev/ada0
ada0p4 resized
askr# zpool get autoexpand zroot
NAME PROPERTY VALUE SOURCE
zroot autoexpand on local
askr# zpool online -e zroot ada0p4
askr# df -h
Filesystem Size Used Avail Capacity Mounted on
zroot/ROOT/default 3.6G 3.5G 35M 99% /
devfs 1.0K 0B 1.0K 0% /dev
zroot 35M 24K 35M 0% /zroot
```
I am at the end of my knowledge. Should I just scrap the VM and start over? It's only my DHCP server and holds no impoertant data, I can deploy it with ansible from scratch without issues.
Posted Apr 15, 2025, 7:41 PM UTC
14