Monthly Archives: September 2010

Two Important Tips Reading vSphere API Reference

Last week I answered a question in VMware Web Services SDK forum about asterisks in vSphere API reference. Underneath these asterisks comes a note saying “May not be present.” What does it really mean?

The asterisks normally show up after properties or sub-properties defined with a managed object. As it says, it’s possible that there is NO value to the property.

How can it be like this?

There are two major causes. First, it reflects the different implementations of ESX, ESXi and vCenter. As a quick example, you can find many of the properties in the “content” (type: ServiceContent) come with asterisks.

On a vCenter server, you will find values to almost all the properties, but not quite so for ESX/ESXi. But we have one API reference document, so it’s natural to mark whatever possible no value as “may not present.”

Secondly, it may be as such depending on the state of a managed object. For instance, a virtual machine can be a bare machine without an OS installed. Therefore, the “guest” property of the virtual machine could have no value at all.

What does it mean to you?

Posted in vSphere API | Tagged , , , , | 4 Responses

How You Can Beat Amazon EC2 by Differentiating Your Cloud Service

With the gradual adoption of cloud computing, more companies are coming to the cloud service business. With so many new players in the game, how can you stand out in the competition as a service provider? In a marketplace already dominated by companies like Amazon, do you even have a chance?

Yes, you do! Differentiate.

I recently read a book, “Differentiate or Die: Survival in Our Era of Killer Competition” by Jack Trout and Steve Rivkin. Although it mainly talks about differentiation ideas in traditional businesses, it does offer good insights that can be applied in the cloud service business as well.

Conventional wisdom

Before we get to cloud services, let us take a look at what Jack and Steve say about differentiation. They first discuss some commonly held misconceptions about differentiating ideas:

Posted in Cloud Computing | Tagged , , , , , | Leave a comment

DoubleCloud Named Top 50 Blogs on Cloud Computing

I am glad to learn that I have been recently named as top 50 bloggers on cloud computing by Cloud Computing Journal. Check out here for all my cloud related articles.

Thanks all for making this happen! The momentum will continue…

Posted in Cloud Computing, News & Events | Tagged , | 4 Responses

“Last Inch” of Cloud Computing

The “last mile” or “last kilometer” is a term in the networking industry describing “the close to end connectivity from a communication service provider to a customer”. Although your infrastructure like backbones is very powerful, your end user experience could suffer if your last mile is not there yet.

For cloud computing, we’ve talked a lot about the data centers, backend servers. What about the end users? Your cloud data center could be very powerful too, but does it mean your users will fully leverage that power? Not necessarily. It depends on how you deliver the service to them.

Because cloud service is delivered with traditional network, the traditional network “last mile” issue is there as well. You surely need a good, if not better, connection to the network.

Beyond the connectivity, you will need good interfaces for your users to interact with the cloud. Let me go over the “last inch” options here.

Posted in Cloud Computing | Tagged , , , | 2 Responses

Google made Instantiations free

Following my prediction in a previous blog, Google just made the tools from its recently acquired Instantiations free to all developers/testers. Besides goodwills to the developer community, this move makes GWT a serious competitor to Adobe Flex, Microsoft Silverlight for Rich Internet Applications.

You can give these tools a try while developing and testing Web applications, or Java GUI applications:

  • GWT Designer
    “a powerful set of Eclipse-based development tools that enables Java developers to quickly create Ajax web applications using the Google Web Toolkit (GWT).”
Posted in News & Events, Software Development | Tagged , , , | 1 Response

Object Model of VMware vCloud API: The Big Picture in 2 Minutes

VMware released the long-awaited vCloud API at VMworld 2010. The API is based on REST with 75 URLs defined in the user related part as you would find in the vCloud API Specification and vCloud API Programming Guide.

I am an OO guy (I am sure many of you are as well), and find it difficult to go through the 75 URLs and numerous XML tags as either input or return. These URLs are like trees in a forest. But where is the forest?

So I decided to create and show you a UML diagram (shown below) so that you can easily capture the key concepts of the vCloud API. In fact, there was a similar diagram in the programming guide of version 0.8.

Posted in Cloud Computing | Tagged , , | 1 Response

Why No DatacenterRemovedEvent? A Deep Dive into vSphere Event Model

Last week I discussed how to get event type with vSphere API, followed by a comment asking why there is no DatacenterRemovedEvent? Very good question and almost got me there.

vSphere API has a comprehensive object model for event. In version 4.1, we have 474 different types of events representing different things happened in vSphere. When a managed entity is removed, there are normally events associated, for example, VmDeployedEvent, HostRemovedEvent, ClusterDestroyedEvent, ResourcePoolDestroyedEvent, DatastoreDestroyedEvent, DatastoreRemovedOnHostEvent, etc. It’s natural to expect DatacenterRemovedEvent. But you don’t find one.

It’s not only Datacenter which does have DatacenterCreatedEvent and DatacenterRenamedEvent. For Folder type, you find nothing other than VmBeingClonedNoFolderEvent which is not related to lifecycle of Folder at all.

Why are these events missing?

Posted in vSphere API | Tagged , | 13 Responses

How to Avoid Virtual Machine Sprawl in Cloud Age?

Technology can be a lot like fashion, with quickly shifting trends. Once we embraced big iron but after the mainframe age the industry went into the client/server age where we soon found too many servers to manage. So we consolidated them, not back to mainframe age, but onto hypervisors. With one physical server, you can run multiple virtual machines.

Server consolidation solved a big problem and resulted in big cost savings. From management’s point of view, however, it does not actually reduce the number of servers to manage in your enterprise. To some extent, it worsens the problem!  In some circumstances it’s so easy and inexpensive to create a new virtual machine that you end up with many more servers than you really want or can effectively manage. This problem not only exists in private clouds, but also in the public cloud.

According to VMware CEO Paul Maritz in his keynote at VMworld 2010, the number of virtual machines exceeded physical machines in 2009, and will reach 10 million by the end of this year. This is definitely great news for the virtualization software industry but also a challenge moving forward.

So how should you try to solve the problem of virtual machine sprawl or even better, prevent it from happening? I discuss some solutions one by one here.

Posted in Cloud Computing | Tagged , , , | 5 Responses

Creating Your Own Task and Event in vSphere

vSphere has a powerful extension mechanism that allows you to add new features as integral part of the platform. Many vendors have already leveraged this by providing plug-ins so that users can manage their components seamlessly within same vSphere Client.

You can actually do more than that with the extension. The following sample shows how to create your own task and event with vSphere API. The code should be self explanatory therefore I don’t elaborate much here. Note that you must run the sample with a vCenter server as extensibility is implemented only in vCenter.

When running the code, you can see a new task created and progresses with 10% every second in the “Recent Tasks” pane of vSphere Client. When the task is done, you will also see a new event posted in the “Tasks & Events” tab of the host you associate the task with.

What can you do with this capability? Here are two typical use cases:

Posted in vSphere API | Tagged , , , , | 33 Responses

Really Easy Ways to Capture VM Screenshot

Since vSphere 2.5, there is a feature allowing you to capture screen shot of a running virtual machine. It’s not well publicized but you can find a short description with screenshotSupported (boolean) in the HostCapability data object. Thanks to Nikita for bringing this up in the comment of the vSphere Java API 2.1 GA post.

Indicates whether the screenshot retrival over https is supported for this host’s virtual machines. If true, a screenshot can be retrieved at the HTTPS relative path /screen?id=<managed object ID of virtual machine or snapshot>. If any of the optional parameters ‘top’, ‘left’, ‘bottom’, and ‘right’ is specified, the returned image will be cropped from the rectangle with upper left corner (left, top) and bottom right corner (right – 1, bottom – 1). These values default to the top, left, bottom and right edges of the image. The client must use an authenticated session with privilege VirtualMachine.Interact.ConsoleInteract on the requested virtual machine or, in the case of a snapshot, the virtual machine associated with that snapshot.

The managed object ID of virtual machine is the value of ManagedObjectReference, which can be easily found using MOB.

Once you have it, you can issue a URL as follows in any browser and get the screen shot in PNG format.

Posted in vSphere API | Tagged , , | 12 Responses

vSphere Java API at VMworld 2010

Last week was a super busy week for all the people involved in VMworld 2010 in San Francisco. Because I spent two hours driving to Moscone Center and back home, I didn’t write any blog after getting back totally exhausted. Now it’s time to get back to it.

I believe there are many blogs/news on VMworld in general. Let me get down to a much narrow part: VMware Sponsored open source vSphere Java API at VMworld 2010.

Thanks to the community, my presentation on vSphere API Best Practice went very well. It’s based on the top 10 best practices blog (part 1, part 2) I wrote early this year, with real world experiences shared with partner engagements. Two copies of my book were given away at the end of the presentation. Thanks to Pablo Roesch for getting the books!

After the presentation, I was invited to check out new products built on top of vSphere Java API. I cannot disclose all of them here because some are not yet on the poweredby page. Here are several companies I can publicly talk about:

Posted in News & Events, vSphere API | Tagged , | Leave a comment
  • 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.