How to simulate a WAN inside a LAN for remote office server setup

local-area-networknetworkingvmware-esxiwide-area-network

I need to send 3 vmWare ESXi servers (hosts) to thee locations around the world. Each host will have 3-5 guest VMs performing various tasks. Each host will live behind a firewall configured with a branch office VPN tunnel back to our HQ. Each remote office will have it's own private network configured so that it does not match any other IP/Subnet of other remote offices. Pretty basic.

I want to simulate the WAN environment so that I can setup all the guest VMs here before sending them off to their future homes. Specifically, I want to test communication from server-to-server and make sure they can talk while on different subnets. I know that the firewall/VPN setup will allow this but I'd like to test it before it's thousands of miles away.

HQ Network
172.16.0.0/16

Remote Office Network 1
192.168.1.0/24

Remote Office Network 2
192.168.2.0/24

Remote Office Network 3
192.168.3.0/24

Remote Office Network 4
192.168.4.0/24

Best Answer

That is not so complicated, but you will need a router (or switch with router capability) to do so, just for basic connectivity tests.
Just setup 5 LAN's on the router, one for each subnet and configure the router on each subnet to behave as if it is the WAN/VPN router for the site.
Then hook everything up.
Of course you will have only 1 router-hop where in the real setup there will be many, but for the connection logic of the VM's that won't make any difference. You can test all your VM's and/or applications in this way.

You can't really test the VPN's themselves, unless you have a bunch of VPN capable routers at your disposal. Even then your setup will look nothing like the real thing. I wouldn't bother with that.

Simulating slow/bad latency on a WAN link can be done through a Linux box as mxrx already mentioned in his answer.
This will also act as the router so you may want to setup a VLAN capable switch to provide the 5 subnets as VLAN's + 1 additional trunk-port onto which you configure the router-PC as a router on a stick. No expensive hardware-router required.

If you are not interested in doing simulated WAN performance tests you can take this approach too, using pfSense as a software router.