The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,860 other subscribers

Archive for the ‘ESXi6.5’ Category

When some virtual machines cannot run VMware Tools: Graceful shutdown of an ESXi 5.1 host and guest VMs (free edition) using the shell/command line/scripting (UPS friendly)

Posted by jpluimers on 2022/04/12

An interesting set of scripts from [Wayback/Archive.is] No Joke IT: Graceful shutdown of an ESXi 5.1 host and guest VMs (free edition) using the shell/command line/scripting (UPS friendly).

If all ESXi virtual machines support running of VMware Tools, then the solution is a plain /sbin/shutdown.sh && /sbin/poweroff (see [Wayback/Archive.is] No Joke IT: Shut down ESXi 5.1 guest VMs and the host (free edition) via SSH – the easy way!).

Code is in the repository at [Wayback/Archive.is] sixdimensionalarray/esxidown: A shell script to shutdown VMware ESXi host servers, with these two main files:

Note: the No Joke IT web-site has vanished, so only the [Wayback] and [Archive.is] links of it still work. The github code was still there at the time of writing.

Via: [Wayback] Solved: Read only Files – VMware Technology Network VMTN

Related: Some notes on replacing parts of a text file with template text using sed on a Busybox system.

–jeroen

Posted in *nix, *nix-tools, ash/dash, ash/dash development, Development, ESXi5, ESXi5.1, ESXi5.5, ESXi6, ESXi6.5, ESXi6.7, Power User, Scripting, Software Development, Virtualization, VMware, VMware ESXi | Leave a Comment »

windows xp – How to know which license version has an XP installed system – Super User

Posted by jpluimers on 2022/03/29

When virtualising your final physical Windows XP machines (just in case you need to hook up old hardware that is unsupported from newer Windows versions), you need to figure out the kind of license of each physical Windows XP machine in order to stand a chance to keep it licensed.

This answer by [Wayback] Moab [Wayback] windows xp – How to know which license version has an XP installed system – Super User helped me a lot.

I tried to make it a bit easier to read:

  1. First obtain the “Product ID” from the Windows XP machine. It is derived from the original Windows XP installation product key and displays a few values:

    xxxxx-yyy-zzzzzzz-zzzzz

    • xxxxx: the MCP (Microsoft Product Code) describing which product version, or in case of Windows XP: what language, edition (like “Home” and “Pro”) and often some more information)
    • yyy: the Channel ID (especially important to set apart OEM from other channels; OEM is not allowed to be virtualised, so would need a complete new Windows XP key to be activated as Virtual Machine; Channel IDs being neither OEM nor VLK (volume license key) can often be re-activated, sometimes over the phone to explain the situation; I’ve not tried virtualising a VLK based Windows XP yet.
    • zzzzzzz-zzzzz: semi-random values

    [Wayback/Archive.is] Product IDs – Lunarsoft Wiki has quite detailed lists of not just the MCP and Channel ID values for Windows XP and Windows Server 2003, but also the disk volume labels and setup.ini label values.

    Often this is easier to do from the physical machine before virtualising it, but even afterwards you can get it by running Windows in Safe Mode, then use either of these to get the Product ID:

    1. Run the Windows Contol Panel applet sysdm.cpl which shows the “Product ID” us under the “Registerd to” information.
    2. From the console, run reg query "hklm\software\microsoft\windows nt\currentversion" /v ProductID
    3. From another machine or boot CD (like Hiren’s Boot CD or Windows Ultimate Boot CD), mount the hard disk, mount the registry hive, then show the above registry key value
    4. Download and run NirSoft [Wayback] ProduKey (which usually will give you both the Product ID and Product Key)
  2. From the product key, determine if you can re-activate Windows, either by phone, or by this link:

    [Archive.is] Self Service for Mobile

    I got the link from [Wayback] activate windows xp – Microsoft Community via [Wayback] windows xp – How do I activate WindowsXP now that support has ended? – Super User.

    Phone (in most countries) and on-line activation should still work; it worked in 2016 (see [Wayback] license – Will I still be able to activate Windows XP after support ends? – Super User) 2019 (see [Wayback] windows xp – How do I activate WindowsXP now that support has ended? – Super User) and 2020 (see [Wayback] XP activation – Windows XP Home and Professional).

  3. When OEM, try to obtain a legal Windows XP license key that matches the MCP, then change the key using steps in for instance:

    Note that it is no use searching Google for Windows XP License keys: Microsoft did and invalidated them back in the Windows XP SP1, SP2 and SP3 days: Wayback: Error message when you install Windows XP Service Pack 1 (SP1) or Service Pack 2 (SP2): “The product key used to install Windows is invalid

     

The 2001 Windows XP Professional License is archived in the Wayback machine as Microsoft Windows XP Professional END-USER LICENSE AGREEMENT: Windows%20XP_Professional_English_9e8a2f82-c320-4301-869f-839a853868a1.pdf (via [Wayback] Convert your existing Windows XP system into a virtual machine – TechRepublic).

Note this does not cover OEM or Volume Licenses.

–jeroen

Posted in ESXi6, ESXi6.5, ESXi6.7, Power User, Virtualization, VMware, VMware ESXi, Windows, Windows XP | Leave a Comment »

Some links on USB pass-through for ESXi

Posted by jpluimers on 2022/03/23

For my link archive (especially because when disconnecting USB devices, the path value needs to be uber-correct, while for connecting, the path value only needs to be a partial match):

Commands applicable:

  • lsusb
  • the /var/log/vmkernel.log file filtered on usb (in a case insensitive way)
  • vim-cmd vmsvc/device.getdevices
  • vim-cmd vmsvc/device.connusbdev
  • vim-cmd vmsvc/device.disconnusbdev

–jeroen

Posted in ESXi6, ESXi6.5, ESXi6.7, Power User, Virtualization, VMware, VMware ESXi | Leave a Comment »

Some notes on replacing parts of a text file with template text using sed on a Busybox system

Posted by jpluimers on 2022/03/17

Note before you think about putting stuff in /etc/rc.local.d/local.sh: that script will not be executed when UEFI booting.

In a very lightweight Busybox system, I wanted to modify some configuration files automatically using fragments stored in template files.

The system has diff, but no patch.

The basic idea is to use sed to insert the template files into certain spots of the configuration file when certain marker texts are not present. So I want the opposite of [Wayback] Hey Stephen Wood: Try patch instead of sed in shell scripts.

Basically the idea is a poor-man’s patch, described in Too bad: ESXi busybox has diff, but not patch « The Wiert Corner – irregular stream of stuff.

Some links that might help me with this:

One alternative would have been to use ed (which is part of the normal Busybox), but ESXi Busybox omits ed like it omits patch.

Too bad that sed commands are too different from ed commands, as I could have used diff -e on another system based on ideas here:

I might give it one more go, as vi is sort of derived from ed via ex (see vi: Creation – Wikipedia), which means that vi “colon mode” (officially command mode: [Wayback] Vim documentation: cmdline) is very similar to ed.

Another alternative would be awk, but I have done so little work with it awk, that I’m hesitating to use a new tool. Some links:

And finally, ash could be used:

The kind of modifications I am after

Below are a few links with examples of the kind of modifications I want to make. Most patch just /etc/rc.local.d/local.sh, but some others introduce other changes as well.

Note that especially with networking settings, local.sh commands might not have any effect (for instance when having slow DHCP or other network issues), see for instance [Wayback/Archive.is] I’m running ESXi 5.5 and my persistent route in local.sh is not taking effect after boot. : vmware.

There is a very convoluted way around using local.sh by using the VIB authoring tool as described in [Wayback] How to create persistent firewall rules on ESXi. It requires lowering the software acceptance level to Community Supported (esxcli software acceptance set --level=CommunitySupported), which gives you a hard time installing ESXi updates.

I got that VIB idea from [Wayback] Solved: Re: Persistent firewall rule – VMware Technology Network VMTN, as:

The local.sh file gets overwritten often with upgrades so it would mean another step during the process.

From the same thread comes [Wayback] Solved: Re: Persistent firewall rule – VMware Technology Network VMTN

set the sticky bit on your separate xml-file – then it will be backed up and persist through reboot: chmod +t

run backup manually before the first reboot: /sbin/auto-backup.sh  because backup runs only once per hour

Within vSphere, one could use [Wayback] Configure ESXi Hosts with Host Profiles, but a standalone ESXi box is not part of vSphere, so that won’t work.

ESXi 7 and up

ESXi 7 makes the above harder as for instance user root cannot change file rights any more, so eventually I might revert to a VM that auto-boots when ESXi comes up, then patches the right files in place over PowerCLI (read-only) or SSH.

Need to give this some thought later:

–jeroen

Posted in *nix, *nix-tools, ash/dash, ash/dash development, Awk, BusyBox, Development, ESXi6, ESXi6.5, ESXi6.7, ESXi7, Power User, PowerCLI, Scripting, sed, sed script, Software Development, Virtualization, VMware, VMware ESXi | Leave a Comment »

Too bad: ESXi busybox has `diff`, but not `patch`

Posted by jpluimers on 2022/03/02

On my ESXi boxes, I have a directory with local scripts that in part depend on the machine.

So I contemplated patching the dending parts with patch.

Then I found out that the BusyBox that VMware built for ESXi does have diff, but not patch:

# $(readlink -f "`which diff`")
BusyBox v1.29.3 (2021-01-17 01:25:00 PST) multi-call binary.
BusyBox is copyrighted by many authors between 1998-2015.
Licensed under GPLv2. See source distribution for detailed
copyright notices.

Usage: busybox [function [arguments]...]
   or: busybox --list
   or: function [arguments]...

    BusyBox is a multi-call binary that combines many common Unix
    utilities into a single executable.  Most people will create a
    link to busybox for each function they wish to use and BusyBox
    will act like whatever it was invoked as.

Currently defined functions:
    addgroup, adduser, arch, ash, awk, basename, bunzip2, bzcat, bzip2, cat, chgrp, chmod, chown, chvt, cksum, clear, cp, crond,
    cut, date, dd, delgroup, deluser, diff, dirname, dnsdomainname, du, echo, egrep, eject, env, expr, false, fdisk, fgrep, find,
    fstrim, getty, grep, groups, gunzip, gzip, halt, head, hexdump, hostname, inetd, init, kill, ln, logger, login, ls, lzop,
    lzopcat, md5sum, mkdir, mkfifo, mknod, mktemp, more, mv, nohup, nslookup, od, passwd, poweroff, printf, readlink, reboot,
    reset, resize, rm, rmdir, sed, seq, setsid, sh, sha1sum, sha256sum, sha3sum, sha512sum, sleep, sort, ssl_client, stat, stty,
    sum, sync, tail, tar, taskset, tee, test, time, timeout, touch, true, uname, uniq, unlink, unlzop, unzip, usleep, vi, watch,
    wc, wget, which, who, xargs, zcat

This list is much shorter than the applets that are supported in [Wayback] BusyBox – The Swiss Army Knife of Embedded Linux, so VMware did cut out quite a few.

Generating the above output

The command-line trick above first expands diff using the output of which diff, then finds out where it links to through the readlink -f wrapper there the back-quotes “`” get this output:

# readlink -f "`which diff`"
/usr/lib/vmware/busybox/bin/busybox

Finally the $(...) executes the output of readlink.

It is based on [Wayback] bash – How to resolve symbolic links in a shell script – Stack Overflow

readlink -f "$path"

Editor’s note: The above works with GNU readlink and FreeBSD/PC-BSD/OpenBSD readlink, but not on OS X as of 10.11.GNU readlink offers additional, related options…

Need to devise a way to apply patches

Given there is no patch, I need to think about a good way to apply patches, for instance to snip this into /etc/rc.local.d/local.sh in a reliable way:

## BEGIN-PATCH-PATH

# local binaries are in /vmfs/volumes/NVMe980PRO_1TB/local-bin/
# link that directory from /opt/bin
# then add /opt/bin to the PATH in /etc/profile so that on each logon it becomes available
# this means you need to logon twice after reboot:
# - first to patch /etc/profile
# - second to have the correct PATH loaded from /etc/profile
# direcory exist trick from https://stackoverflow.com/questions/59838/how-can-i-check-if-a-directory-exists-in-a-bash-shell-script

patch_etc_profile_PATH() {
    if [ -d "$1" ]; then
      ln -s "$1" "/opt/bin"
      sed -i -e 's!PATH=/bin:/sbin!PATH=/bin:/sbin:/opt/bin/!' /etc/profile
    fi
}

patch_etc_profile_PATH /vmfs/volumes/NVMe980PRO_1TB/local-bin/

## END-PATCH-PATH

–jeroen

Posted in *nix, *nix-tools, ash/dash, ash/dash development, BusyBox, Development, ESXi6, ESXi6.5, ESXi6.7, ESXi7, Power User, Scripting, Software Development, Virtualization, VMware, VMware ESXi | Leave a Comment »

ESXi: some notes on .vswp files; there are actually two types of them!

Posted by jpluimers on 2022/02/23

Earlier this month, I ended ESXi: editing /etc/vmware/hostd/vmInventory.xml to fix the datastore UUID for unavailable VMs part 2 with this:

A final note: I need to check out if .vswp files need to be there at all, as my ESXi servers have plenty of physical memory in order not to swap out to disk. More on that in a future blog post.

Browsing back through my blog posts, I mentioned .vswp files before, but never really dug into them:

Read the rest of this entry »

Posted in ArchiveTeamWarrior, ESXi6, ESXi6.5, ESXi6.7, ESXi7, Internet, InternetArchive, Power User, Virtualization, VMware, VMware ESXi, WayBack machine | Leave a Comment »

ESXi: forcing VMKlinux drivers over native drivers, especially at boot time for sort-of supported hardware

Posted by jpluimers on 2022/02/22

Note: the below holds for sure for ESXi 5.x and 6.5; as of ESXi 7.x, the VMKlinux stack is supposed to be gone for good. I still need to verify that as I’m still on ESXi 6.7.

I wrote about ESXi VMKlinux and native drivers before:

Back then, I knew that VMKlinux based drivers were being slowly phased out as of ESXi 5.5. But I didn’t really understand the actual difference.

VMKlinux is a bit like NDISwrapper – Wikipedia: it allows drivers basically written for a different platform to run on your platform. For NDISwrapper, it is about running Windows NDIS drivers on both i386 (née, x86-32, née IA-32) and x86-64 architectures. For VMKLinux, it allows drivers originally written for the Linux Kernel to be run on ESXi through an intermediate wrapper layer.

Usually having both native and wrapped code means that not all functionality is yet available natively. That was indeed the solution for my smartinfo trouble: the native drivers were having latency problems where the VMKlinux drivers were not.

Sometimes it means that hardware is only supported by the VMKlinux drivers, which (since native drives have a higher priority than VMKlinux drivers) means disabling the native driver.

This does not work in the early upgrade/install boot process: there the settings cannot be read from the configuration files yet. ESXi solves this by having a global boot option preferVmklinux=True that you can store in the boot configuration.

Most of the issues this solves are around USB boot sticks and USB disks, but not all of them, see the below links and summaries for more information.

I like the solution by temporarily using preferVmklinux=True, then just disabling the vmkusb best.

  • [Wayback] VMware vSphere 6.5 install can’t find USB device – Gallahad IT Inc.

    Upon rebooting the host, the host will need to use the legacy USB drivers to boot correctly.  At the startup screen, you can press “e” to edit the boot parameters or later you can press “Shift + O” to edit the boot parameters.

    Again add this to the boot parameters: preferVmklinux=TRUE

    Once the system is booted and you can login to the ESXi shell you will need to enter the following commands:

    esxcli system settings kernel set -s preferVmklinux -v FALSE
    esxcli system module set –enabled=false –m vmkusb
    reboot

    Once the system reboots it will boot and discover the USB devices properly.

    It should be noted that only a few systems have problems with the new USB driver.  I had this trouble on an older system.  An HP ML330 G6 gave me the trouble.

  • [Wayback] Installing VMware ESXi 6.7.0 on a Hades Canyon NUC – The NUC Blog

    only one of the two Gigabit Ethernet interfaces will work out of the box. That’s why the interface did not get an IP address in the video above. Both interfaces were detected, but for some reason only the other one was detecting signal when I had an Ethernet cable plugged in.

    using another computer make an SSH connection to the ESXi box, log in as root and execute the two following commands:

    esxcli system settings kernel set -s preferVmklinux -v TRUE
    reboot

    After the reboot your both network interfaces should be working as expected.

  • [Wayback] Solved: Upgrade problem !! – VMware Technology Network VMTN

    After upgrading my ESXi host from 6.0 to 6.5, I am now unable to SSH into it or connect to it in any way. It appears to freeze half way through booting up (last message displayed : nfs41client loaded successfully) … Hardware: MacPro 6,1 Q: What are my options? TIA

  • [Wayback] ESXi 6.5 support for Apple Mac Pro 6,1

    If you prefer not to manually have to add the ESXi boot option by hand, you can create an ESXi bootable USB key and then simply edit both boot.cfg and efi/boot/boot.cfg and append the option as shown below:

    kernelopt=runweasel preferVmklinux=True
  • I got a question from my buddy Paudie O’Riordan this morning where he was noticing a strange issue while trying to upgrade his ESXi hosts from 6.0 to 6.5 (all on the VMware HCL). Like many of…[Wayback] No suitable disk was found when upgrading to ESXi 6.5 on USB?

    The issue looks to be related to the new USB Native Driver (vmkusb) that was introduced in ESXi 6.5 where is it is unable to claim the specific USB device.

    Although you can disable the USB Native Driver and fall back to the legacy driver as mentioned in this VMware KB 2147650, but because this is happening during the installation/upgrade process, it can get a bit tricky.

    workaround

    1. Step 1 – Append preferVmklinux=TRUE to the ESXi’s boot.cfg file whether that is on a USB device which has your ESXi installer or on your PXE Server for ESXi Scripted Installations.Here is an example of what boot.cfg should look like:
      kernelopt=runweasel preferVmklinux=TRUE</pre>
    2. Step 2 – Boot up ESXi and you should now be able to see the USB device and continue with your upgrade.
    3. Step 3 – Once ESXi has been successfully upgraded, go ahead and run the following commands to re-enable the Native Drivers and disable the vmkusb driver (reboot required for changes to go into effect):
      esxcli system settings kernel set -s preferVmklinux -v FALSE esxcli system module set –enabled false -m vmkusb reboot

       

      Note: If you are doing an ESXi Scripted Installation, you can actually append just the first two commands (replace esxcli with localcli as hostd is not running) as part of the Kickstart %post section.

  • [Wayback] Important information about the new ESXi 6.5 USB driver vmkusb, and the legacy USB drivers (2147650)

    In ESXi 6.5, the legacy USB drivers, including xhci, ehci-hcd, usb-uhci, usb, usb-storage, and so on, are replaced with a single USB driver named vmkusb. The vmkusb driver is loaded by default and it is applied to all the USB Host Controllers (XHCI/EHCI/UHCI/OHCI), USB Keyboard, Mass Storage, and supported USB NIC devices connected to the host.

    You can disable the vmkusb driver by running esxcli system module set -m=vmkusb -e=FALSE. The legacy USB drivers are loaded at the next reboot. To re-enable the vmkusb driver, run esxcli system module set -m=vmkusb -e=TRUE, and reboot the host.

    If the host will not boot completely to use the solution, please follow the below steps:

    1. Reboot the ESXi host.
    2. During the pre-boot splash screen, press SHIFT-O to modify the boot options.
    3. In the resulting screen, add the following to the end of the boot line:
    jumpstart.disable=vmkusb
    1. Press the enter key to resume boot.
    Note: When ESXi host comes up, vmkusb module will be disabled, and the solution can be followed to make the change permanent.
  • Wayback VMware Knowledge BaseL Enabling and Disabling Native Drivers in ESXi (2147565)

    ESXi 6.5 contains many new native drivers that replace the earlier vmklinux drivers. Most of the new native drivers are enabled by default after installation or upgrade.

    Some of the new native drivers are disabled by default, because they do not fully support the functions of the corresponding vmklinux drivers. For example:

    • qflge is a native driver that replaces the vmklinux net-bnx2 driver, but does not support HW iSCSI.
    • qfle3 is a native driver that replaces the vmklinux net-bnx2x driver, but does not support HW iSCSI and SW FCoE.
    • ixgben is a native driver that replaces the vmklinux net-ixgbe driver, but does not support SW FCoE.

    steps for enabling/disabling a native driver (which then overrules the VMKlinux driver)

  • Current versions of ESXi 6.x are shipped with both the VMKlinux and the Native driver stack. Modern hardware is, in many cases, using the new Native drivers. However, older hardware may still depend on a VMKlinux driver module. We announced to deprecate the VMKlinux driver stack back in 2017. This blog post goes into detail … Continued[Archive.is] What is the Impact of the VMKlinux Driver Stack Deprecation? – VMware vSphere Blog

    Since the first days of ESX, we used the Linux derived driver modules to provide support for a large range of hardware devices. Doing so gave us a lot of hardware compatibility, but at the cost of introducing an additional layer of driver emulation. Because ESX is not Linux, we needed a translate layer that provides communication between the VMkernel and the Linux driver modules. This is the imperative layer that is VMKlinux. But since vSphere 5.5, we introduced the Native driver stack with the plan to move away from the VMKlinux driver stack. Please review the following blog posts for more in depth information about both driver stacks:

    The vSphere 6.7 family will be the last vSphere versions that includes the VMKlinux driver stack. Future releases will only ship with the Native driver stack.

    How to check impact on your cluster

    If you run the following command, it will show you if the VMKlinux module is loaded on that specific ESXi host.

    esxcli system module list | grep vmklinux

    When it returns nothing, the system is already in full native mode and there are no VMKlinux dependencies. This however, is an ESXi host only approach. We came up with the following script to assist you in verifying an entire cluster.

    With the help of William Lam, we created a script that identifies ESXi hosts with VMKlinux driver modules loaded. The usage of the script is pretty straightforward. Get, and contribute to, the script here: https://github.com/lamw/vghetto-scripts/blob/master/powershell/VMKLinuxDrivers.ps1.

  • A balanced discussion (despite the title) on two forum pages on ESXi 7 dropping VMKlinux support:
    1. [Wayback] My Rant on ESXI 7.0 | ServeTheHome Forums: page 1
    2. [Wayback] My Rant on ESXI 7.0 | ServeTheHome Forums: page 2

–jeroen

Posted in ESXi6, ESXi6.5, ESXi6.7, ESXi7, Power User, Virtualization, VMware, VMware ESXi | Leave a Comment »

Creating a bootable USB installer for ESXi on other operating systems than Windows

Posted by jpluimers on 2022/02/17

I wrote about Creating a bootable USB installer for ESXi and use it to create a bootable ESXi installation.

Just in case I ever need to do this on a non-Windows system, some links:

–jeroen

Posted in *nix, Apple, ESXi6, ESXi6.5, ESXi6.7, ESXi7, Linux, Mac OS X / OS X / MacOS, Power User, Virtualization, VMware, VMware ESXi, Windows | Leave a Comment »

ESXi: for my link archive – links about “vim-cmd vmsvc/message” (lots of interesting scripts for deployment scenarios)

Posted by jpluimers on 2022/02/16

In ESXi: on the console/ssh, when a moved VM pauses during power-on: show which VMs have messages waiting, then answer them, I searched for [Wayback] “vim-cmd vmsvc/message” – Google Search in order to see which messages were available.

That search revealed a lot more links, so here are the ones I found most interesting:

 

–jeroen

Read the rest of this entry »

Posted in ESXi4, ESXi5, ESXi5.1, ESXi5.5, ESXi6, ESXi6.5, ESXi6.7, ESXi7, Power User, Virtualization, VMware, VMware ESXi | Leave a Comment »

ESXi: for my link archive “Developing for VMware ESXi”

Posted by jpluimers on 2022/02/15

This post amends the post last week on rsync backup of your ESXi box: How to make a statically linked rsync binary « The Wiert Corner – irregular stream of stuff.

Two weeks ago, I posted about Source: ESXi: searching for “vim-cmd vmsvc/message” lead me to the “Managing ESXi Without VI Client” series of blog posts.

It got me looking more deeply in the VM-Help site, and I found [Wayback] Developing for VMware ESXi – Virtual Machine and VPS Tutorials, for which I have materialised the links below and checked their WayBack machine status.

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.

Compiling rsync – [Wayback] How to compile a statically linked rsync binary for ESXi
Compiling Busybox – [Wayback] How to compile Busybox for ESXi … kind of Part 1
Discussion of compiling UNFS – http://www.vm-help.com/forum/viewtopic.php?f=16&t=2280&p=10185&e=10185 (not archived in the WayBack machine nor available on-line)
Notes on compling binaries – [Wayback] Stjepan Groš – Homepage

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 compatibility 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 – [Archive.is] Wayback: Adding Driver Support to VMware ESXi 4 | Tip’s Notebook
Compiling a Marvell sky2 driver – [Wayback] Using a Marvell LAN card with ESXi 4 – KernelCrash

(Note: This post was initially written when ESXi 4.0 was available. As of late 2010, ESXi 4.1 has been released, and it does actually include a sky2 driver that may or may not work with various Marvell LAN chipsets. The post is still relevant (especially the comments)  if your particular Marvell chipset does not work with the sky2 driver in ESXI 4.1. Also, the post is relevant if you’re interested in porting other network drivers to ESXi)

Open Virtualization Drivers development notes

Being from the ESXi 4 and 5 era, the links seem to hold up remarkably well. Despite ESXi 3 being Linux based (see [Archive.is] VMware ESX Server – Wikipedia, the free encyclopedia), as opposed to ESXi 4 and up that run a microkernel, Linux based tools still can be used to develop tooling and drivers.

–jeroen

Posted in ESXi4, ESXi5, ESXi5.1, ESXi5.5, ESXi6, ESXi6.5, ESXi6.7, ESXi7, Power User, Virtualization, VMware, VMware ESXi | Leave a Comment »