Win32_ShadowCopy class
The Win32_ShadowCopy class is a storage extent that represents a duplicate copy of the original volume at a previous time.
The following syntax is simplified from Managed Object Format (MOF) code and includes all of the inherited properties. Properties and methods are in alphabetic order, not MOF order.
Syntax
class Win32_ShadowCopy : CIM_LogicalElement
{
string Caption;
string Description;
string ID;
datetime InstallDate;
string Name;
string SetID;
string ProviderID;
string Status;
uint32 Count;
string DeviceObject;
string VolumeName;
string OriginatingMachine;
string ServiceMachine;
string ExposedName;
uint32 State;
boolean Persistent;
boolean ClientAccessible;
boolean NoAutoRelease;
boolean NoWriters;
boolean Transportable;
boolean NotSurfaced;
boolean HardwareAssisted;
boolean Differential;
boolean Plex;
boolean Imported;
boolean ExposedRemotely;
boolean ExposedLocally;
};
Members
The Win32_ShadowCopy class has these types of members:
- Methods
- Properties
Methods
The Win32_ShadowCopy class has these methods.
Method | Description |
---|---|
Create | Creates a shadow copy by using the specified context. |
Properties
The Win32_ShadowCopy class has these properties.
Caption
Data type: string
Access type: Read-only
Short textual description of the object. This property is inherited from CIM_LogicalElement.
ClientAccessible
Data type: boolean
Access type: Read-only
If true, the shadow copy is created by the Windows Previous Versions component.
Count
Data type: uint32
Access type: Read-only
Number of shadow copies in a shadow copy set to which a shadow copy belongs.
Description
Data type: string
Access type: Read-only
Textual description of the object. This property is inherited from CIM_LogicalElement.
DeviceObject
Data type: string
Access type: Read-only
Windows object manager name for an underlying storage device that supports the original volume.
Differential
Data type: boolean
Access type: Read-only
If true, the shadow copy is created by a differential shadow copy provider. The provider can be implemented in hardware or software.
ExposedLocally
Data type: boolean
Access type: Read-only
If true, the shadow copy is exposed on the local computer with a drive letter or mount point. If ExposedLocally and ExposedRemotely are not set, the shadow copy is hidden.
ExposedName
Data type: string
Access type: Read-only
File system name of a shadow copy when it is exposed. The ExposedName property might contain a drive letter or mount point. The ExposedName property is NULL when a shadow copy is hidden or otherwise not exposed.
ExposedRemotely
Data type: boolean
Access type: Read-only
If true, the shadow copy is exposed on a remote computer with a network share. If ExposedRemotely and ExposedLocally are not set, the shadow copy is hidden.
HardwareAssisted
Data type: boolean
Access type: Read-only
If true, the shadow copy is created by a hardware shadow copy provider.
ID
Data type: string
Access type: Read-only
Unique identifier for a shadow copy on the system.
Imported
Data type: boolean
Access type: Read-only
If true, the shadow copy is imported to a computer by using the Import method and is not created by using the Create method.
InstallDate
Data type: datetime
Access type: Read-only
Date and time the object was installed. This property does not need a value to indicate that the object is installed. This property is inherited from CIM_LogicalElement.
Name
Data type: string
Access type: Read-only
Label by which the object is known. When subclassed, this property can be overridden to be a key property. This property is inherited from CIM_LogicalElement.
NoAutoRelease
Data type: boolean
Access type: Read-only
If true, the shadow copy is retained after the requestor process ends. If false, the shadow copy is automatically deleted when the requestor process ends.
NotSurfaced
Data type: boolean
Access type: Read-only
If true, the shadow copy is not currently in the device namespace of a local computer.
NoWriters
Data type: boolean
Access type: Read-only
If true, the shadow copy is created with the involvement of the shadow copy writer components.
OriginatingMachine
Data type: string
Access type: Read-only
Name of the computer that hosts the original volume.
Persistent
Data type: boolean
Access type: Read-only
If true, the shadow copy is persistent across reboots.
Plex
Data type: boolean
Access type: Read-only
If true, the shadow copy is created by a split mirror shadow copy provider. The provider can be implemented in hardware or software.
ProviderID
Data type: string
Access type: Read-only
Unique identifier for a shadow provider that creates a shadow.
ServiceMachine
Data type: string
Access type: Read-only
Name of the computer that services the shadow copy.
SetID
Data type: string
Access type: Read-only
Unique identifier for a shadow copy set to which the shadow belongs.
State
Data type: uint32
Access type: Read-only
Current state of a shadow copy.
Value | Meaning |
---|---|
0 | Unknown |
1 | Preparing |
2 | ProcessingPrepare |
3 | Prepared |
4 | ProcessingPrecommit |
5 | Precommitted |
6 | ProcessingCommit |
7 | Committed |
8 | ProcessingPostcommit |
9 | Created |
10 | Aborted |
11 | Deleted |
12 | Count |
Status
Data type: string
Access type: Read-only
Current status of the object. This property is inherited from CIM_LogicalElement.
Values include the following:
"OK"
"Error"
"Degraded"
"Unknown"
"Pred Fail"
"Starting"
"Stopping"
"Service"
"Stressed"
"NonRecover"
"No Contact"
"Lost Comm"
Transportable
Data type: boolean
Access type: Read-only
If true, the shadow copy can be surfaced on another computer. If false, and the volumes are surfaced locally, it may not be possible to surface them later on a different computer.
VolumeName
Data type: string
Access type: Read-only
Name of the original volume for which a shadow copy is made.
Remarks
Note This class is unavailable for 32-bit applications on Windows Server 2008 x64. To access the class with Visual Studio, go to Project Properties, then General, and un-check the Prefer 32-bit box.
Examples
The Get Remote Shadow Volume Information With Powershell PowerShell sample on TechNet gallery uses Win32_ShadowCopy to retrieve shadow volume information.
Requirements
Minimum supported client |
None supported |
Minimum supported server |
Windows Server 2003 |
Namespace |
Root\CIMV2 |
MOF |
Vss.mof |
DLL |
Vsswmi.dll |