When configuring PowerShell checks on a SharePoint Server in GSX Monitor, you get a failure error message when testing the connection.
This articles explains how to fix the issue and why this is happening.
- Failure. PowerShell test command error: The farm is unavailable.
- Failure. Object reference not set to an instance of an object.
How to Solve the Issue
To fix the issue, edit the server configuration and change the authentication from Kerberos to CredSSP from the connectivity tab:
This issue is related to user rights, basically a double-hop authentication problem, when the SQL Server instance is not hosted on the targeted SharePoint server.
What is happening is that GSX Monitor tries to authenticate on the SharePoint objects running on the server to retrieve data from databases. By default it cannot do this, as it cannot delegate credentials using Kerberos.
The solution is then to enable CredSSP when connecting to the remote PowerShell session. The CredSSP (Credentials Security Support Provider) was created to securely send credentials to a service, and authenticate on its behalf to other services, which is exactly what we are doing here.
Microsoft Related article:
- For a detailed explanation on the roles CredSSP and Kerberos are playing in this issue, take a look at this MSDN blog post.