Image pruning and storage optimizations for SQL Server incrementally updated images

Pruning

Pruning allows image refreshes to carry on forever. Pruning is automatic after the number of refreshes specified in Windocks\config\node.conf MAX_REFRESHES_BEFORE_PRUNING (usually 100). If you change this number, then restart the Windocks service.

Pruning will automatically delete old containers, clones and restore points marked with !. If you do not want automatic deletion of old containers, clones or restore points for an image, then turn off scheduled refreshes for that image. To prune manually, select Refresh from the top menu, find your image and Prune (all the way on the right).

VHDX storage optimizations

Each time an incremental transaction log backup or set of backups is applied to an image, a new VHDX is created. If you do frequent updates, then storage is use quickly.

In node.conf, the following settings are available for you:

# Values to optimize VHDX storage and performance

# Runs Optimize Vhdx on each VHDX
# OPTIMIZE_VHD="1"

#Writes Vhd info to windocks\log\sqlLog.txt
# DEBUG_VHD="1"

# Uses less disk space in parent for full backup
# OPTIMIZE_PARENT_SIZE_VHD="1"

# The parent VHD is formatted with this allocation unit size, must be a multiple of PARENT_PHYSICAL_SECTOR_SIZE_IN_BYTES below
# PARENT_ALLOCATION_UNIT_SIZE_IN_BYTES="4096"

# All Restores use this block size. Allowed values are 512, 1024, 2048, 4096, 8192, 16384, 32768, and 65536
# AND must be a multiple of the disk on which the backup was created
# RESTORE_BLOCK_SIZE_IN_BYTES="4096"

# VHDX block sizes minimum of 1024 (Amount by which the dynamic disks are increased each time needed)
# PARENT_BLOCK_SIZE_IN_KB="1024"
# DIFFERENTIAL_BLOCK_SIZE_IN_KB="1024"

# Must be 512 or 4096
# PARENT_PHYSICAL_SECTOR_SIZE_IN_BYTES="4096"
# PARENT_LOGICAL_SECTOR_SIZE_IN_BYTES="512"