13

Sometimes I need to simulate a WAN environment between my client and server. I mean, specifically, from most important to least:

  • Total bandwidth limit,
  • Occasional long (many tens of seconds) delays
  • jitter

Preferably, the WAN simulator could act as a proxy -- I point my client at the WAN simulator and the WAN simulator talks to the server. I have spent a lot of time Googling to try to find something that will do this, and have found very very little.

Of course, I know there are various solutions I can implement by controlling the network topology and inserting devices in the middle, but IT controls the network. I'm just a developer.

What free or low cost tools do y'all know about that can help one simulate a WAN?

HopelessN00b
  • 53,385
  • 32
  • 133
  • 208
Eddie
  • 11,332
  • 8
  • 36
  • 48

6 Answers6

7

If you use Linux you can use tc - the traffic control program. It should be standard in your distro. For example, to set the upload maximum speed (in this case 100 kbit per second):

$ sudo tc qdisc add dev eth1 root tbf rate 100kbit latency 600ms burst 1540   

to set the download maximum speed (in this case 500 kbit per second):

$ sudo tc qdisc add dev eth0 root tbf rate 500kbit latency 600ms burst 1540

tc can do a lot more than that. I can't find the reference right now, but you can drop packets etc with tc. To find out more, you can read the traffic control howto.

Alternatively you could look into tcng - Traffic Control Next Generation - this uses tc at a low level, but has a slightly nicer language to specify what you do. I have not used it, but there is a tcng howto and a tcng manual.

Hamish Downer
  • 9,142
  • 6
  • 36
  • 49
6

http://communities.vmware.com/blogs/Knorrhane/2008/01/23/how-to-simulate-wan-connections-in-your-own-test-lab-for-free

saschabeaumont
  • 2,794
  • 22
  • 14
  • In the article they mention Tmurgent also introduces latency for testing. This is key. We found the hard way with our internal app that bandwidth wasn't the main issue it was latency. We have to be very careful with building our objects on the client because all the SQL calls can add up to a real costs in a WAN environment with latency. – Aaron May 01 '09 at 12:40
3

There's a company called Shunra that specializes in this stuff. I don't have any experience with them but they've been around for a while.

Joel Spolsky
  • 3,686
  • 4
  • 21
  • 19
2

DummyNet is a free piece of software that can be used to simulate various network conditions. If you have a spare machine, install FreeBSD and DummyNet, and put it inline between your client and server. You can then tweak DummyNet to vary the latency, jitter and loss that you experience.

EDIT: just re-read the question and realised you don't own your network. In this case, configure DummyNet on a machine that has two NICs, and turn it into a router that has your corporate WAN on one side and your workstation on the other. Just be sure to speak to your IT department first to make sure that they don't have any issues with you doing this!

Murali Suriar
  • 10,166
  • 8
  • 40
  • 62
2

lagfactory

Wraps tc to provide random unreliable network behaviour.

1

I bet you could build a Fiddler plugin to simulate something like this, but I don't know a solution out of the box.

jj33
  • 11,038
  • 1
  • 36
  • 50