I'm attempting to hash every file on my C:\ drive with
fciv.exe c:\ -r -md5 -xml hashes.xml
The xml file does not initially exist, but after the command is entered, the xml file is created. The command takes about 5 minutes to complete, but at the end, there is nothing in the xml file. The only thing is creates is a large error file that contains numerous "access denied" and "this file is being used by another process" errors.
I am running the command as an administrator. I even tried enabling the net user administrator account to run it from, but still the same results.
I did a test on a single file and it works fine. It outputs an MD5 hash no problem.
So my question is, what am I doing wrong? How can I hash my entire C drive using an fciv command?
11 Answer
There are two issues preventing it from running as desired.
- C:\ root has restrictions on what can be run.
- A file in use, e.g. fciv.exe itself, is locked.
Also, fciv apparently does not write intermediate results to disk and then concatenate them, so on long operations, it may runs out of memory.
Workarounds:
- To avoid files locked while in use, run fciv on an unmounted partition. You can do so either by booting from Windows PE, and running fciv on the actual HDD, or by making an image, e.g. with Macrium Reflect Free, mounting the image (check Enable access to restricted folders and make writable). You should be doing this regularly anyway, to keep an image in case something breaks.
- Get a checksum for one folder at a time. If there's not enough ram available for this 32-bit application, then run it on subfolders.
Wait! The command below took about an hour to complete on one PC, creating ~7MB of XML output!
C:\temp>fciv.exe "c:\Program Files" -r md5 -xml out.xml