-
Notifications
You must be signed in to change notification settings - Fork 89
The variable '$defaultNSXConnection' cannot be retrieved because it has not been set #616
Comments
What command do you are using ? |
I've tried by IP address as well. Docs said -vCenterServer was prefered. I also have the powercli module installed, and the connect-NsxServer cmdlet will also try to use an existing vSphere connection and automatically attempts to hit the correct NSX manager IP without ever referencing it |
Strange |
|
Now I'm getting this error after closing my powershell ISE and reopening and trying again. Strange, because I connect to Vsphere just fine and get run Get-VM.
None of this makes sense because i can do postman API calls with my same credentials to this nsx manager and return things. |
What NSX Release ? you try to connect directly to NSX Manager ? |
I've tried Connect-NsxServer -NsxServer 10.X.X.X -Credential $cred Still won't work. |
I am now able, without PowerNSX at all, to connect to my NSX manager via pure powershell invoke-restmethod
This returns a security tag just as it did when using Postman. Still have no idea why powerNSX doesn't work. Was really hoping to abstract some of this. |
i ask the NSX Manager release |
and for your issue about SSL/TLS it is coming from need to disable certificate check (it is set automatically when launch connect-nsx...) |
NSX Manager Version: | 6.4.5 Build 13282012 I can get around the TLS issue easy enough. Just wish I could actually use powernsx >.< |
You are using the vCenter name when connect ? (and the [email protected]) account ? (not the NSX Manager) |
So that worked with those credentials...how am I able to make any API call I want outside of powernsx with my admin credentials, but using powernsx requires this specific account? |
you can the use admin account of NSX Manager ? or a another account on vSphere ? |
I have been making API calls to NSX directly with my personal admin account. I was finally able to do it with the power nsx module using the [email protected] |
When attempting to connect to the NSX manager, I get this error.
The variable '$defaultNSXConnection' cannot be retrieved because it has not been set.
At C:\Program Files\WindowsPowerShell\Modules\PowerNSX\3.0.1174\PowerNSX.psm1:25305 char:41
The text was updated successfully, but these errors were encountered: