Unable to connect to WSUSServer

Nov 21, 2013 at 5:34 PM
I am hoping to get some help as I have just about run through everything that I can think of. I am unable to successfully connect to the WSUS server after installing POSHWSUS module.

I am installing POSHWSUS 2.1.1 downloaded from codeplex and have tried installing on a Server 2008R2 WSUS server and a fresh Server 2012 WSUS server and get the same behavior (so I am almost positive it is something I am doing incorrectly!).

The first difference from the documentation for install that I experience is that the result of the 'get-module -listavailable' command does indeed show that it has picked up the POSHWSUS module in the path in my documents (c:\users\username\documents\WindowsPowerShell\modules\POSHWsus)
but in the powershell window (which is being run as administrator) shows that POSHWSUS is ModuleType Script instead of Manifest as it shows in all the documentation and discussions I could find. Upon issuing the command import-module POSHWSUS it succeeds and gets:
            PoshWSUS 2.1.1

Make initial connection to WSUS Server: Connect-PoshWSUSServer
Disconnect from WSUS Server: Disconnect-PoshWSUSServer
List all available commands: Get-PoshWSUSCommand

But when I use the command Connect-PoshWSUSServer -WSUSServer server1.domain.local I receive
Warning: Unable to connect to server1.domain.local
no matter if I try the IP or the NetBIOS name or anything else I cant get past this error. I also tried connecting and adding -debug -verbose but no additional information is provided besides that warning message.

I have tried different combinations across different servers (all with WSUS installed) but receive the same warning message and the module always shows up as the type script.
Is the manifest vs. script the root of this problem?

Thanks,

Brian
Nov 25, 2013 at 8:22 AM
You can try to specify port parameter.
Connect-PoshWSUSServer -WsusServer "Your_WSUS_FQDN_or_NETBIOS_name" -port "8530"
Nov 28, 2013 at 10:18 AM
Is it also possible to connect with other credentials?
That functionality would be appriciated very much.

(I was not able to create a new Thread for unknown reason)

Thanks,

Andre
Nov 29, 2013 at 8:40 AM
to Brian...

Are you are importing the module using the .psm1 file instead of the maniest file (.psd1).
That maybee causing your problem.

grtz,
Andre
Dec 2, 2013 at 8:45 PM
@lingevad Yes I tried importing both ways without any difference in the results

However...I was able to connect using the port command with the 8530 value

This hurdle is now over...on to the next !

Thanks for the help
Sep 16, 2014 at 6:19 AM
Edited Sep 16, 2014 at 6:19 AM
I had to do the following
  1. run PS locally on the WSUS server so I didn't have to make sure remote PS is allowed.
  2. Make sure PS execution policies are unrestricted
  3. Run PS as admin
  4. Run the following command to Load .NET assembly. Just copy and paste it in PS.
[void][reflection.assembly]::LoadWithPartialName("Microsoft.UpdateServices.Administration")
Step 4 is what fixed my issue.
Sep 16, 2014 at 6:19 AM
I had to do the following
  1. run PS locally on the WSUS server so I didn't have to make sure remote PS is allowed.
  2. Make sure PS execution policies are unrestricted
  3. Run PS as admin
  4. Run the following command to Load .NET assembly. Just copy and paste it in PS.
[void][reflection.assembly]::LoadWithPartialName("Microsoft.UpdateServices.Administration")
Step 4 is what fixed my issue.