This sample reads performance measurements from the current time.

url            [required]: url of the web service.
username       [required]: username for the authentication
Password       [required]: password for the authentication
hostname       [required]: name of the host
interval       [required]: sampling interval in seconds.
starttime:     [optional]: In minutes, to specify what's start time from which samples needs to be collected
duration       [optional]: Duration for which samples needs to be  taken
groupname      [required]: cpu, mem
countername    [required]: usage (for cpu and mem), overhead (for mem)

Command Line:
Display performance measurements of extra CPU usage
run.bat com.vmware.performance.History --url [webserviceurl]
--username [username]  --password [password] --hostname [name of the
history server]  --groupname cpu --countername usage --interval 300

Display performance measurements from the past
should be displayed as per the counter and the group specified.
run.bat com.vmware.performance.History --url [webserviceurl]
--username [username]  --password [password]--hostname [name of the
history server]  --groupname mem --countername overhead --interval 300

VMware vSphere Web Services Java Samples

This sample was originally released as a part of vSphere 6.0 under license terms that contained a provision that disallowed redistribution in source form. In order to encourage growth of community around VMware samples, these samples are being re-released under a commercially friendly open source license (BSD 3-Clause). See the file header for details.

The samples themselves are identical to the official release version with the exception of a changed copyright and license header on each file.

If you wish to run this sample, please download the official SDK from https://my.vmware.com/group/vmware/get-download?downloadGroup=MNGMTSDK600 and follow the provided instructions.

These samples are provided for reference with no warranty expressed or implied.

Sign in to be able to add comments.

Comments 0