Most IT administrators know how to create a new virtual server. You download or purchase the ISO or install disk, fire up your favorite virtual machine (VM) tool, and install the operating system on a new VM. But how do you make use of all of those virtual appliances and other pre-built VMs? I'll show you how to load pre-built VMs in VirtualBox and VMware Player.
I will assume that:
- You have either or both virtual tools installed, as well as a suitable VM or virtual appliance downloaded and ready to go.
- You know how to create a new VM within either or both of the VM tools.
- The virtual appliance to be added is in the .vmdk format.
During the simple process of creating a new VM in VirtualBox, you will have to point the VM wizard to the .vmdk file on your hard drive. Let's walk through the process to that point.Step 1: Start the wizard and name your VM Fire up VirtualBox and click the New button. In the first screen of the wizard, you need to name your VM and select the operating system the virtual machine is based upon (Figure A). Figure A
VirtualBox will attempt to automatically detect the operating system, based on the name entered. (Click the image to enlarge.)Step 2: Assign memory to the machine
In the next window, you need to assign an amount of memory to the VM. Don't give the VM so much memory that your host system will become bogged down in the running of the guest.
Step 3: Associate the hard driveThis is where you associated your .vmdk file to the VM. In this window, select Use Existing Hard Disk, and then click the folder icon to browse to the location of your .vmdk file (Figure B). Figure B
If you've already used a .vmdk file, it will show up in the drop-down listing for the existing hard drives. (Click the image to enlarge.)
After you set up the hard drive, you can finish the VM setup per normal, and you're ready to fire up this VM.
VMware PlayerThe use of a .vmdk is somewhat similar in VMware Player as it is in VirtualBox. You will follow the process of creating a new VM as you normally would except, in the first screen of the creation process, you should select I Will Install The Operating System Later (Figure C). Figure C
It's not terribly intuitive, but it's easy to add a .vmdk file to a new VM in VMware Player. (Click the image to enlarge.)After completing the process of creating the new VM, go back to the VMware Player management window, select the VM to have the new .vmdk file and click the Edit Virtual Machine Settings button; this will bring up the Settings window, where a new Hard Drive can be added (Figure D). Figure D
This gives you an at-a-glance report on everything about this VM. (Click the image to enlarge.)Click the Add button and select Hard Disk from the listing of hardware in the new window. In the resulting window, select Use An Existing Virtual Disk (Figure E). Figure E
This is the only option that will allow you to select a downloaded .vmdk file. (Click the image to enlarge.)
In the next window, click the Browse button and navigate to the directory housing your .vmdk file. Once you've located it, click the Finish button.
Next, remove the original hard disk created during the first steps of the VM setup by selecting the initial hard disk (it should be the first one listed), clicking the Remove button, and clicking Save. Your VMware Player VM is ready to fire up!
If you plan on using VMs, you need to learn how to use downloadable appliances and other available .vmdk files. The methods I describe in this post should get you up to speed with two very popular VM tools.
Jack Wallen is an award-winning writer for TechRepublic and Linux.com. He’s an avid promoter of open source and the voice of The Android Expert. For more news about Jack Wallen, visit his website getjackd.net.