Notes on Using ReFS
什么是ReFS
浏览本文的时候,默认你已经了解了ReFS的基本概念以及优劣。如果不了解,可以参考ReFS概述。
本文只讨论自己使用ReFS的注意事项,若有命令参数等请自行参考本文的超链接官方文档。
并且本文对ReFS的归纳并不完整,请参阅官方文档。
ReFS注意事项
下面只讨论作为数据盘的情况,不太建议用作系统盘。虽然新版本的Windows支持从REFS引导,但是社区依然发现在系统还原这种基础问题上依然有问题。
强烈建议在使用前,禁止自动升级REFS版本。不然在回撤Windows版本的时候,你会无法访问数据盘,变成RAW分区。
REFS的版本升级是不可逆的,升级后无法降级!!!
日常维护
禁止自动升级(推荐)
1 | |
手动升级(推荐)
在你确认你不需要降级的情况下,手动升级ReFS版本。高版本的ReFS会有更好的性能和稳定性。
1 | |
数据压缩(推荐)
这个挺好用的。
数据压缩文档
重复数据删除(推荐)
数据修复(必看)
分析和解决文件系统损坏问题
对于变成RAW(损坏的卷)执行恢复作以检索数据。
高级功能
ReFS完整性流(推荐)
完整性流是 ReFS 的一项功能,它可以确保文件数据的完整性。它使用 CRC32 校验和来验证文件数据的完整性。启用完整性流后,ReFS 会在每次读取文件时计算 CRC32 校验和,并将其与存储在文件中的校验和进行比较。如果校验和不匹配,则 ReFS 会尝试修复文件。
完整性流文档
Get-FileIntegrity
若要查看是否为文件数据启用了完整性流,请使用 Get-FileIntegrity cmdlet。
1 | |
1 | |
也可以使用 Get-Item cmdlet 获取指定目录中所有文件的完整性流设置。
Set-FileIntegrity
若要对文件数据启用/禁用完整性流,请使用 Set-FileIntegrity cmdlet。
1 | |
也可以使用 Get-Item cmdlet 设置指定文件夹中所有文件的完整性流设置。
1 | |
Set-FileIntegrity cmdlet 也可直接用于卷和目录。
1 | |
高级重复数据删除
高级重复数据删除指令
我一直分不清ReFSDedupSchedule和ReFSDedupScrubSchedule区别。总之我一直用ReFSDedupScrubSchedule。
不过基本上常用的下面这些
1 | |
What is ReFS
While reading this article, it is assumed that you already understand the basic concepts, advantages, and disadvantages of ReFS. If not, you can refer to the ReFS Overview.
This article only discusses considerations for personal use of ReFS. For command parameters and other details, please refer to the official document hyperlinks within this text.
Also, this article is not a complete summary of ReFS; please consult the official documentation.
Notes on ReFS
The following only discusses the scenario of using ReFS as a data drive. It is not strongly recommended for use as a system drive. Although newer versions of Windows support booting from ReFS, the community has still found issues with basic functionalities like system restore.
It is highly recommended to disable automatic ReFS version upgrades before use. Otherwise, when rolling back the Windows version, you may be unable to access the data drive, and it might become a RAW partition.
ReFS version upgrades are irreversible; once upgraded, it cannot be downgraded!!!
Daily Maintenance
Disable Automatic Upgrade (Recommended)
1 | |
Manual Upgrade (Recommended)
Manually upgrade the ReFS version when you are certain you will not need to downgrade. Higher versions of ReFS offer better performance and stability.
1 | |
Data Compression (Recommended)
This feature is quite useful.
Data Compression Documentation
Data Deduplication (Recommended)
Data Deduplication Documentation
Data Recovery (Must Read)
Analyze and Resolve Filesystem Corruption Issues
Perform Recovery on a RAW (Corrupted) Volume to Retrieve Data.
Advanced Features
ReFS Integrity Streams (Recommended)
Integrity Streams is a feature of ReFS that ensures the integrity of file data. It uses CRC32 checksums to verify the integrity of file data. When Integrity Streams is enabled, ReFS calculates a CRC32 checksum each time a file is read and compares it with the checksum stored in the file. If the checksums do not match, ReFS attempts to repair the file.
Integrity Streams Documentation
Get-FileIntegrity
To check whether Integrity Streams is enabled for file data, use the Get-FileIntegrity cmdlet.
1 | |
1 | |
You can also use the Get-Item cmdlet to retrieve the Integrity Streams settings for all files in a specified directory.
Set-FileIntegrity
To enable/disable Integrity Streams for file data, use the Set-FileIntegrity cmdlet.
1 | |
You can also use the Get-Item cmdlet to set the Integrity Streams settings for all files in a specified folder.
1 | |
The Set-FileIntegrity cmdlet can also be applied directly to volumes and directories.
1 | |
Advanced Deduplication
Advanced Deduplication Commands
I have always been unclear about the difference between ReFSDedupSchedule and ReFSDedupScrubSchedule. In any case, I always use ReFSDedupScrubSchedule.
However, the commonly used ones are basically the following:
1 | |