At time while troubleshooting SUP (software update point)in SCCM we get error in WCM.log that we are unable to connect to WSUS server. Most of the time turning out to be proxy or a network issue,
This script will help you connect to the WSUS and let us know if the connection is successful or else will help us with the exception information. hence we could isolate the issue out of SCCM to understand if it is environment or a configuration issue in SCCM
Many a times I have found this handy
#Change server name and port number and $True if it is on SSL
"CMCAS"[Boolean]$useSecureConnection = $False
8530# Load .NET assembly
# Connect to WSUS Server
$updateServer = [Microsoft.UpdateServices.Administration.AdminProxy]::getUpdateServer($updateServer1,$useSecureConnection,$portNumber)
write-host "<<<Connected sucessfully >>>" -foregroundcolor "yellow"
write-host "Error Occurred"
write-host "Exception Message: "
On success you would get this
Or error exception
This posting /Script is provided "AS IS" with no warranties and confers no rights