Tag Archives: Guest

vSphere APIs for Guest Operating System Management: What’s Special and When to Use It?

This is a wrap-up post of recent series on vSphere guest operating system management APIs. If you missed them, here are a few links to related posts: [Note: these are not related to the vSphere Guest API.]

Posted in Software Development, vSphere API | Also tagged , , | 13 Responses

How to Upload File to Guest Operating System on VMware

My last post explained how to download file from a guest operating system. Naturally this post is about how to upload file. After a quick sample code, I will discuss how to extend the capability of existing APIs that run program inside guest operating system. My next post will wrap up this series of guest related APIs in vSphere API.

Let’s take a look at a sample code: (To run it, first check out the simple prerequisites in a previous post)

Posted in Software Development, vSphere API | Also tagged , , | 31 Responses

How to Download File from Guest Operating System on VMware

In my last few posts I discussed how to use the Guest Operating System Management API to run program, set/read environment variables. From this post, I will talk about how to move files to and from a Guest Operating System, and advanced features like moving whole directory only implemented in the Guest Operating System Management API.

Posted in Software Development, vSphere API | Also tagged , , | 23 Responses

Set Environment Variables in Guest Operating System on VMware

While reading my last post on reading environment variables from a guest operating system, you may wonder how to set environment variables. Don’t be disappointed if I tell you that there is NO direct support for setting an environment variable.

However, you have a workaround – use a command directly. Unlike reading variables, there is no standard ways to do it for different operating systems. You have to first figure out what type of operating system and then run different commands. For example, if you are targeting Windows family of operating systems, you simply run the following:

Posted in Software Development, vSphere API | Also tagged , , , | Leave a comment

Read Environment Variables in Guest Operating System on VMware

My last post explained how to run, kill, and list programs in guest operating system on VMware. In that post, I mentioned that you can actually use the same API, GuestProgramDirector in particular, to read environment variables. I think the explanation is detailed enough for an implementation.

Still, a good sample provides more details. That is why I decided to write a quick sample just to show how to read environment variables. While trying the sample by myself, I did find more that I will discuss after the sample code.

Posted in Software Development, vSphere API | Also tagged , , , | 14 Responses

Run, Kill, and List Programs in Guest Operating System on VMware

In my last article, I announced the Guest Operating System Management API for vSphere. As promised, I will write samples to show how to use the APIs. This post explains the GuestProgramDirector type with an example.

Let’s take a quick look at the following sample:

Posted in Software Development, vSphere API | Also tagged , , | 28 Responses

Announcing Guest Operating System Management API for vSphere

Having created a sample to run a program in guest operating system using GuestProgramManager, I started to write a similar one to show how to use the GuestFileManager. Compared with the GuestProgramManager, the GuestFileManager is much more complicated to use.

Posted in Software Development, vSphere API | Also tagged , , | 15 Responses

Introducing vSphere Guest API

If you want to read information about a virtual machine from the guest OS running on it, the vSphere Guest API is for you. It’s a C library coming with VMware Tools. Unlike the vSphere API which can be used anywhere, the vSphere Guest API is only available in the guest OS.

High Level Characteristics

  • It’s read only. You can use it to retrieve state and performance of a virtual machine running on ESX, but you can NOT
Posted in vSphere API | Also tagged , , | 2 Responses
  • NEED HELP?


    My company has created products like vSearch ("Super vCenter"), vijavaNG APIs, EAM APIs, ICE tool. We also help clients with virtualization and cloud computing on customized development, training. Should you, or someone you know, need these products and services, please feel free to contact me: steve __AT__ doublecloud.org.

    Me: Steve Jin, VMware vExpert who authored the VMware VI and vSphere SDK by Prentice Hall, and created the de factor open source vSphere Java API while working at VMware engineering. Companies like Cisco, EMC, NetApp, HP, Dell, VMware, are among the users of the API and other tools I developed for their products, internal IT orchestration, and test automation.