PowerShell Cmdlets and New Prism Central pc.2023.1.0.1 | Nutanix Community
Skip to main content

I find that I am stuck between a rock and a hard place all of a sudden.

 

I have been using the original Nutanix PowerShell cmdlets (Add-PSSnapin NutanixCmdletsPSSnapin) for weekly inventory scripts.  I also have a script for deploying new VMs from images that use these cmdlets.

 

Our production Prism Central is pc.2022.6.0.3 and I can still login to that just fine (Connect-NTNXCluster).  However, we are having numerous issues with that build and support has advised they have been resolved in the newest build pc.2023.1.0.1.

 

We have a test Prism Central instance with one test AHV cluster.  Yesterday we updated that to pc.2023.1.0.1 and now I cannot connect with the cmdlets.

 

Scripts> Connect-NTNXCluster -Server $PCentral -Username $MyCreds.Username -Password $MyCreds.Password -AcceptInvalidSSLCerts -ForcedConnection
Connect-NTNXCluster : Invalid JSON primitive: Authentication.
At line:1 char:1
+ Connect-NTNXCluster -Server $PCentral -Username $MyCreds.Username -Pa ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) dConnect-NTNXCluster], ArgumentException
+ FullyQualifiedErrorId : System.ArgumentException,Nutanix.Prism.Common.NutanixCluster

 

I also installed the new cmdlets (version 2.0.1) and tried to use those.  That version uses the Connect-PrismCentral command.  I can connect to the new Prism Central build but I can’t connect to the pc.2022.6.0.3 build (throws an exception).  Plus these do not seem to be complete yet but I haven’t dug into them very much yet.

 

PS C:\> connect-prismcentral -server "prismcentral" -Credential $MyCreds -AcceptInvalidSSLCerts -ForcedConnection -SessionTimeoutSeconds 600
Connect-PrismCentral: Exception of type 'Nutanix.Prism.Common.CmdletErrorException' was thrown.

 

Anyone else running into these issues?

 

Besides converting everything to REST APIs, are there any workarounds?