Estimate space needed to move zvol

rwfitzy

Explorer
Joined
Nov 20, 2014
Messages
53
I am planning to move a zvol into another dataset. I'm assuming I'll need to create the new zvol in its new location and transfer the data finally deleting the existing zvol. I'd like to take this opportunity to reduce its size. My question is which zvol property should I look at for determining how much space is currently being used and fit into my new zvol. Here are the existing zvol properties, is the safest to use used - available = disk space used to determine used space or use logicalused?

Code:
NAME                   PROPERTY         VALUE     SOURCE
Backup/iscsi/sp-steph  used             152G      -
Backup/iscsi/sp-steph  available        43.1G     -
Backup/iscsi/sp-steph  referenced       113G      -
Backup/iscsi/sp-steph  quota            -         -
Backup/iscsi/sp-steph  usedbysnapshots  0         -
Backup/iscsi/sp-steph  usedbydataset    113G      -
Backup/iscsi/sp-steph  written          113G      -
Backup/iscsi/sp-steph  logicalused      84.6G     -


With the calculation showing 108.9 used space, if I create a 125GB zvol, the data will fit and leave ~16GB free space? Let me add this zvol is used solely for backup and the backup software says the backup is was 86.4GB.
 
Last edited:

rwfitzy

Explorer
Joined
Nov 20, 2014
Messages
53
I have not moved the zvol yet. I believe my assumption on how to move the zvol will be correct. My questions are pertaining to if I'm calculating the space needed is correct.
 

rwfitzy

Explorer
Joined
Nov 20, 2014
Messages
53
So, yeah, this is hard to believe, but I guess true? A zvol with a size of 150 GB and used space of 139 GB can have an overhead of 45 GB. This is what the same zvol status looks like now...

Code:
NAME                              PROPERTY         VALUE     SOURCE
Backup/iscsi/sp-steph  used             184G      -
Backup/iscsi/sp-steph  available        1.91T     -
Backup/iscsi/sp-steph  referenced       184G      -
Backup/iscsi/sp-steph  quota            -         -
Backup/iscsi/sp-steph  usedbysnapshots  0         -
Backup/iscsi/sp-steph  usedbydataset    184G      -
Backup/iscsi/sp-steph  written          184G      -
Backup/iscsi/sp-steph  logicalused      139G      -


The used space in the FreeNAS GUI is 184.3 GB. I dropped the quota since it is unmanageable. Please let me know if there is anything I should be doing differently.
 
Top