Enable inline data compaction for FAS systems
You can enable inline data compaction on FAS systems with Flash Pool (hybrid) aggregates or HDD aggregates at the volume or aggregate level by using the volume efficiency
cluster shell command. Data compaction is disabled by default for FAS systems.
If you enable data compaction at the aggregate level, data compaction is enabled on any new volume that is created with a volume space guarantee of none
in the aggregate. Enabling data compaction on a volume on an HDD aggregate uses additional CPU resources.
-
Change to the advanced privilege level:
set -privilege advanced
-
Check the data compaction state of the volumes and aggregates for the desired node:
volume efficiency show -volume <volume_name>
-
Enable data compaction on volume:
volume efficiency modify -volume <volume_name> -data-compaction true
If data compaction is set to
false
for either an aggregate or a volume, then compaction fails. Enabling compaction does not compact existing data; only new writes to the system are compacted. Thevolume efficiency start
command contains more information about how to compact existing data (in ONTAP 9.1 and later). For more information, see the ONTAP command reference. -
View the compaction statistics:
volume efficiency show -volume <volume_name>