Reduce size container raw

Swaty

New Member
Feb 20, 2017
3
0
1
28
I have a problem to resize my container I can't reduce disk size in 4.4-12/e71b7a74 :

I change my old 2to SATA HDD for a 120 go SSD. My container have 500go disk but I move this container to my new SSD dedicated server.

I tried different size and it's always says :
# pct resize 200 rootfs 70G
unable to shrink disk size

When I try with GUI I can't reduce the disk size:
Screenshot_32.png
My df -h result :
Screenshot_33.png

Regards.
 
There is no option to reduce the size, you'll have to do migration to a smaller disk with e.g. clonezilla. If you like to do overprovisioning, you can change to another disk type like qcow2. Never use raw, you're too limited.
 
if you use ZFS for your containers, you can reduce them via CLI, also during runtime.
 
There is no option to reduce the size, you'll have to do migration to a smaller disk with e.g. clonezilla. If you like to do overprovisioning, you can change to another disk type like qcow2. Never use raw, you're too limited.
Do you have a tutorial or some documentation to do this change?


if you use ZFS for your containers, you can reduce them via CLI, also during runtime.
I use the default param when I deploy my container. By default is ZFS ?
 
I use the default param when I deploy my container. By default is ZFS ?

Have you installed your Proxmox VE on ZFS? If not, it will not work. You need to reinstall with ZFS - and please read about this before, it's a big thing.

Do you have a tutorial or some documentation to do this change?

It's not a Proxmox VE problem, it's a general problem with your guest os. Just google about clonezilla migration
 
I have read something about arc2 for SSD better alternative to ZFS.
I have checked my host and the zfsutils is not present. I made an apt-get install zfsutils and use the command zpool status, and there is "no pools available".

Can I use clonezilla with this configuration ?
upload_2017-2-28_11-48-20.png
My host :
upload_2017-2-28_11-50-17.png

upload_2017-2-28_11-52-44.png
The guest with the problem (id 200) :
upload_2017-2-28_11-51-5.png

I have an another proxmox install in an other data center but I can't make a backup of my actual vm.

INFO: starting new backup job: vzdump 100 --storage local --compress lzo --node $$$$$$ --mode stop --remove 0
ERROR: Backup of VM 100 failed - unable to create temporary directory '/var/lib/vz/dump/vzdump-lxc-100-2017_02_28-09_41_08.tmp' at /usr/share/perl5/PVE/VZDump.pm line 836.
INFO: Backup job finished with errors
TASK ERROR: job errors

Can I simply send my disk.raw to my other datacenter ? Or I have to made a vm for clonezilla ?

If the procedure is to long I have better time to re install proxmox ? And loose a day to reconfigure a new vm ?

Or last option can I use ZFS without uninstall and re install proxmox VE ?

Regards.
 
Last edited:
I have read something about arc2 for SSD better alternative to ZFS.

What? Please read again.
You probably mean L2ARC with ZFS.

I have checked my host and the zfsutils is not present. I made an apt-get install zfsutils and use the command zpool status, and there is "no pools available"

If you did not have the zfsutils installed, there cannot be any zfs pool, which you also wrote, so no ZFS.

Can I use clonezilla with this configuration ?

Clonezilla is a solution for you guest VM, you show your host VM. Please read about clonezilla and how it works.

You can also fill your guest OS all with zeros, do a backup and restore on a "good" storage like QCOW2. This also works and is similar to the stuff you need to do on VMware.

I'd suggest to never use RAW files on a filesystem.

I have an another proxmox install in an other data center but I can't make a backup of my actual vm.

INFO: starting new backup job: vzdump 100 --storage local --compress lzo --node $$$$$$ --mode stop --remove 0
ERROR: Backup of VM 100 failed - unable to create temporary directory '/var/lib/vz/dump/vzdump-lxc-100-2017_02_28-09_41_08.tmp' at /usr/share/perl5/PVE/VZDump.pm line 836.
INFO: Backup job finished with errors
TASK ERROR: job errors

If you do not have enough space on your disk, you cannot do a backup even if there wouldn't be an error.

Can I simply send my disk.raw to my other datacenter ? Or I have to made a vm for clonezilla ?

Again, please read about clonezilla and test in a minimal system how it works. Just setup a simple, plain and minimal OS installation (e.g. just click through $anyos install program) and try to use clonezilla.

If the procedure is to long I have better time to re install proxmox ? And loose a day to reconfigure a new vm ?

I'd only reinstall Proxmox VE to change from non-ZFS to ZFS, but only if you fully understand what ZFS is, how it works and how it can benefit your

Or last option can I use ZFS without uninstall and re install proxmox VE ?

Basically yes, but you need another disk (better two) and a step-by-step guide. I think you're better of with reinstall, much faster and easier.
You need to do a backup of all your VMs and then only import them afterwards. Very easy, if backup works.
 
There is no option to reduce the size, you'll have to do migration to a smaller disk with e.g. clonezilla. If you like to do overprovisioning, you can change to another disk type like qcow2. Never use raw, you're too limited.

Can you use qcow2 for an LXC container? How?
 

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!