Link to home
Start Free TrialLog in
Avatar of NCI_IT
NCI_IT

asked on

VMs and different IP subnets

I've been tasked to come up with a solution for a team of software developers. They want to be able to run 3 or more Linux VMs in a physical Windows PC. The problem is that each of these virtual PCs need to ideally be on different networks than the physical network card they are connecting to. The VMs would connect out through a second NIC than what the Windows OS would connect out of.

Is this even possible to do without using NAT? Can the NIC be connected to a VLAN trunk on the switch?

We have yet to decide on exactly which VM we will be using.

The hope is to replicate a field install of 3 physical servers which will each be on different networks without having to have the infrastructure surrounding it.
Avatar of expert02232010
expert02232010

Yes.
vmware can give each VM its own IP address, and they can share a NIC, they can also be placed into VLANs as well.
Not sure on all the other VM products, but most all of them do support those options.
clarification:  they can all be in different subnets as well.  the VM software would operate a software switch that is "connected" to the PC NIC card.  Each VM NIC could have its own MAC address as well, that is default for most of the VM software.  
Avatar of NCI_IT

ASKER

So - if I understand what you are saying, VM#1 would need to go to the router and back in order to talk to VM#2.

Is that correct?
the VM software can handle the traffic between VMs.  but there may now be options to force that traffic out to the router as well.  It depends on the software you use, and the configuration options selected.
Depending on what VMware product you are using - options are a bit different. You are correct in your assumption that a router will be required for communication between different IP subnets - the VMware software does not provide any routing functionality.

The router can be either physical (outside of your VMware host) or virtual such as options from Monowall, Vyatta, and PFSense.

Please detail your setup:
Type of VMware software (Workstation, Server, ESX, ESXi)
Type of host PC or Server
Number of NICs in VMware host
Types of routers/switches involved
connectivity requirements for each vm - ie. are they isolated and only host on the subnet? Do they need to communicate with other physical or virtual machines? etc.

With that info I am sure we can help you design a solution

Good Luck
Avatar of NCI_IT

ASKER

Please detail your setup:

Type of VMware software - Not chosen at this point. VMware has been brought up but it will need to be researched for feature function.
Type of host PC - PC, will be XP, Vista or Win7
Number of NICs in VMware host - at least 2, one for the Windows OS and the other for the VM boxes
Types of routers/switches involved - Cisco, various models
connectivity requirements for each vm - The VMs need to communicate with each other and with other hosts on different subnets. In fact, each virtual host will likely have multiple virtual NICs on different subnets.

The purpose of this setup is to replicate a Linux server cluster for a custom application.
Certainly doable, in fact, I've seen many similar demos that are all hosted on a single notebook running a few VMs of the servers and clients to show how things interact.
You will want to make sure you have enough RAM in the systems, as well as processor, but RAM is the larger issue from my experience.
If you are not concerned about taking snapshots of the system, then you can begin trying VMWare Player, which is free.  VMWare Workstation adds some additional functionality, including multiple snapshots (point in time images) for each VM.
Sounds like your VMware software will likely be VMware Workstation - the Player software won't give you the flexibility required for your setup, VMware Server requires a Server OS, and ESX/ESXi requires server class software.

So long as you don't need to put your virtual machines on an existing subnet shared with other physical machines you should be able to accomplish this with VMware Workstation and a virtual router such as Vyatta. You can assign your guest VMs to "host-only" networks that are shared with the virtual NICs on the Vyatta appliance, then route everything out through the bridged network NIC you are allocating to your vmware guests.

Note that you will need return routes to the Vyatta from your physical infrastructure router.

Good Luck
Avatar of NCI_IT

ASKER

The virtual servers will need to talk to hosts on the physical network as it needs to interact with them. In turn the external hosts will need to talk back to the virtual servers.

I'll look into VMware workstation.
ASKER CERTIFIED SOLUTION
Avatar of bgoering
bgoering
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial