13
votes

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?

1
  • What environment are you using? There are various things you can do with the network stack if you are using Linux ... May 2, 2009 at 19:53

6 Answers 6

6
votes

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

1
  • 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 1, 2009 at 12:40
7
votes

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.

3
votes

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.

2
votes

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!

2
votes

lagfactory

Wraps tc to provide random unreliable network behaviour.

1
vote

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

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .