commands

^

Get-DbaWsfcNode

Author Chrissy LeMaire (@cl), netnerds.net
Availability Windows, Linux, macOS

 

Want to see the source code for this command? Check out Get-DbaWsfcNode on GitHub.
Want to see the Bill Of Health for this command? Check out Get-DbaWsfcNode.

Synopsis

Retrieves detailed node information from Windows Server Failover Clusters hosting SQL Server instances.

Description

Retrieves configuration and status details for individual nodes (servers) within Windows Server Failover Clusters that host SQL Server FCIs or Availability Groups. This function connects to cluster nodes to gather essential node properties including ownership details, version information, and operational status.

DBAs use this when troubleshooting cluster node issues, validating node configurations before SQL Server failover operations, or auditing cluster member server details. The function returns key node metadata needed for capacity planning, patch management coordination, and high availability troubleshooting.

All Windows Server Failover Clustering (Wsfc) commands require local admin on each member node.

Syntax

Get-DbaWsfcNode
    [[-ComputerName] <DbaInstanceParameter[]>]
    [[-Credential] <PSCredential>]
    [-EnableException]
    [<CommonParameters>]

 

Examples

 

Example: 1
PS C:\> Get-DbaWsfcNode -ComputerName cluster01

Gets node information from the failover cluster cluster01

Example: 2
PS C:\> Get-DbaWsfcNode -ComputerName cluster01 | Select-Object *

Shows all node values, including the ones not shown in the default view

Optional Parameters

-ComputerName

Specifies the Windows Server Failover Cluster or individual cluster node to query for node information. Accepts either the cluster name or any member node name.
Use this when you need to connect to a specific cluster hosting SQL Server FCIs or Availability Groups to retrieve node details.

Alias
Required False
Pipeline true (ByValue)
Default Value $env:COMPUTERNAME
-Credential

Allows you to login to the cluster using alternative credentials.

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.

Alias
Required False
Pipeline false
Default Value False