Posts Tagged ‘0x2’

In monitoring we recently saw a Scheduled Task for a Shadow Copy Job failing with 0x2.

After running the Action manually in CMD I go the below error

C:\Windows\system32>C:\Windows\system32\vssadmin.exe Create Shadow /AutoRetry=15 /For=\\?\Volume{411116ac-84e511-11116-80d4-11111111111}\

vssadmin 1.1 – Volume Shadow Copy Service administrative command-line tool
(C) Copyright 2001-2013 Microsoft Corp.

Error: Either the specified volume was not found or it is not a local volume.

Running this in powershell listed all the Volumes with their current GID

GWMI -namespace root\cimv2 -class win32_volume | FL -property Label,DriveLetter,DeviceID,SystemVolume,Capacity,Freespace

Turns out the job was for a GUID that didn’t exist anymore on that system. After checking the other ShadowCopyVolume Tasks to make sure all the Disks were accounted for , I deleted the errored job

VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.22_1171]
Rating: 0 (from 0 votes)

When running a bat file scheduled task coming back with 0x2 

You need to put the exit of the IF statement to exit 0

VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.22_1171]
Rating: 0 (from 0 votes)