Have you ever felt a need to fetch some information from the guestOS that is not exposed by VI APIs? If you have a requirement to pass some information from guestOS and use VI APIs to get access to that information, VMware tools guest service can be of help.

When you install VMware Tools in a virtual machine, the VMware guest operating system service is one of the primary components installed. In a Linux guest, the guest service is called "vmware-guestd" and in a Windows guest, the guest service program file is called VMwareService.exe. One can use this service to set a guest info variable.

The command to set the guest variables is:

In windows guest:
VMwareService --cmd "info-set guestinfo.<variableName> <value>"

In Linux guest:
vmware-guestd --cmd "info-set guestinfo.<variableName> <value>"

This value can then be retrieved using VI APIs through the config.extraConfig["guestinfo.<variableName>"] property for the virtual machine object.

As mentioned above, the primary pre-requisite of above method is to have VMware Tools installed.

1 comments:

  1. ksfga said...

    I have tried this howto on esxi 4.0 but with now success.. Have you tried it also? Does it work?
    And what about stealing cookies? How can be this made?

    Thank you!



Copyright 2009 InterraIT template by Blogcrowds.