February 14th, 2016

PowerTip: Flush file system cache by using PowerShell

Doctor Scripto
Scripter

Summary: Use Windows PowerShell to forcibly write the file system cache to a drive.

Hey, Scripting Guy! Question How can I use Windows PowerShell to forcibly flush the volume cache by writing it to a drive?

Hey, Scripting Guy! Answer Use the Write-VolumeCache cmdlet and specify the drive letter, for example:

Write-VolumeCache c

Note  There is no colon following the drive letter.

Author

The "Scripting Guys" is a historical title passed from scripter to scripter. The current revision has morphed into our good friend Doctor Scripto who has been with us since the very beginning.

0 comments

Discussion are closed.