We are using Windows Failover Clusters and would like a sensor to alert when a node is not 'Up' (eg: Paused or Down).
We've previously had a Custom EXEXML sensor working for this, using a custom lookup (state 1 is OK), but it no longer works...
param ( [string]$server ) $s = New-PSSession $server Invoke-Command -Session $s -Scriptblock { $nodes = Get-ClusterNode Write-Output '<prtg>' foreach ($node in $nodes){ Write-Output '<result>' Write-Output '<channel>' + $node.Name + '</channel>' Write-Output '<value>' + (&{If($node.State -ceq 'Up') {1} else {0}}) + '</value>' Write-Output '</result>' } Write-Output '</prtg>' } Remove-PSSession $s
Any suggestions?
Add comment