Export (0) Print
Expand All

MSCluster_Resource class

The MSCluster_Resource class is a dynamic WMI class that represents a cluster resource.

Note  The following object is available for use in Windows Server 2008, Windows Server 2008 R2, Windows Server 2012, and Windows Server 2012 R2. It may be altered or unavailable in subsequent versions.

The following syntax is simplified from Managed Object Format (MOF) code and includes all inherited properties.

Syntax

[Dynamic, Provider ("MS_CLUSTER_PROVIDER"), UUID ("{C2862F9C-34DE-4b16-9EE3-099D078E9F59}")]class MSCluster_Resource : MSCluster_LogicalElement
{
  string             Caption;
  datetime           InstallDate;
  string             Status;
  uint32             Flags;
  uint32             Characteristics;
  string             Name;
  string             Description;
  string             DebugPrefix;
  uint32             IsAlivePollInterval;
  uint32             LooksAlivePollInterval;
  uint32             PendingTimeout;
  uint32             MonitorProcessId;
  boolean            PersistentState;
  uint32             RestartAction;
  uint32             RestartPeriod;
  uint32             RestartThreshold;
  uint32             RetryPeriodOnFailure;
  boolean            SeparateMonitor;
  string             Type;
  uint32             State;
  string             InternalState;
  uint32             ResourceClass;
  uint32             Subclass;
  MSCluster_Property PrivateProperties;
  string             CryptoCheckpoints[];
  string             RegistryCheckpoints[];
  boolean            QuorumCapable;
  boolean            LocalQuorumCapable;
  boolean            DeleteRequiresAllNodes;
  boolean            CoreResource;
  uint32             DeadlockTimeout;
  string             ResourceSpecificStatus;
  uint32             RestartDelay;
  boolean            IsClusterSharedVolume;
};

Members

The MSCluster_Resource class has these types of members:

Methods

The MSCluster_Resource class has these methods.

MethodDescription
AddCryptoCheckpoint

Adds an encrypted crypto checkpoint to the resource.

AddDependency

Creates a dependency relationship between two resources.

AddPossibleOwner

Adds a possible owner (host) node to the list of possible owners for this resource.

Windows Server 2003:  

This method is not supported before Windows Server 2008.

AddRegistryCheckpoint

Adds a registry checkpoint to the resource.

BringOnline

Brings a resource online.

CreateResource

Creates a resource.

DeleteResource

Deletes a resource.

Windows Server 2003:  

This method has a Static qualifier.

ExecuteResourceControl

Executes a control code on the resource.

Windows Server 2003:  

This method is not supported before Windows Server 2008.

FailResource

Forces this resource to become unavailable to simulate failure. This method is used by applications to test their failover configurations.

GetDependencies

Gets the resource dependency expression.

Windows Server 2003:  

This property is not supported before Windows Server 2008.

MoveToNewGroup

Moves the resource to a different group.

ReleaseAddress

Releases the IPv4 address DHCP lease. Valid only for IP address resources.

Windows Server 2003:  

This method is not supported before Windows Server 2008.

RemoveCryptoCheckpoint

Removes a crypto key from the list of keys being checkpointed for the resource.

RemoveDependency

Removes a dependency relationship between two resources.

RemovePossibleOwner

Removes a possible owner node (host) from the list of possible owners for this resource.

Windows Server 2003:  

This method is not supported before Windows Server 2008.

RemoveRegistryCheckpoint

Removes a registry key from the list of keys being checkpointed for the resource.

Rename

Renames the resource.

RenewAddress

Renews the IPv4 address DHCP lease. Valid only for IP address resources.

Windows Server 2003:  

This method is not supported before Windows Server 2008.

SetDependencies

Sets the resource dependency expression.

Windows Server 2003:  

This property is not supported before Windows Server 2008.

TakeOffline

Takes the resource offline.

 

Properties

The MSCluster_Resource class has these properties.

Caption
Data type: string
Access type: Read-only

Provides a short textual description of the resource.

Inherited from MSCluster_LogicalElement.

Characteristics
Data type: uint32
Access type: Read/write

Describes the characteristics of the resource. For a list of possible values, see CLUSCTL_RESOURCE_GET_CHARACTERISTICS.

Inherited from MSCluster_LogicalElement.

CoreResource
Data type: boolean
Access type: Read/write

If True, indicates that the resource is essential to the cluster and cannot be deleted.

CryptoCheckpoints
Data type: string array
Access type: Read-only

Provides a list of crypto checkpoints for the resource.

DeadlockTimeout
Data type: uint32
Access type: Read/write

Indicates the length of time to wait, in milliseconds, before declaring a deadlock in any call into a resource.

Windows Server 2003:  

This property is not supported before Windows Server 2008.

DebugPrefix
Data type: string
Access type: Read/write

This property is not supported.

Windows Server 2003:  

Provides access to the resource's DebugPrefix property.

DeleteRequiresAllNodes
Data type: boolean
Access type: Read/write

If True, the resource cannot be deleted unless all nodes are active. Setting this property to True adds the CLUS_CHAR_DELETE_REQUIRES_ALL_NODES characteristic to the resource.

Description
Data type: string
Access type: Read/write

Provides access to the resource's Description property.

Inherited from MSCluster_LogicalElement.

Flags
Data type: uint32
Access type: Read/write

Describes the flags set for the resource. For a list of possible values, see CLUSCTL_RESOURCE_GET_FLAGS..

Inherited from MSCluster_LogicalElement.

InstallDate
Data type: datetime
Access type: Read-only

Indicates when the resource was installed. A lack of a value does not indicate that the resource is not installed.

Inherited from MSCluster_LogicalElement.

InternalState
Data type: string
Access type: Read-only

This property is not supported.

Windows Server 2008:  

The current internal state of the resource.

IsAlivePollInterval
Data type: uint32
Access type: Read/write
Qualifiers: Units ("Milliseconds")

Provides access to the resource's IsAlivePollInterval property, which is the recommended interval in milliseconds at which the Cluster Service should poll the resource to determine whether it is operational. If the property is set to 0xFFFFFFFF, the Cluster Service uses the IsAlivePollInterval property for the resource type associated with the resource.

IsClusterSharedVolume
Data type: boolean
Access type: Read-only

Specifies if the resource is a cluster shared volume resource.

Windows Server 2008 and Windows Server 2003:  

This property is not supported before Windows Server 2008 R2.

LocalQuorumCapable
Data type: boolean
Access type: Read/write

The resource can be selected as the quorum resource in clusters configured using the -localquorum switch.

LooksAlivePollInterval
Data type: uint32
Access type: Read/write
Qualifiers: Units ("Milliseconds")

Provides access to the resource's LooksAlivePollInterval property, which is the recommended interval in milliseconds at which the Cluster Service should poll the resource to determine whether it appears operational. If the property is set to 0xFFFFFFFF, the Cluster Service uses the LooksAlivePollInterval property for the resource type associated with the resource.

MonitorProcessId
Data type: uint32
Access type: Read/write

Provides the process ID of the resource host service that is currently hosting the resource.

Windows Server 2003:  

This property is not supported before Windows Server 2008.

Name
Data type: string
Access type: Read-only
Qualifiers: Key

Provides the name of the resource.

Inherited from MSCluster_LogicalElement.

PendingTimeout
Data type: uint32
Access type: Read/write

Provides access to the resource's PendingTimeout property. If a resource cannot be brought online or taken offline in the number of milliseconds specified by the PendingTimeout property, the resource is forcibly terminated.

Windows Server 2003:  

This property is not supported before Windows Server 2008.

PersistentState
Data type: boolean
Access type: Read/write

Provides access to the resource's PersistentState property, which specifies whether the resource should be brought online or left offline when the Cluster Service is started.

PrivateProperties
Data type: MSCluster_Property
Access type: Read/write

Provides access to the private properties of the resource.

QuorumCapable
Data type: boolean
Access type: Read/write

The resource can be selected as the quorum resource for the cluster.

RegistryCheckpoints
Data type: string array
Access type: Read-only

Provides a list of registry checkpoints for the resource.

ResourceClass
Data type: uint32
Access type: Read/write

Gets or sets the resource class of a resource.

ResourceSpecificStatus
Data type: string
Access type: Read-only

Provides a resource-specific status message that complements the current resource state.

Windows Server 2003:  

This property is not supported before Windows Server 2008.

RestartAction
Data type: uint32
Access type: Read/write

Provides access to the resource's RestartAction property, which is the action to be taken by the Cluster Service if the resource fails. The following are the possible values.

ValueMeaning
0

Do not restart the resource after a failure.

1

Restart the resource after a failure. If the resource exceeds its restart threshold within its restart period, do not attempt to failover the group to another node in the cluster.

2

Restart the resource after a failure. If the resource exceeds its restart threshold within its restart period, attempt to fail over the group to another node in the cluster. This is the default setting.

 

RestartDelay
Data type: uint32
Access type: Read-only

Indicates the time delay before a failed resource is restarted.

Windows Server 2003:  

This property is not supported before Windows Server 2008.

RestartPeriod
Data type: uint32
Access type: Read/write

Provides access to the resource's RestartPeriod property, which is interval of time, in milliseconds, during which a specified number of restart attempts can be made on a nonresponsive resource.

RestartThreshold
Data type: uint32
Access type: Read/write

Provides access to the resource's RestartThreshold property which is the maximum number of restart attempts that can be made on a resource within an interval defined by the RestartPeriod property before the Cluster Service initiates the action specified by the RestartAction property.

RetryPeriodOnFailure
Data type: uint32
Access type: Read/write

Provides access to the resource's RetryPeriodOnFailure property, which is the interval of time (in milliseconds) that a resource should remain in a failed state before the Cluster service attempts to restart it.

SeparateMonitor
Data type: boolean
Access type: Read/write

Provides access to the resource's SeparateMonitor property, which indicates whether the resource requires its own Resource Monitor.

State
Data type: uint32
Access type: Read-only

The current state of the resource. The following are the possible values. For a list of possible state values, see GetClusterResourceState.

ValueMeaning
StateUnknown
-1

The operation was not successful.

Inherited
0

TBD

Initializing
1

The resource is performing initialization.

Online
2

The resource is operational and functioning normally.

Offline
3

The resource is not operational. This value will be returned if the resource reported a state of ClusterResourceOffline (3) or ClusterResourceCannotComeOnlineOnThisNode (127).

Failed
4

The resource has failed. This value will be returned if the resource reported a state of ClusterResourceFailed (4) or ClusterResourceCannotComeOnlineOnAnyNode (126).

Pending
128

The resource is coming online or going offline.

Online Pending
129

The resource is coming online.

Offline Pending
130

The resource is going offline.

 

Status
Data type: string
Access type: Read-only

Indicates the current status of the resource.

Inherited from MSCluster_LogicalElement.

Subclass
Data type: uint32
Access type: Read/write

Provides the list of references to nodes that can be the owner of this resource.

Type
Data type: string
Access type: Read/write

Provides access to the resource's Type property, which is the name for the resource's type.

Remarks

The MSCluster_Resource class is derived from the MSCluster_LogicalElement class.

Requirements

Minimum supported client

None supported

Minimum supported server

Windows Server 2003 Datacenter, Windows Server 2003 Enterprise

Namespace

\\.\Root\MSCluster

MOF

ClusWmi.mof

 

 

Show:
© 2014 Microsoft