As part of a broader organisational restructure, data networking research at Swinburne University of Technology has moved from the Centre for Advanced Internet Architecture (CAIA) to the Internet For Things (I4T) Research Lab.

Although CAIA no longer exists, this website reflects CAIA's activities and outputs between March 2002 and February 2017, and is being maintained as a service to the broader data networking research community.

TCP Experiment Automation Controlled Using Python (TEACUP) -- Architecture

ARCHITECTURE

This section contains a brief overview about TEACUP's architecture, and how to extend TEACUP with new functionality. More details (for TEACUP version 0.9) can be found in this technical report.

TEACUP Building Blocks

The implementation of TEACUP is based on Fabric. It is designed based on multiple small tasks that are (1) combined to run an experiment or a series of experiments but (2) some may also be executed directly from the command line. Functions which are not tasks are ordinary Python functions. Currently, we do not make use of the object-oriented capabilities of Python.

The figure below shows the main functional building blocks. All the blocks in the diagram have corresponding Python files. However, we have summarised a number of Python files in the helper_functions block. The fabfile block is the entry point for the user. It implements tasks for running a single experiment or running a series of similar experiments with different parameters. The fabfile block also provides access to all other tasks via imports.


The experiment block implements the main function that controls a single experiment and uses a number of functions of other blocks. The sanity_checks block implements functions to check the config file, the presence of tools on the hosts, the connectivity between hosts, and a function to kill old processes that are still running. The host_setup block implements all functions to setup networking on the testbed hosts (this includes basic setup of the testbed router). The router_setup block implements the functions that set up the queues on the router and the delay/loss emulation. The loggers block implements the start and stop functions of the loggers, such as tcpdump and SIFTR/web10g loggers. The traffic_gens block implements the start and stop functions of all traffic generators.

The util block contains utility tasks that can be executed from the command line, such as executing a command on a number of testbed hosts or copying a file to a number of testbed hosts. The analysis block contains all the post-processing functions that extract measurement metrics from log files and plot graphs.

Extending TEACUP

Additional host setup

Any general host setup (e.g. sysctl settings for all experiments) should be added in the init_host tasks in hostsetup. Note that in this function there are three different sections, one for each OS (FreeBSD, Linux, Windows/Cygwin, MacOS X). Commands that shall only be executed in certain experiments can be set in the config (TPCONF_host_init_custom_cmds).

New TCP congestion control algorithm

Adding support for a new TCP congestion control algorithm requires to modify the init_cc_algo task in hostsetup. The new algorithm needs to be added to the list of supported algorithms and in the OS-specific sections code need to be added to load the corresponding kernel module (if any).

New traffic generator

Adding a new traffic generator requires to add a new start task in trafficgens. The current start tasks always consist of two methods, the actual start method is a wrapper around an internal _start method. This is to have the host on which the generator is started as explicit parameter (and not as Fabric hosts parameter) and this also allows to have multiple traffic generators that actually use the same underlying tool (for example this is the case for httperf). The new start method must be added to the imports in experiment.

New data logger

To add a new data logger a start method and possibly a stop method need to be added in loggers. The new logger's start method should be called from the start_loggers task in loggers via Fabric's execute(), but could also be called from experiment if required (in the latter case it must be added to the imports in experiment).

New analysis method

To add a new analysis method, add an analysis task in analysis. If the new analysis should be carried out as part of the analyse_all task, the new task must be called from analyse_all via Fabrics execute() function. The new task should implement the parameters test_id, out_dir, pdf_dir, out_name, replot_only, source_filter and min_values (see existing analyse tasks as examples). The new task must be added to the imports in fabfile.

Future Work

The initial design of TEACUP was ad-hoc and TEACUP has organically grown for more than 15 months. Our plan is to eventually change TEACUP to a more modular and more easily extensible structure using the object-oriented capabilities of Python.


Last Updated: Wednesday 17-Jun-2015 12:13:57 AEST | No longer maintained. Pre-2018 was maintained and authorised by Grenville Armitage, garmitage@swin.edu.au