MaxB
Enthusiast
Enthusiast

Get-CisService Appliance Health

Jump to solution

Hey Guys,

I try to request some information from the vCenter VAMI, like health status.

But the Get-CisService command seems not to work as I want.

First I connect successfully to the CisServer with Connect-CisServer with Administrator@vsphere.local.

After that I want to use Get-CisService to retrieve the general system health.

(Get-CisService -Name 'com.vmware.appliance.health.system' -Server $global:DefaultCisServers).get()

But it throws an authorization error.

I use PowerCLi 10.1.0

I´m really sure it worked in a previous release.

The exception is attached as screenshot.

Hope you have any suggestions or may a better way to get the informations.

CisService.PNG

Thanks.

Max

0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership

You might want to have a look atRe: vcsa 6.5 trying to automate the backup - authentication failure

They also had an authentication issue.
And it seems to be a bug in 6.5U1f and 6.5U1g.
I'm on 6.7, so that's perhaps why it works for me (without editing that file).


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

View solution in original post

0 Kudos
5 Replies
LucD
Leadership
Leadership

Seems to be working for me in 10.1.0 (without and with the Server parameter).

cis.jpg

What is in $error[0].Exception.ServerError as the message suggests?
Do other CIS services show the same issue? Or only this service?


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

0 Kudos
LucD
Leadership
Leadership

One more suggestion, do you see the same error when you make the call via the API Explorer?

rest.jpg


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

0 Kudos
MaxB
Enthusiast
Enthusiast

Hi Luc,

you´re damn fast.

I attached the Output of $error[0] and the Response from the Api Explorer.

But it seems to be a smiliar problem.

It´s not only one vCenter... I tried about 5 vCenters and all Show me same behaviour.

Error0_Output.PNGApiexplorer_response.PNG

As you can see in the screenshot I´m logged in with the adminsitrator@vsphere.local

May It´s an vCenter Issue? All my vCenters are on 6.5U1g

0 Kudos
LucD
Leadership
Leadership

You might want to have a look atRe: vcsa 6.5 trying to automate the backup - authentication failure

They also had an authentication issue.
And it seems to be a bug in 6.5U1f and 6.5U1g.
I'm on 6.7, so that's perhaps why it works for me (without editing that file).


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

View solution in original post

0 Kudos
MaxB
Enthusiast
Enthusiast

Sure will try it today and let you know!

0 Kudos