winapiwindows-server-2008failovercluster

Using DiskVolumeInfo (Cluster Failover API)


I found the DiskVolumeInfo property -- I'd like to use it to get some disk information in a clustered setup.

http://msdn.microsoft.com/en-us/library/windows/desktop/bb309235(v=vs.85).aspx

The problem is I have no idea what technology is required to get this data. This doesn't resemble the standard C/C++/C#/VB format of function/method reference.

Question: How do I get the DiskVolumeInfo data?

Ideally I could write the binary output directly to a file, say data.bin.

Any ideas would be helpful, thanks.


Solution

  • The process for getting object properties is described here.

    Looks like you need to call the ClusterResourceControl function with a handle to the physical disk resource and the CLUSCTL_RESOURCE_GET_PRIVATE_PROPERTIES control code. You can then use ResUtilFindBinaryProperty to extract the DiskVolumeInfo property from the property list returned.