How To Set Up Virtual Servers

Give you clients new IT power and flexibility--without a lot of heavy iron

Printer-friendly version Email this CRN article

These days, when a client needs to support a new application or a growing user base, falling hardware prices and soaring system specs make it all too tempting to simply add a server or three. Exacerbating the problem is a growing class of enterprise server applications that insist on running in isolation, either on their own hardware on an isolated operating system image. Unfortunately, this leads to server farms getting out of control and creates management headaches. Due to bad data-center design, overpowered servers spend more time generating heat than crunching numbers.

It doesn't have to be this way. Using virtual-machine technology, you can split one high-powered server into several virtual slices. This way, each slice has its own partitioned-off operating system, disk, and CPU resources.

In the mainframe world, virtual-machine images are old hat. But for the small and mid-sized business (SMB) market, it's a relatively new technique.

Virtual servers let a single box run several different virtual machines (VMs). Each VM can run its own operating system, completely independent of the OS installed on the host computer. For example, a single Windows 2000 Server machine could host a VM running Windows Server 2003 Web Edition for streaming media alongside three different flavors of Linux, each running its own dedicated application. Multi-CPU systems can devote a different CPU for each virtual machine. Different amounts of RAM can be provided to each virtual machine, depending on need. Even if one virtual machine crashes, the other VMs will continue to run undisturbed.

A virtual-server platform, such as GSX Server from VMware, lets disk images be swapped among host computers, as each virtual machine emulates the same set of virtual hardware, down to the chipset level. If your clients are sick of adding racks every time they do a system upgrade, you can wow them with the ability to make one computer do the work of many. For both you and your clients, it can save time and hassle over the long haul.

Here's what you'll need to get started:


  • GSX Server. Available from VMware, GSX Server is the company's mid-range product. It's suitable for systems with as many as 32 CPUs running up to 64 GB of memory. Licensing starts at $3,025 for a two-processor machine. A downmarket alternative is VMware's Workstation at roughly $300. At that price, server strength is not guaranteed, and your configuration options are less flexible.
  • A host computer.The host must run a Windows Server variant, or a Mandrake, Red Hat, or SuSE server-grade Linux install. (VMware Workstation users can get away with using Windows 2000 Professional or XP, however.) Virtually any 32-bit x86 hardware platform is suitable for GSX Server; for this Recipe, we used a modest Intel Pentium 4 at 2.2 GHz, running Windows 2000 Server. Decide how many virtual machines you intend to run on the host computer before making the final hardware decision. VMware recommends that you run no more than four virtual machines per CPU to prevent slowdowns. Remember, even on a multiprocessor host, each virtual machine will behave like a single-processor computer.
  • RAM, lots of it. Why a lot? Because each virtual machine needs its own dedicated chunk of memory. The host OS must have enough room to run. Plus, GSX Server has its own operating overhead. My recommendation: Total up how much memory you need for each virtual machine, then add at least 256 MB for overhead from both the OS and VMware. For example, to run this Recipe, I configured the host with 768 MB. You may need even more. Depending on the host OS, a single virtual machine may be allocated as much as 3.6 GB of RAM.
  • Guest operating systems. Each virtual machine needs its own unique software installation. GSX Server supports several guest operating systems, including Windows down to 3.1, MS-DOS 6.22, most variants of Linux and FreeBSD, and Novell NetWare. For this Recipe, I used Red Hat Enterprise Linux ES 3 and Windows 2003 Server Enterprise Edition.
  • One or more dedicated hard disks per virtual machine (optional). GSX Server will transparently create virtual partitions for each machine on a single disk or disk array visible to the host server. But advanced users and high-performance environments may demand that each virtual server have its own disk for better performance. If you go this route, make sure the disks are attached to the host controller, but are not formatted and mounted on the host, to prevent access conflicts.

Sprouting Virtual Servers

Once the host machine is prepared with GSX Server, you can configure and run new virtual machines in less than a minute. Here's how:

1. Streamline the performance of the host machine by entering Administrative Tools and shutting down as many extraneous services as possible. The less CPU time burned by the host, the more the virtual machines can use. Be sure to leave IIS and all COM functionality running, however. VMware needs them for its configuration interface.

2. Obtain GSX Server (or whatever VM software you decide to use) via package or download purchase. Run the installer.

3. If Autorun is turned on for your optical drives, the GSX Server installation will prompt you to disable it. To do so, click Yes. Multiple virtual machines attempting to Autorun a CD could lead to problems.

4. Restart the computer when prompted. Then open GSX Server. Register the software with the serial number provided by VMware.

5. Click New Virtual Server to define the first virtual machine. In our case, this is Red Hat ES. Select Typical configuration. When presented with a list of guest operating systems, choose Linux, or the listing that best suits the guest operating system you plan to install. GSX Server will suggest a nickname for this configuration of "linux", which you may change to anything you wish.

6. VMware can share one or more network interfaces across virtual machines. The most straightforward networking mode is Bridged networking. This creates a virtual Ethernet device inside the virtual machine that appears to be another node on the network to a local router or switch. Select this option. Then click Next.

7. GSX Server will automatically create a virtual disk file for this virtual machine, then store it on the host computer's file system. Virtual disks can grow to a maximum of 4 GB, and more can be added later. Input the maximum size you want, then click Next.

8. Create a Windows Server 2003 virtual machine. Click New Virtual Machine. But this time, select the Custom option. This adds a few questions to the process, eliminating some default assumptions by the software.

9. This time, GSX Server asks how much memory to allocate. Ensure that the Windows Server 2003 machine receives at least 256 MB.

10. GSX Server will ask about networking for this virtual machine. As before, answer Bridged.

11. GSX Server presents advanced disk options. You can create a new virtual disk. Or, if you wish to assign a dedicated drive to the virtual machine, select Use a Physical Disk. You will need to know the ID number of the drive: ID 0 is the Primary Master disk, typically the boot drive for the host OS. Set any drives that will not be used to install the guest OS to either Hide or Read-only status. Physical drives that can be written by a virtual machine should not be visible to the host OS or any other virtual machines. If they are visible, more than one operating system could try to write to the drive at the same time, resulting in corrupted data.

12. Once the two virtual machine configurations are complete, it's time to turn them on and install the server software. Place Red Hat ES CD1 in the computer's optical drive. Select the Linux profile. Click Power On. A window will appear showing a BIOS power-up sequence similar to what you would expect from a real PC.

13. After a few seconds, the virtual machine will begin booting from the Red Hat CD. To provide input to the VM, click inside the window. The mouse and keyboard will then be locked to that virtual machine. Free up control by pressing CTRL ALT simultaneously.

14. Go through the Red Hat Enterprise Linux ES installation process. This particular version of Linux can detect the VMware virtual graphics adapter, so you may use higher resolutions and color depths out of the box.

15. Once the installation is complete, you have a living, breathing Linux server environment, cozily hosted by a Windows server box. Turn on and configure whatever services you wish.

16. Install the OS for the Windows 2003 virtual machine. Place the Windows Server 2003 Enterprise Edition install CD in the drive. Highlight the Windows 2003 virtual machine in the GSX Server window. Select Power On.

17. The BIOS screen should look virtually identical to the Linux boot sequence, although details such as memory and disk may be slightly different, depending on the choices you made during the configuration. Windows 2003 will begin to boot. Follow the prompts to configure and install.

18. When Windows Server 2003 reboots and prompts you to press CTRL ALT DEL, use CTRL ALT INS instead. VMware will translate the keypresses inside the virtual machine. It will keep your host Windows installation from intercepting the keys and bringing up its own task manager.

19. Once Windows Server 2003 is up and running, escape the window by pressing CTRL ALT. Then click the "install VMware tools" link at the bottom of the window. This automatically launches a program inside the virtual machine that installs custom device drivers for better video performance and networking.

20. Configure the Windows 2003 environment as you see fit.

21. Whenever the virtual machines need to be taken offline, be sure to use the shut-down commands inside the VM operating systems, rather than the "power off" button on the virtual machine window. Consider Power Off a method of last resort -- the data consequences are every bit as abrupt as pulling the plug on a real computer.

With the aid of virtualization, one box, one keyboard, and one mouse can do the work of an entire rack. Hardware maintenance becomes localized. And as you can see from the example, it is possible to install new operating systems atop older environments without gutting and re-imaging the system. Virtual servers also provide the ideal environment to maintain legacy servers, which may require minimal CPU and disk allocations but would otherwise run on wheezy, bulky hardware. Virtual servers provide power and flexibility to your IT clients without a lot of heavy iron.

JASON COMPTON is a technology writer who has covered topics ranging from 8-bit entertainment to supercomputing for more than a decade.

Did you try this Recipe? If so, how did it work? Visit TechBuilder's Recipe Forum, and share your results with more than 2,500 other registered system builders..

Printer-friendly version Email this CRN article