スキャンし、保護されているすべてのシステムの整合性がファイルし、正しいバージョンと正しくないバージョンが置き換えられますことを確認します。 If this command discovers that a protected file has been overwritten, it retrieves the correct version of the file from the systemroot\ folder, and then replaces the incorrect file.
Important
このコマンドを実行するには、Administrators グループのメンバーとしてログオンしている必要があります。
Syntax
sfc [/scannow] [/verifyonly] [/scanfile=<file>] [/verifyfile=<file>] [/offwindir=<offline windows directory> /offbootdir=<offline boot directory> /offlogfile=<log file path>]
Parameters
Parameter | Description |
---|---|
/scannow | すべての保護されたシステム ファイルの整合性をスキャンし、可能であれば、問題のあるファイルを修復します。 |
/verifyonly | 保護されているすべてのシステム ファイルの整合性をスキャンします。ただし、修復は実行しません。 |
/scanfile <file> |
指定されたファイルの整合性 (完全なパスとファイル名) をスキャンし、問題が検出された場合はその修復を試みます。 |
/verifyファイル <file> |
指定されたファイルの整合性 (完全なパスとファイル名) を確認します。ただし、修復は実行しません。 |
/オフウィンディア <offline windows directory> |
オフライン修復用のオフラインの windows ディレクトリの場所を指定します。 |
/オフブートディレクトリ <offline boot directory> |
オフライン修復用のオフライン ブート ディレクトリの場所を指定します。 |
/offlogfile=<log file path> |
既定以外のログ ファイルを格納する場所を指定します。 |
/? | コマンド プロンプトにヘルプを表示します。 |
Examples
To verify the kernel32.dll file, type:
sfc /verifyfile=c:\windows\system32\kernel32.dll
To set up the offline repair of the kernel32.dll file with an offline boot directory set to D: and an offline windows directory set to D:\Windows, type:
sfc /scanfile=D:\windows\system32\kernel32.dll /offbootdir=D:\ /offwindir=d:\windows