Page 1 of 1

Help on choosing network connection

Posted: 31. Jan 2013, 13:53
by mat1_8
Hi,

Currently I am experimenting with PacketFence by using VirtualBox. My setup is like this:

VM 1: Server
VM2: Client (testing purposes)

Both the VM1 and VM2 have IP address 10.0.2.15 since they are configured in NAT mode. Having such network is not vital to my testing since I need to change the way the network works.

What I would like to do is this: Have VM1 (Server) and VM2 (Client) under one virtual network but with different IP addresses and at the same time be able to access the Internet from my physical PC. Also, VM1 needs to act as a DHCP server for VM2. I know that there are Bridged network, Internal network and so on which I can configure but don't know if I can do such implementation.

In other words VM1 and VM2 need to be in their own virtual network (for testing purposes) and at the same time can access the Internet via my physical machine/network. Is this possible please? Thanks

Re: Help on choosing network connection

Posted: 1. Feb 2013, 00:11
by BillG
Yes, it can be done in several ways.

To communicate with each other and run DHCP you need to put the vms in an internal network. DHCP uses LAN broadcasts so the machines need to be in their own network.

There are several ways to give these machines Internet access. For example you could give them two NICs each, one in the internal network and one using NAT (as at present). You could only give them one NIC (in the internal network) only and run a router in a vm to route this network to the Internet. The router vm would have one NIC in the internal network and one bridged to the physical NIC in the host.

Re: Help on choosing network connection

Posted: 1. Feb 2013, 08:57
by mat1_8
Thanks for your help BillG :D

BillG wrote:Yes, it can be done in several ways.

To communicate with each other and run DHCP you need to put the vms in an internal network. DHCP uses LAN broadcasts so the machines need to be in their own network.

There are several ways to give these machines Internet access. For example you could give them two NICs each, one in the internal network and one using NAT (as at present). You could only give them one NIC (in the internal network) only and run a router in a vm to route this network to the Internet. The router vm would have one NIC in the internal network and one bridged to the physical NIC in the host.