File History Command Line Tool

There’s a command called fhmanagew.exe that comes with Windows 10 (not sure about Windows 8.1, but I assume so).  The full path is c:\windows\system32\fhmanagew.exe. This tool is used for managing certain aspects of File History, and contains a few undocumented features.

From what I can tell,  Microsoft has only mentioned the -cleanup argument which is used like: fhmanagew.exe -cleanup <# days> [-quiet]

A couple examples:
fhmanagew.exe -cleanup 365
fhmanagew.exe -cleanup 30 -quiet

I used strings.exe by sysinternals (a Windows port of a handy *nix tool for extracting raw strings from a binary file) to analyze fhmanagew.exe and found the following arguments are available:

-autoplayBring up the File History UI
-backupnowRun backup
-cleanup <days> [-quiet]Cleanup files older than a certain number of days on your File History destination drive.
-migrate <path>Seems to be used for migrating your file history to a new destination. Destination must be added to File History first.
-stopStop File History

This blog post over at mentions a few of the args I’ve discovered with a short description of them.  It doesn’t seem to mention the -migrate command, however.

Leave a Reply