A common question on the forums here is regarding development for VMware ESXi. In most cases users are looking to develop or update a device driver. In other cases a user is looking to integrate a common Linux utility. This page serves to introduce the reader to some of the development resources for ESXi. If you’re aware of any additional resources, please leave a comment.
If you’re looking to develop commercial drivers or products, the place to start is VMware’s Advanced Developer Portal. The portal includes information on VMware’s programs for driver development, application development, server certification, and other development avenues.
If you’re getting started down this road, the most critical item to understand is that ESXi is not based on Linux. The VMkernel of ESXi is a closed source product and not a derivative of Linux. That said, ESXi makes use of many Open Source utilities and includes a Linux driver compatability mode.
Compiling Utilities for ESXi
Given that ESXi is not based on Linux you won’t find any installer which you could use to install any Linux components that you might want to add to ESXi. However, ESXi does make use of a number of Open Source packages such as OpenSSL, Python, and Openwsman (WS-Management). The key to compiling a utility for ESXi is creating a statically linked version of the tool. With a statically linked version, there are no dependencies on other libraries that may not be present on ESXi. The downside to this method of compiling is that the utility may be larger than a dynamically linked version. With a dynamically linked version the utility assumes that other libraries are present and can rely on subroutines within those libraries.
Compling rsync – http://www.virtuallyghetto.com/2011/02/how-to-compile-statically-linked-rsync.html
Compiling Busybox – http://www.virtuallyghetto.com/2011/02/how-to-compile-busybox-for-esxi-kind-of.html
Discussion of compiling UNFS – http://www.vm-help.com/forum/viewtopic.php?f=16&t=2280&p=10185&e=10185
Notes on compling binaries – http://www.zemris.fer.hr/~sgros/sysadm/esxi_hacks.shtml
Compiling Drivers for ESXi
Given the common misunderstanding that ESXi is Linux based, a new user often inquires about the process of copying a Linux driver to their ESXi install. This is not possible. ESXi includes a Linux driver compatability module. This allows for Linux source code to be used to compile drivers for ESXi, but the drivers are still specific to ESXi. The following links provides some samples and notes for compiling drivers for ESXi.
Compiling a Silicon Image 3132 driver – http://www.bytedynamix.com/?p=77
Compiling a Marvell sky2 driver – http://www.kernelcrash.com/blog/using-a-marvell-lan-card-with-esxi-4/2009/08/22/
Open Virtualization Drivers development notes