Hi,
I'm a bit at loss. Here is what I want to do. Getting some information about the vms in my VC plus the hostname of the esx-server the vm resides on. Sounds pretty easy but I don't seem to get that working.
May be someone could point me in the right direction.
thanx
Harro
If you download the beta-2 version of the toolkit, you will find vminfo.pl in the apps/vm directory.
The utility vminfo.pl can be used for that.
vminfo.pl --fields name,hostName
gives you everything you want. You may want to refine the output for your needs but it gives you the basic things in a pretty compact script.
You didn't mention the language. But here's the basic operation.
The virtual machine object
VirtualMachine.runtime.host => moRef of the host object
get the host object
host.name = name of host.
Hi,
sorry the language is perl.
Harro
If you download the beta-2 version of the toolkit, you will find vminfo.pl in the apps/vm directory.
The utility vminfo.pl can be used for that.
vminfo.pl --fields name,hostName
gives you everything you want. You may want to refine the output for your needs but it gives you the basic things in a pretty compact script.
thanx, that did the job!
Harro,