KnowThreat will soon be offering VMware VI3 Training, on behalf of VMware, Inc. To celebrate the announcement, I thought I'd post this quick walkthrough detailing my process for building an installing a full VMware Virtual Infrastructure environment using ESX 3 and VC 2 within virtual machines in VMware Fusion Beta on Mac OS X 10.4.10. This environment proved to be ideal for simulation and testing (though performance obviously leaves a bit to be desired) and saved me the trouble of using an Ubuntu daily build just to do the same thing in VMware Workstation via Linux on the same hardware. Further, with VMware Fusion's new “Unity” feature, I can run the VI Client alongside all of my other OS X applications as if it were natively built for the Mac!
After using it pretty constantly for the past two weeks, I can say that VMware Fusion is certainly an excellent basis for the forthcoming GA product, and though there are still a few minor features missing and kinks to work out before we see a 1.0 release, I've been very pleased with its functionality and performance thus far.
In Part I of this walkthrough, I'll show you how to setup VMware Fusion to allow ESX to install, then setup bi-directional connectivity between your laptop and your virtual infrastructure.
Before you begin this process, I recommend you free up plenty of disk space. On my first run through this process, I created the virtual disks for both ESX and Windows XP with a bit too little available free space. This process itself can be made significantly easier with the assistance of either Disk Inventory X or GrandPerspective, both of which provide visualizations of your filesystem that should make removing existing disk hogs significantly easier. I'd suggest you leave no less than 20 – 30 GB available specifically for your virtualization environment if you plan to put it to any real use.
Building our environment essentially just consists of creating and customizing a VM to host VMware ESX Server, then creating additional VMs using default settings to hold our VC and other Guest VMs.
Now, go into the VMs Settings dialog and increase Memory to the amount specified as the ”Recommended maximum“ in the Memory dialog. Select 2 Processors. Set Network to Bridged.
Close VMware Fusion, browse to the location of your ESX VM, select it and choose ”Show Package Contents.“ Then open up the .vmx file and ensure the following values exist as specified.
virtualHW.version = ”6“ scsi0.virtualDev = ”lsilogic“ ethernet0.virtualDev = ”e1000“ ethernet0.addressType = ”generated“ monitor_control.restrict_backdoor = ”TRUE“ monitor_control.vt32 = ”TRUE“ virtualHW.productCompatibility = ”esx“
Close the Package Contents window in Finder, Re-open VMware Fusion, and we're ready to move on.
When you first boot your new VM, Fusion will prompt you to recreate the virtual disk, as it was originally created using a different virtual SCSI adapter. In order for the VM to function properly, you must allow VMware to recreate the virtual disk. Ignore any warnings and move on.
Now, insert your ESX installation CD, boot your VM and install ESX. When giving ESX an IP address, make sure to use an IP on an unused private subnet, not your existing Internet-facing subnet! For example, if your existing network is a 192.168.1.0/24, give the ESX machine an IP within 192.168.254.0/24 or something within 172/12 or 10/8. Next, we'll add an alias to our wired interface so that we can communicate ‘pseudo-privately' with our VVI while maintaining Internet connectivity from our laptop.
First, you'll need to give your MacBook an IP on the private subnet that you established for your ESX VVI. To simplify this, we'll add an alias to our wired interface. Note that this technique will not work on your wireless (en1) interface, as packet forwarding is handled differently and will prevent your laptop from communicating with its VMs.
taylor@[~]: ifconfig en0 en0: flags=8863
mtu 1500 tunnel inet --> inet6 fe80::42b:79fb:fa97:ea12%en0 prefixlen 64 scopeid 0x4 inet 10.254.254.100 netmask 0xffffff00 broadcast 10.254.254.255 media: autoselect (100baseTXtaylor@[~]: sudo ifconfig en0 alias 192.168.254.100 netmask 255.255.255.255 taylor@[~]: ifconfig en0 en0: flags=8863 ) status: active vlan: 0 parent interface: bond interfaces: mtu 1500 tunnel inet --> inet6 fe80::42b:79fb:fa97:ea12%en0 prefixlen 64 scopeid 0x4 inet 10.254.254.100 netmask 0xffffff00 broadcast 10.254.254.255 inet 192.168.254.100 netmask 0xffffffff broadcast 192.168.254.255 media: autoselect (100baseTX ) status: active vlan: 0 parent interface: bond interfaces:
After adding the interface alias, you should be able to ping your ESX VM on the new subnet while maintaining the default route for your laptop through your existing upstream gateway. Note that the VM will otherwise be isolated, as it has no knowledge of any other subnets, nor a route to or through any default routers.
In Part II of this series, I'll show you how I setup VC and my virtual-virtual machines, as well as how I setup a virtual SAN for ESX datastores and VM usage!
Taylor Banks is an entrepreneur who travels full-time in an RV with his wife, Beth, and their dog, Sedona. Taylor's background is in computer, network and information security and privacy, but he now also runs several e-commerce sites and chairs a mastermind group that provides mentorship to other entrepreneurs who want to achieve location and financial independence with passive income provided by lifestyle businesses.