vSphere Guest API Runtime Components

To use the vSphere Guest API, the runtime components must be installed in the guest operating system. The runtime components are dynamically loaded binary modules for 32-bit and 64-bit guests. When you install VMware Tools, the vSphere Guest API runtime components are installed as well. You can also download them from http://www.vmware.com/download/sdk/guest_sdk.html.
To make the vSphere Guest API functions available to your program, use your program’s standard methods to load the library.
  • In a Windows guest operating system, the library file is
    vmGuestLib.dll
    . The import library file is
    vmGuestLib.lib
    .
  • In a Linux guest operating system, the library file is
    libvmGuestLib.so
    .
    If you are using a Security-Enhanced Linux (SELinux) guest OS, its security policies might interfere with dynamic loading of
    libvmGuestLib.so
    . Refer to documentation about your SELinux policy configuration
The vSphere Guest SDK includes the test program
vmGuestlibTest.c
. If you are using a Windows environment, you must rebuild the test program. The
vmGuestLib.dll
library file is a non-Unicode DLL. In Microsoft Visual Studio, build the test program
vmGuestlibTest.c
as a non-Unicode executable file so that the program can access the DLL at runtime.

Enabling and Disabling the Runtime Components

The vSphere Guest API runtime components are enabled by default (
disable = “FALSE”
). To disable the runtime components, use the configuration editor in the vSphere Client to edit the configuration file for the virtual machine. The virtual machine must be powered off before you can use the configuration editor.
  1. In the vSphere Client window, right-click the virtual machine in the machine list.
  2. In the drop-down menu, select Edit Settings.
  3. In the Virtual Machine Properties window, click the Options tab.
  4. In the list of “Advanced” settings, select General.
  5. Click Configuration Parameters.
  6. In the Configuration Parameters window, add the following line or, if the file already contains the disable configuration setting, set the value to
    TRUE
    :
    isolation.tools.guestlibGetInfo.disable = "TRUE"
    The default value for the disable setting is
    FALSE
    . The default setting enables the runtime components. Reinstalling VMware Tools does not affect the disable setting. If you disable the vSphere Guest API and reinstall VMware Tools, the vSphere Guest API remains unavailable until you change the configuration setting
    guestLibGetInfo.disable
    to
    FALSE
    .