- Error
- Cause
- Solution
- Remove Drive Letters Erroneously Assigned to System Partitions
Error
If a backup fails due to the error VSS_E_INSUFFICIENT_STORAGE, the error VSS_E_INSUFFICIENT_STORAGE message and error code 0x8004231f will be displayed in ReflectMonitor and the subsequent log file. This may look similar to the error below:
Creating Volume Snapshot - Please Wait
Failed: Code: 0x8004231f - Retrying without VSS Writers
ERROR: COM call "m_pVssObject->BackupComplete(&pAsync)" failed.
- Returned HRESULT = 0x80042301
- Error text: VSS_E_BAD_STATE
Gathering Windows Events - Please Wait
Backup aborted! - Failed To Create Volume Snapshot. Result Code: 0x8004231f
Reviewing the VSS log will provide more detailed information that may look similar to the example below:
ERROR: COM call "m_pVssObject->BackupComplete(&pAsync)" failed.
- Returned HRESULT = 0x80042301
- Error text: VSS_E_BAD_STATE
- Setting the VSS context to: 0x00000010
Creating shadow set {VOLUME_GUID} ...
- Adding volume \\?\Volume{VOLUME_GUID}\ [X:\] to the shadow set...
Creating the shadow (DoSnapshotSet) ...
(Waiting for the asynchronous operation to finish...)
Error during the last asynchronous operation.
- Returned HRESULT = 0x8004231f
- Error text: VSS_E_INSUFFICIENT_STORAGE
- Please re-run VSHADOW.EXE with the /tracing option to get more details
Cause
There are several reasons why this error may occur:
- System Partitions Erroneously Assigned Drive Letters
System partitions are required by Windows to boot and operate correctly. Excluding the C: drive, these system partitions are generally small and do not have a drive letter assigned to them. As a result, they are generally not accessible through Explorer and are not often interacted with by users.
Occasionally, the MSR partition and OEM utility and recovery partitions can erroneously be assigned a drive letter and cause VSS to fail when creating a snapshot. - Insufficient Shadow Storage Space
VSS uses copy on write snapshotting, meaning that as changes occur to the system, the amount of data in the shadow storage space increases. If the shadow storage space is not large enough, the backup can fail. - Old VSS Snapshots
During normal Windows operation, restore points are created during software installation and other regular operational tasks. These restore points create snapshots that reside in an area of the disk and consume disk space.
Solution
Depending on which one of the causes above is most applicable, the following solution(s) can be applied:
Remove Drive Letters Erroneously Assigned to System Partitions
First launch Windows Disk Management by right-click on the Windows start button, then selecting 'Disk Management':
Launch 'Run' with the Windows Key + R key combination, and search for 'diskmgmt.msc':
Right-click the relevant partition and select 'Change Drive Letter and Paths...'. In the window that opens, select 'Remove':
If drive letter cannot be removed using Disk Management, the drive letter can also be removed using DiskPart. To do this, launch an elevated command prompt by following the steps in this article.
In the command prompt window, launch DiskPart using the command below:
DiskPart
The local volumes can be listed using the following command:
List Volume
Select the relevant volume that has erroneously been assigned a drive letter.
Select Volume 2
Finally, remove the drive letter by replacing X with the relevant drive letter:
Remove Letter = X
Increase Shadow Storage
The maximum size allocated to shadow copy storage can be increased using the 'vssadmin' command.
To do this, open an elevated command prompt, and run the following command:
vssadmin Resize ShadowStorage /For=c: /On=c: /Maxsize=10%
For non-server operating systems, the shadow storage resides on the drive that is being imaged. As a result, C: should be changed for the drive that was being imaged when the error message occurre. The 'Maxsize' can be increased or decreased as necessary, but 10% is a good default value.
Delete Old VSS Snapshots
Old VSS snapshots can also be deleted using the 'vssadmin' command.
First launch and an elevated command prompt. Different commands can then be run depending on the snapshots that will be delted.
To delete all snapshots, run the following command:
vssadmin delete shadows /all
To delete the oldest snapshot only, run the following command:
vssadmin delete shadows /oldest
To delete specific snapshots, first identify the ID of snapshot that will be deleted. The following command can be used to display a list of the snapshots on the system and the associated IDs:
vssadmin list shadows
A specific snapshot can then be deleted by specifying the snapshot ID, similar to the example below:
vssadmin delete shadows /shadow={42bb9090-723c-4107-8954-92006026defd}