nkarandikar
Contributor
Contributor

srm 8.2 (appliance) and vcenter 6.7u2a (appliance) can't connect with powercli 11.2 from windows

from a windows server (2012r2) in the same env. as both vcenter and srm I have connected to vcenter with powercli (no issues there)

but when i try connect-srmserver, i get errors, i have tried various combinations of the command with srm server IP and usernames and passwords trying to follow the command reference here Online Documentation - Cmdlet Reference - VMware {code}  and 11.2 users guide https://vdc-download.vmware.com/vmwb-repository/dcr-public/72479a44-60ed-4b00-839a-0e442d85a863/6a9f... .
i have an older env. (vcenter and srm 6.5 on windows and this works without issues, so i have an idea of how the commands work, the end goal is to load up the api)

PS C:\> Connect-SrmServer

Connect-SrmServer : 6/10/2019 4:53:27 PM        Connect-SrmServer               Unable to connect to the remote server

At line:1 char:1

+ Connect-SrmServer

+ ~~~~~~~~~~~~~~~~~

    + CategoryInfo          : NotSpecified: (:) [Connect-SrmServer], VimException

    + FullyQualifiedErrorId : ConnectServer_UnhandledException,VMware.VimAutomation.Srm.Commands.Commands.ConnectSrmSe

   rver


or if i do

PS C:\> Connect-SrmServer -srmserver <IP or fqdn>
when i do this i get a prompt for creds (i enter my creds that i use for vcenter {windows domain creds})

and i get this

Connect-SrmServer : Unable to connect to the remote server

At line:1 char:1

+ Connect-SrmServer -srmserveraddress 10.193.198.142

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : NotSpecified: (:) [Connect-SrmServer], VimException

    + FullyQualifiedErrorId : VMware.VimAutomation.Sdk.Types.V1.ErrorHandling.VimException.VimException,VMware.VimAuto

   mation.Srm.Commands.Commands.ConnectSrmServer

there is no firewall between windows or the 2 appliances

Tags (2)
9 Replies
LucD
Leadership
Leadership

Are you sure you can use the same credentials as for the VCSA?
You did do the Connect-VIServer to the VCSA first?
Can you open the SRM plugin in the Web Client when connected to the VCSA?


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

0 Kudos
nkarandikar
Contributor
Contributor

pastedImage_4.png

note the above does not prompt me for creds

same creds for vcsa?
in VCSA i have configured Identity sources to point to my windows domain, my ID is full admin everywhere, no fw blocking
srm plugin is fully connected to/in both sites (SRM 8.2 and replication 8.2)
DNS is all good

new env. so i only have 1 Vm replicating,, but in the web plugin i can test failover, modify all settings etc., that all looks good

pastedImage_2.png

from what i have read/understand just connect-srm server should work, but even when i try adding in the srm appliance IP
pastedImage_3.png
note this variation asks me for creds, i have tried my windows ID, and the vcsa and srm local internal IDs (root),

and this error is slightly different from above

0 Kudos
LucD
Leadership
Leadership

Did you already try with (after the Connect-VIServer)?


Connect-SrmServer -NotDefault -IgnoreCertificateErrors

See also Example 4 on the Connect-SrmServer cmdlet.

You could also try adding the Verbose switch.


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

0 Kudos
nkarandikar
Contributor
Contributor

yup tried that

and this error is occurring at both sites vcenters/srm, 2 separate windows servers that i am running the ps command from
one in each site, get same results to each individual vcenter/srm

pastedImage_4.png

anything else to try?

installed versions of what i have

vcenter 6.7u2a appliance(both sites)

pastedImage_5.png

srm 8.2 (appliance) both sites (replication 8.2 as well both sites)

pastedImage_6.png

windows 2012r2 (fully up to date)

PS C:\> $PSVersionTable

Name                           Value

----                           -----

PSVersion                      5.1.14409.1018

PSEdition                      Desktop

PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}

BuildVersion                   10.0.14409.1018

CLRVersion                     4.0.30319.42000

WSManStackVersion              3.0

PSRemotingProtocolVersion      2.3

SerializationVersion           1.1.0.1

PS C:\> get-powercliversion

WARNING: The cmdlet "Get-PowerCLIVersion" is deprecated. Please use the 'Get-Module' cmdlet instead.

PowerCLI Version

----------------

   VMware PowerCLI 11.2.0 build 12483598

---------------

Component Versions

---------------

   VMware Cis Core PowerCLI Component PowerCLI Component 11.2 build 12483642

   VMware VimAutomation VICore Commands PowerCLI Component PowerCLI Component 11.2 build 12483638

   VMware VimAutomation Srm PowerCLI Component PowerCLI Component 11.2 build 12483605

PS C:\Windows\system32> Get-Module

ModuleType Version    Name                                ExportedCommands

---------- -------    ----                                ----------------

Manifest   3.1.0.0    Microsoft.PowerShell.Management     {Add-Computer, Add-Content, Checkpoint-Computer, Clear-Con...

Manifest   3.1.0.0    Microsoft.PowerShell.Utility        {Add-Member, Add-Type, Clear-Variable, Compare-Object...}

Script     6.7.0.1... VMware.Vim

Script     11.2.0.... VMware.VimAutomation.Cis.Core       {Connect-CisServer, Disconnect-CisServer, Get-CisService}

Script     11.2.0.... VMware.VimAutomation.Common

Script     11.2.0.... VMware.VimAutomation.Core           {Add-PassthroughDevice, Add-VirtualSwitchPhysicalNetworkAd...

Script     11.2.0.... VMware.VimAutomation.Sdk            {Get-ErrorReport, Get-InstallPath, Get-PSVersion}

Script     11.2.0.... VMware.VimAutomation.Srm            {Connect-SrmServer, Disconnect-SrmServer}

0 Kudos
LucD
Leadership
Leadership

Not at this time I'm afraid.
You might want to open a SR for this.


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

0 Kudos
nkarandikar
Contributor
Contributor

I had submitted a comment/feedback from inside the SRM plugin last week (and had not heard back) until late last night from vmware
This is the "fix" (which i have confirmed as working in both sites)

“connect-srmserver -Port 443”

The reason is there is a change in the port used with the SRM appliance.


my install is default install (not sure what port it was trying)

LucD
Leadership
Leadership

Didn't know that, thanks for sharing.


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

0 Kudos
oppergod
Enthusiast
Enthusiast

Thanks, had the same problem since we migrated to the SRM 8.2 appliance.

Is this documented somewhere (release notes)?

--- If you found this or any other answer helpful, please consider the use of the Helpful or Correct buttons to award points. R. Verdam Sr. Technical Consultant Infrastructures www.cloudfix.nl VCAP-DCD, VCAP-DCA, VCAP-DTA, VCAP-DTD, CCNP R&S, MSCE 2012
0 Kudos
jordanovi
VMware Employee
VMware Employee

Hi all

The issue with the PowerCLI Connect-SrmServer using the default port with SRM appliance is documented in the SRM 8.2 release notes - Known issues section VMware Site Recovery Manager 8.2 Release Notes

Sr. Manager R&D, VMware Site Recovery Manager