Solved Shrinking a ZFS disk in VMware

enfield303

New Member


Messages: 4

Hello folks, we're using FreeBSD 12.0 and was just wondering what the procedure is to shrink the ZFS disk - do we simply shrink it in VMware then is it:

gpart recover
gpart resize -i 3 disk

Thanks for any help
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 7,293
Messages: 29,742

was just wondering what the procedure is to shrink the ZFS disk
Simple answer, you don't, it's not supported. You cannot shrink a (single disk) pool. You will have to backup the data, rebuild and restore.
 
OP
OP
E

enfield303

New Member


Messages: 4

Of course, I should've realised that but I think because I'm dealing with a virtual environment and I wouldn't be removing physical drives then it never occurred to me, thanks anyway.
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 7,293
Messages: 29,742

I don't recommend shrinking any filesystem actually. Growing is usually not an issue. For this reason I typically set up my VMs with a really small disk. Growing them is easy (for both UFS and ZFS) and generally well supported.
 
Top