大网数据广告活动
Windows排障命令

refsutil compression

· 52CE 我爱测

Reference article for the refsutil compression tool, which queries or modifies compression settings on a Resilient File System (ReFS) volume in Windows.

The refsutil compression command is used to query or set the compression parameters on a specified Resilient File System (ReFS) volume. You can check the current compression status, apply compression using different formats, or decompress a compressed volume.

Syntax

refsutil compression <drive> <[/q]> | <[/c] [/f <format>] [/e <engine>] [/cs <size>]>

Parameters

Parameters Description
<drive> Specifies the drive letter of the volume to be compressed in the format E:.
/q Queries the volume's current compression parameters.
/c Compresses the volume with the specified compression parameters.
/f <format> Specifies the compression format to use. Valid options include: <li>LZ4: A fast compression algorithm. <li> ZSTD: A compression algorithm that offers a good balance between compression ratio and speed. <li> NONE: Used to decompress a previously compressed volume. When using NONE, omit the engine and compression chunk size parameters.</li>
/e <engine> Defines the compression level to use, which varies by format: <li> LZ4: Levels 1, 3-12. The default is 1. Levels 3-12 use the LZ4HC algorithm, which provides higher compression ratios at the cost of slower compression speeds. <li> ZSTD: Levels 1-22. The default is 3. Higher levels provide better compression ratios but reduce compression speed and might require more memory (especially levels 20 and greater). Decompression speed remains consistent regardless of the chosen compression level.</li> Omitting the /e parameter or using the value 0 sets the default level for any given compression format.
/cs <size> Specifies the compression chunk size in bytes. This value must be to the power of two (2^n), at least equal to the volume's cluster size, and no greater than 64MB. Larger chunk sizes can enhance compression ratios but might negatively impact read performance for smaller data amounts. Beyond 1MB, the benefits diminish significantly, so larger sizes aren't recommended. If omitted or set to 0, the volume's cluster size is used.

Note: For the /e parameter, the default compression values are subject to change.

Examples

To query the F: volume compression parameters, run the command:

refsutil compression F: /q

To compress the F: volume using the LZ4 format with level 12 compression and a chunk size of 524,288 bytes (512 KB), run the command:

refsutil compression F: /c /f LZ4 /e 12 /cs 524288

To compress the F: volume using the ZSTD format with level 15 compression and a chunk size of 131,072 bytes (128 KB), run the command:

refsutil compression F: /c /f ZSTD /e 15 /cs 131072

To compress the F: volume using the ZSTD format with default compression parameters, run the command:

refsutil compression F: /c /f ZSTD

To decompress the F: volume, run the command:

refsutil compression F: /c /f NONE

Related links

Source: Microsoft Learn / Windows Server documentation by Microsoft and contributors (upstream author metadata: robinharwood). Documentation licensed CC BY 4.0. Code samples are covered by the MIT License. Converted from Markdown, with links normalized and embedded media omitted.

资料来源与适用范围

资料来源
Microsoft Learn / Windows Server documentation
适用范围
Windows Server · Source date 04/02/2025
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。