Dienstag, 27. September 2011

MS SQL cluster: determine active node via T-SQL

Problem: You want to determine the active node in a MS SQL Server active/passive cluster using T-SQL.
Solution: execute the following query:

USE master
Select ServerProperty('ComputerNamePhysicalNetBIOS')
as 'Active Cluster Node'

The result is shown in the picture below:



Keine Kommentare: