Volume Shadow Copy Service VSS_E_BAD_STATE 0×80042301

Last Updated on Monday, 4 November 2013 09:17 Written by admin Saturday, 22 November 2008 03:11

If you have been racking your brains trying to resolve this error:

ERROR: COM call “m_pVssObject->GatherWriterMetadata(&pAsync)” failed.
- Returned HRESULT = 0×80042301
- Error text: VSS_E_BAD_STATE
- Please re-run VSHADOW.EXE with the /tracing option to get more details

Then read on…

Update (28/11/09) – After not being able to get my backup utility to run on 64 bit Vista and Windows 7 machines, I resolved it with the the following two versions:-

vshadow.exe Vista 64 bit 300 KB
vshadow.exe Windows 7 64 bit 340 KB

Interestingly, I found it necessary to install the entire (over 1GB) SDK onto a Vista 64 bit machine in order to get the correct vshadow.exe file – installing it onto a 32 bit Vista machine did not produce the correct file so I assume it is compiled during installation, and is dependant upon the hardware that the SDK is being installed on. I didn’t test this for Windows 7 but assume it’s the same. Below are the links to the two SDK’s

Microsoft Windows Software Development Kit (SDK) Update for Windows Vista

Microsoft Windows Software Development Kit (SDK) for Windows 7

_______________________________________________________________

After much fruitless research I realised I was not going to find the answer to the above error online and so began to go through Microsoft’s Volume Shadow Copy Service SDK, v7.2, something I had avoided as I am not a programmer.

Like most problems the solution is simple if you know where to look. The Volume Shadow Copy Service uses vshadow.exe but although this file keeps the same name it is different for XP, Vista and servers.
The following table, extracted by doing a search for all instances of the file in the above SDK should help you identify which one you need

vshadow.exe VSSReports 185 KB
vshadow.exe debug-server 760 KB

vshadow.exe debug-xp 724 KB

vshadow.exe release-server 344 KB

vshadow.exe release-xp 288 KB

vshadow.exe obj-chk\amd64 387 KB

vshadow.exe obj-chk\ia64 679 KB

vshadow.exe obj-fre\amd64 356 KB

vshadow.exe obj-fre\ia64 662 KB

The 344KB Server release version seems to work on Vista as well
The 288KB XP version only works in XP, not Vista
Interestingly the 185KB version found in the “VSSReports” folder works on Vista but not XP

Running the wrong version will generate the cryptic error and most references to this error send you off on a tortuous debugging path.
Simply using the correct version should solve the problem



6 Comments

  1. Prototyped   |  Tuesday, 10 February 2009 at 6:55 am

    Thank you very much. This is the only place I found straightforward information on the VSS_E_BAD_STATE error from vshadow.

  2. Kevin H   |  Monday, 09 March 2009 at 3:28 am

    This was exactly my problem. Thanks for posting this and saving me what I expect would have been hours of work.

  3. Gimly   |  Thursday, 13 August 2009 at 10:42 am

    Thank you for solution :)

  4. Anonymous   |  Thursday, 12 November 2009 at 3:00 pm

    Thanks! Now that you explain what's going on here, the solution should have been obvious.

  5. Steve   |  Friday, 13 August 2010 at 4:41 pm

    I know this is an old post, so sorry for those that will get this reply and don\’t want it… but I\’m curious what the fix actually is. Did you just download and install the SDK, and the errors went away? Or did you use the SDK to program something?

  6. admin   |  Friday, 13 August 2010 at 4:55 pm

    The “fix” is to use the correct version of vshadow.exe for the operating system that you are using.
    If you google “Volume Shadow Versions” you might find a torrent file containing a collection of all the versions of volumeshadow.exe. Then all you need to do is select the one that works with your OS.
    Hope this helps.