Virtual Network In A Box
By:
Eric B. Rux
Many computer professionals have already discovered the power and versatility of using virtual machines in their LAB environment. In this article, I will show you how to expand that versatility by setting up virtual networks. Configured properly, virtual networks appear to be physically separate networks with their own address space.
While this could be done simply by using a virtual Windows server with multiple network cards, this takes up valuable memory and CPU cycles, not to mention hard disk space of the host that is running the virtual software. Instead, I will show you how to setup a virtual network using only 16M of memory, and less than 2M of hard disk space using a free Linux router. Don’t worry, you don’t need to know a thing about Linux; the router is completely menu driven.
The first step is to hand sketch the desired network configuration. Here is an example of a simple virtual network. Notice that one network is attached to your physical network card. This gives all of your virtual networks access to the Internet.

This sketch shows only one server per network. However you can actually have many more and are only limited by your IP address scheme, and the physical memory of your host machine.
Now that you have a
plan, it’s time to start putting it all together.
First, download the FreeSCO Router floppy image. FreeSCO stands for “Free Cisco”. A VMware compatible floppy image can be downloaded from the vmguru website. http://www.vmguru.com This version of Free SCO has all of the drivers that we need already loaded.
Once the virtual floppy has been downloaded, you are ready to create your Virtual Router. Create a new VM and choose a Typical configuration with “Other Linux” as the operating system and “bridged networking” on the network card. Your Virtual Router will not need a hard disk or CDROM, so you can remove them if you wish. Add in three additional network cards. Your Virtual Router should look similar to this:

Don’t forget to assign each network card to a different network.

Start the virtual machine that you just created and log in as “root” with a password of “vmware”. Type “Setup” to view the setup menu. As you can see from the boot process, this router runs Linux. However, everything you need to configure the router can be done from this menu screen.
Type “2” (without quotes), then press Enter:

On the next menu screen, enter “a” (without quotes), then press Enter to change to advanced settings:

Enter menu item 62 for Local networks

Next, assign network addresses and subnet masks to the router using the simple menu system. For example: to change the IP address, type “621” and then press Enter. Then enter in the IP address.

Use Menu item 25 to ensure that each network is trusted. Otherwise, network traffic will not be allowed to pass from network to network.

Once you have finished with the setup, don’t forget to save the settings and reboot.

Reboot the router by entering in “Reboot”. After the router reboots, you are ready to start routing between virtual networks.
The FreeSCO Router is capable of much more. Download it, set it up, and soon you too will have a Network In A Box.
Notes from the
field:
If you have any questions or comments, please feel free to email me at: ebrux at mvps dot org