Search in sources :

Example 1 with VmwareHypervisorHostResourceSummary

use of com.cloud.hypervisor.vmware.mo.VmwareHypervisorHostResourceSummary in project cloudstack by apache.

the class VmwareResource method fillHostHardwareInfo.

private void fillHostHardwareInfo(VmwareContext serviceContext, StartupRoutingCommand cmd) throws RuntimeFaultFaultMsg, RemoteException, Exception {
    VmwareHypervisorHost hyperHost = getHyperHost(getServiceContext());
    VmwareHypervisorHostResourceSummary summary = hyperHost.getHyperHostResourceSummary();
    if (s_logger.isInfoEnabled()) {
        s_logger.info("Startup report on host hardware info. " + _gson.toJson(summary));
    }
    cmd.setCaps("hvm");
    cmd.setDom0MinMemory(0);
    cmd.setSpeed(summary.getCpuSpeed());
    cmd.setCpuSockets(summary.getCpuSockets());
    cmd.setCpus((int) summary.getCpuCount());
    cmd.setMemory(summary.getMemoryBytes());
}
Also used : VmwareHypervisorHost(com.cloud.hypervisor.vmware.mo.VmwareHypervisorHost) VmwareHypervisorHostResourceSummary(com.cloud.hypervisor.vmware.mo.VmwareHypervisorHostResourceSummary)

Aggregations

VmwareHypervisorHost (com.cloud.hypervisor.vmware.mo.VmwareHypervisorHost)1 VmwareHypervisorHostResourceSummary (com.cloud.hypervisor.vmware.mo.VmwareHypervisorHostResourceSummary)1