Get-DbaWsfcDisk
View SourceSynopsis
Retrieves detailed information about clustered physical disks from Windows Server Failover Clusters.
Description
Retrieves comprehensive disk information from Windows Server Failover Clusters including disk space usage, file systems, mount points, and cluster resource states. This function is essential for DBAs managing SQL Server Failover Cluster Instances who need to monitor storage health and capacity across cluster nodes. Returns detailed disk properties like total size, free space, volume labels, and serial numbers for each clustered disk resource, helping identify storage bottlenecks and plan capacity upgrades.
All Windows Server Failover Clustering (Wsfc) commands require local admin on each member node.
Syntax
Get-DbaWsfcDisk
[[-ComputerName] <DbaInstanceParameter[]>]
[[-Credential] <PSCredential>]
[-EnableException]
[<CommonParameters>]
Examples
Example: 1
PS C:\> Get-DbaWsfcDisk -ComputerName cluster01
Gets disk information from the failover cluster cluster01
Optional Parameters
-ComputerName
Specifies the Windows Server Failover Cluster to query for disk information. Accepts either a cluster node name or the cluster name itself.
Use this when managing SQL Server Failover Cluster Instances to monitor storage across different cluster environments.
| Property | Value |
|---|---|
| Alias | |
| Required | False |
| Pipeline | true (ByValue) |
| Default Value | $env:COMPUTERNAME |
-Credential
Allows you to login to the cluster using alternative credentials.
| Property | Value |
|---|---|
| Alias | |
| Required | False |
| Pipeline | false |
| Default Value |
-EnableException
By default, when something goes wrong we try to catch it, interpret it and give you a friendly warning message.
This avoids overwhelming you with “sea of red” exceptions, but is inconvenient because it basically disables advanced scripting.
Using this switch turns this “nice by default” feature off and enables you to catch exceptions with your own try/catch.
| Property | Value |
|---|---|
| Alias | |
| Required | False |
| Pipeline | false |
| Default Value | False |
Outputs
PSCustomObject
Returns one object per clustered disk partition found on the failover cluster.
Default display properties (via Select-DefaultView):
- ClusterName: The name of the Windows Server Failover Cluster
- ClusterFqdn: The fully qualified domain name of the cluster
- ResourceGroup: The owner group of the disk resource
- Disk: The disk resource name
- State: The current state of the disk resource
- FileSystem: The file system type (NTFS, ReFS, etc.)
- Path: The mount path of the disk partition
- Label: The volume label assigned to the disk
- Size: Total size of the disk partition; dbasize object convertible to Bytes, KB, MB, GB, TB
- Free: Free space available on the disk partition; dbasize object with unit conversion
- SerialNumber: The serial number of the physical disk
*Additional properties available (using Select-Object ):
- MountPoints: Array of mount points for the disk partition
- ClusterDisk: The CIM MSCluster_Disk object representing the physical disk
- ClusterDiskPart: The CIM MSCluster_DiskPartition object with full partition metadata
- ClusterResource: The CIM MSCluster_Resource object representing the cluster resource
dbatools