Hello,
I need help with a problem.
I'm using SOAP with PHP to connect to a vSphere Webservice. So far I'm able to login and get references for Managed Objects but I can't retrieve CPU, Memory and disk usage data from the VM. I'm using the QueryPerfProviderSummary method (PerformanceManager class) but I'm having a hard time with the entity parameter. Can anyone give me any insight or suggestions to resolve this?
Regards
Marta
$client = new soapclient( "https://my_vshere/sdk/vimService.wsdl", array( "trace" => 1, "location" => "https://my_vshere/sdk/" ) );
$soapmsg["_this"] = new SoapVar( "ServiceInstance", XSD_STRING, "ServiceInstance" );
$result = $client->RetrieveServiceContent( $soapmsg );
// Login
$soapmsg = null;
$soapmsg["_this"] = $result->returnval->sessionManager;
$soapmsg["userName"] = "user";
$soapmsg["password"] = "password";
$client->Login( $soapmsg );
// Performance
$soapmsg = null;
$soapmsg["_this"] = $result->returnval->perfManager;
$soapmsg["entity"] = ???????????
$resultPerf = $client->QueryPerfProviderSummary( $soapmsg );