GetClusterQuorumResource function (clusapi.h)

Returns the name of a cluster's quorum resource. The PCLUSAPI_GET_CLUSTER_QUORUM_RESOURCE type defines a pointer to this function.

Syntax

DWORD GetClusterQuorumResource(
  [in]      HCLUSTER hCluster,
  [out]     LPWSTR   lpszResourceName,
  [in, out] LPDWORD  lpcchResourceName,
  [out]     LPWSTR   lpszDeviceName,
  [in, out] LPDWORD  lpcchDeviceName,
  [out]     LPDWORD  lpdwMaxQuorumLogSize
);

Parameters

[in] hCluster

Handle to an existing cluster.

[out] lpszResourceName

Pointer to a null-terminated Unicode string containing the name of the cluster's quorum resource. The name is read from the quorum resource's Name common property. Do not pass NULL for this parameter.

[in, out] lpcchResourceName

Pointer to the size of the lpszResourceName buffer as a count of characters. On input, specify the maximum number of characters the buffer can hold, including the terminating NULL. On output, specifies the number of characters in the resulting name, excluding the terminating NULL.

[out] lpszDeviceName

Pointer to a null-terminated Unicode string containing the path to the location of the quorum log files maintained by the Cluster service. Do not pass NULL for this parameter.

[in, out] lpcchDeviceName

Pointer to the size of the lpszDeviceName buffer as a count of characters. On input, specify the maximum number of characters the buffer can hold, including the terminating NULL. On output, specifies the number of characters in the resulting name, excluding the terminating NULL.

[out] lpdwMaxQuorumLogSize

Pointer to the maximum size (in bytes) of the log being maintained by the quorum resource. Do not pass NULL for this parameter.

Return value

If the operation succeeds, the function returns ERROR_SUCCESS.

If the operation fails, the function returns a system error code. The following is one of the possible values.

Return code Description
ERROR_MORE_DATA
The lpszResourceName or the lpszDeviceName buffer is not big enough to hold the result. The lpcchResourceName and lpcchDeviceName parameters return the number of characters in the result, excluding the terminating NULL.

Remarks

Note that lpcchName refers to a count of characters and not a count of bytes, and that the returned size does not include the terminating NULL in the count. For more information on sizing buffers, see Data Size Conventions.

Requirements

Requirement Value
Minimum supported client None supported
Minimum supported server Windows Server 2008 Enterprise, Windows Server 2008 Datacenter
Target Platform Windows
Header clusapi.h
Library ClusAPI.lib
DLL ClusAPI.dll

See also

Name

SetClusterQuorumResource