Using Wanem to simulate a wide-area network

If you (or your company) are in the web-development business, one thing you need when testing your application, besides trying it in different browsers, is trying the user experience at differents conenction speed.

This can be achieved easily with Wanen, a live CD that enables you to create a gateway for your test computer which slows down (or intruduces errors, jitters, random disconnections) the network experience. Wanem uses the almighty iproute2 tools (more in details, tc) to accomplish its tasks.

The easiest way is to try Wanem is to boot it in a virtual environment (for example, VMWare Server, for easy management). Its use is quite straightforward, so I won’t nag you here and I’ll just invite you to read the documentation the project provides, but I let you know a couple of things/errors I found while using it (I’m going to report them to the developers as well)

  • The remote administration interface, which is basically a web page, it’s so bad written HTML that onlky works with Internet Explorer 6. Firefox will render a completely useless mess instead of the simple, plain HTML table that is supposed to be. I can’t understand how is this still possible in 2007 from people using Linux (it’s a Knoppix-based live cd!). So, be careful with the advanced settings.
  • Even if you specify a static IP address on startup (in the end it’s meant as a gateway, so DHCP is almost useless), there’ll always be a “pump” (DHCP client) process active in memory, resetting your IP from time to time, if you are in a DHCP’ed environment. To solve this, you have to do a couple of tricks because by default Wanem only gives you access to a limited control shell.
    So, acces Wanem from a remote ssh with these options:

    ssh perc@$WANEM_IP -t /bin/bash

    and enter the password you created at boot time. Now you’re in the live cd and you may try to kill the pump process. But you can’t since you don’t have enough permissions! And sudo/su ask you an inexistent root password. The solution is the “dosu” executable found in the home you’ve just entered. Resuming:

    dosu killall pump
Advertisements

6 thoughts on “Using Wanem to simulate a wide-area network

  1. Thank you for the info :) What about the pump problem? (probably it would be better to file a bug in SF but I simply hate SF bugzilla…)
    And thank you for creating Wanem, it’s a nice tool!

  2. There is an exit2shell command in the WANem console which will take you to the UNIX shell. The same “kill pump” command can be issued there.

    In a DHCP environment I agree that it is possible to have IP addresses reset from time to time. So far in my experience it hasnt been much of a problem. I guess it depends on when the IP lease expires – which may differ from place to place. In practice I have seen even DHCP IP addresses to be sticky – once you an IP assigned to a MAC you almost always get the same one again.

  3. @Spencer: it forces the specified remote shell when opening the connection, thus not using the default one for that user (as normally specified in /etc/passwd).
    To be honest I don’t know if you can pass this option to PuTTY (I’ve never used it too much) but, if you need a powerful ssh client (and tons of other *nix tools) and you don’t mind the overhead, you can try CygWin32.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s