Skip to content

Collection of scripts, which can be used to further automate moonsniff post processing and measurements

License

Notifications You must be signed in to change notification settings

AP-Frank/MoonSniff-scripts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MoonSniff Scripts

This is repository is a collection of scripts which can help to automate/visualize output from MoonSniff which is part of MoonGen. For general information about MoonSniff look here.

The scripts provided should be seen as starting point/inspiration for your own scripts.

Bash scripts

The Bash scripts help to automate measurement series. A series consists of latency measurements of constant time for different data-rates. The bash scripts can be found in the bash/ directory.

Each series has the following properties:

  • Start rate (e.g. 1 Gbit/s)
  • End rate (e.g. 3 Gbit/s)
  • Step size (e.g. 1 Gbit/s)
  • Duration (e.g. 30 seconds)

This would result in 3 measurements taking 30 seconds each.

The configuration of those scripts is done within the configuration.sh file. All configuration options are also explained within this file.

The main scripts, which the user should execute, are the moonsniff-combined-series.sh and the moonsniff-complete-test.sh scripts. The difference between both scripts is, that the first one measures once, does post-processing afterward and repeats until all measurements are done. The second one does all measurements firsts and then continues with the post-processing.

Typically as file sizes get big really fast the first option is more useful, because with the PROCESSOR_DELETE option set to true it can delete the raw files after each measurement, so that only the current file takes up space.

Important: The scripts open an SSH connection to the sniffer as well as to the traffic generators. You may need to modify the scripts if you need SSH-Keys.

Python scripts

The python scripts are meant to visualize the results generated by MoonSniff, especially those generated by the Bash scripts. The scripts can be found in the python/ directory.

Using the python scripts

In order to execute the scripts you need Python 3 with the matplotlib and the numpy modules set up. The script can be executed by providing all mandatory parameters.

python3 hist-interpreter.py --begin 1000 --end 2000 --step_size 1000 --bucket_size 1
  • begin: The rate to start with [Mbit/s]
  • end: The rate to end with [Mbit/s]
  • step_size: Added to begin until end is reached [Mbit/s]
  • bucket_size: MoonSniff uses buckets for its histograms. The size of a bucket is given in nanoseconds.

The script searches for input files within its working directory.

Example working directory:

hist-1000.csv
hist-2000.csv
measurement-rate-1000-stats.csv
measurement-rate-2000-stats.csv

Naming Conventions

  • Histograms need to follow the naming convention: <name>-<rate>.csv, where <name> is the common part of all file names generated by MoonSniff's post-processing and <rate> is the rate which was measured.
  • Statistics files need to follow the following convention: <stat-name>-<rate>-stats.csv, where <stat-name> is the common part of all statistic files which are generated by MoonSniff's Sniffer. <rate> is the rate which was measured.

Note: The <rate> values are important as they are used to match statistics with the corresponding histogram files. When using the provided bash scripts, all naming conventions are met by default.

About

Collection of scripts, which can be used to further automate moonsniff post processing and measurements

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published