Code Monkey home page Code Monkey logo

fs's Introduction

FS: a network flow record generator

FS is a network flow record generator. It contains a discrete event simulation core to generate the flow records, and relies on existing TCP throughput models to drive the simulation.

FS is made available under terms of the GPLv2.

Note: the originally released version of fs as described in an INFOCOM '11 research paper (see http://dx.doi.org/10.1109/INFCOM.2011.5935055) is on branch fs-orig. The master branch is completely revamped and includes the fs-sdn code as described in a HotSDN '13 paper (http://dl.acm.org/citation.cfm?id=2491202).

Running fs

FS is implemented in Python and has a few external module dependencies:

To use fs, you need the following Python packages:

  • ipaddr
  • networkx
  • pydot
  • pyparsing
  • pytricia (py-radix is no longer supported)

To install all the above, see the requirements.txt file here and use pip:

$ pip install -r requirements.txt

I'd recommend using virtualenv, then installing the packages inside the venv. See http://pypi.python.org/pypi/virtualenv.

fs runs fastest using pypy (http://pypy.org) but also works well under the standard CPython implementation.

Examples

There are a number of example configuration files in the conf/ directory. To run a couple of the example configuration files for 600 simulated seconds, you might do something like:

$ python -OO fs.py -t 600 conf/ex1.dot
$ python -OO fs.py -t 600 conf/testconf1.json

fs supports a DOT configuration file syntax as well as a (basically equivalent) JSON syntax. For now, config file syntax is undocumented; take a look at the examples and our 2011 INFOCOM paper: http://dx.doi.org/10.1109/INFCOM.2011.5935055

To use the OpenFlow extensions (aka fs-sdn), you'll need to clone the POX git repository and point your PYTHONPATH to it. fs currently is only tested with the betta branch of POX. Once you've done those things, there are two example configurations in the conf folder that should work out-of-the-box:

$ git clone git://github.com/noxrepo/pox.git ../pox
$ export PYTHONPATH=`pwd`/../pox
$ python -OO fs.py -t 60 conf/openflow_small_cbr.dot
$ python -OO fs.py -t 60 conf/openflow_small_harpoon.dot

The first few lines of output from fs when running one of the above example (OpenFlow) configurations should be:

0.0000 fslib.config INFO     Reading config for graph test.
0.0000 fslib.config INFO     Running measurements on these nodes: <a,c,b,controller>
    POX 0.1.0 (betta) / Copyright 2011-2013 James McCauley, et al.
0.0000 fs           INFO     Monkeypatching POX for integration with fs
0.0000 core         INFO     POX 0.1.0 (betta) is up.
0.0000 fs.core      INFO     simulation completion: 0.00
0.0600 openflow.of_01 INFO     [00-02-e4-0d-b1-e0 1] connected
0.0600 openflow.of_01 INFO     [00-02-f3-4f-f4-e2 2] connected
0.0600 openflow.of_01 INFO     [00-02-eb-ae-d3-63 3] connected

Acknowledgments

This software is based up on work supported by the National Science Foundation under Grant No. CNS-1054985. Any opinions, findings, and conclusions or recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of the National Science Foundation.


Copyright 2011-2013 Joel Sommers. All rights reserved.

This file is part of fs, a network flow record generation tool.

fs is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

fs is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with fs; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA

fs's People

Contributors

jsommers avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

fs's Issues

What's the flow export format?

Hi,I am using your simulation tools.But I can't understand the format of the flow export files.For example,what's the meaning of each column of the following line?
textexport a 0.016469 0.016469 0.321625 10.1.0.1:22->10.3.1.1:25833 tcp 0x0 harpoon:172.16.0.1 5 4373 FSA
I am looking forward to your reply as soon as possible.

Question about the counters

I noticed something interesting about the counters when playing with fs-sdn when executing that simpler version of openflow_small_cbr.dot.

It uses the learning switch application and sends traffic from switch A that goes through B and ends in C. Every interfaces can forward 10Mpbs.
The udp traffic starts at 5s and an additional flow of 10Mb is sent every second.

The interesting thing is that in the A counters I can see the flows leaving every seconds, but the first flow only reaches B at 7s and C at 8s. In a scenario without congestion and no queue delay, or competing flows, at 10Mbps, the time to reach should not be near 6s? (Approximately the time it takes to be transmitted to switch A, considering that the next switch starts to transmit as soon as the first packet reaches it).

A counters
5.000 simple->a 1250000 bytes 826 pkts 1 flows
7.000 simple->a 1250000 bytes 826 pkts 1 flows
8.000 simple->a 1250000 bytes 826 pkts 1 flows

B counters
7.000 a->b 1250000 bytes 826 pkts 1 flows
9.000 a->b 1250000 bytes 826 pkts 1 flows

C counters
8.000 b->c 1250000 bytes 826 pkts 1 flows
10.000 b->c 1250000 bytes 826 pkts 1 flows

Looking in the code

wait = self.delay + flowlet.size / self.capacity

The waiting time is calculated that way, which means for the flow size sent, the wait is going to be 1s, which explains the difference in the interval between different switches. Is it a known problem or is it related to the way traffic is being generated? (Considering the importance of the traffic generator to it).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.