blob: 5bc9b263231e1e8efc00c4b4766c9a27a5dade13 [file] [log] [blame] [view]
Davide Pesavento2a7f32b2017-09-02 13:48:13 -04001Traffic Generator for NDN (ndn-traffic-generator)
Alexander Afanasyevfda32a32014-03-20 10:50:00 -07002=================================================
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -08003
Davide Pesavento2a7f32b2017-09-02 13:48:13 -04004[![Build Status](https://travis-ci.org/named-data/ndn-traffic-generator.svg?branch=master)](https://travis-ci.org/named-data/ndn-traffic-generator)
5
jeraldabraham420dbf02014-04-25 22:58:31 -07006This tool is designed to generate Interest and Data traffic in an NDN network.
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -08007The client and server tool accept traffic configuration files which can be
8used to specify the pattern of NDN traffic that is required to be generated.
Alexander Afanasyevfda32a32014-03-20 10:50:00 -07009Sample configuration files are provided which include instructions on how
10to configure various parameters.
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080011
Alexander Afanasyevfda32a32014-03-20 10:50:00 -070012## Prerequisites ##
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080013
Alexander Afanasyevfda32a32014-03-20 10:50:00 -070014Compiling and running ndn-traffic-generator requires the following dependencies:
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080015
Davide Pesavento29db0fd2017-08-29 13:32:00 -0400161. ndn-cxx library <https://github.com/named-data/ndn-cxx>
Alexander Afanasyevfda32a32014-03-20 10:50:00 -070017
Davide Pesavento29db0fd2017-08-29 13:32:00 -040018 For detailed installation instructions, please see
19 [`INSTALL.rst`](https://github.com/named-data/ndn-cxx/blob/master/docs/INSTALL.rst)
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080020
Davide Pesavento29db0fd2017-08-29 13:32:00 -0400212. NDN forwarding daemon <https://github.com/named-data/NFD>
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080022
23-----------------------------------------------------
24
Davide Pesavento2a7f32b2017-09-02 13:48:13 -040025## 1. Compilation & Installation Instructions: ##
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080026
Alexander Afanasyevfda32a32014-03-20 10:50:00 -070027 ./waf configure
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080028 ./waf
29 sudo ./waf install
30
Davide Pesavento2a7f32b2017-09-02 13:48:13 -040031
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080032## 2. Tool Run Instructions & Command Line Options: ##
33
Davide Pesavento35185332019-01-14 04:00:15 -050034 Usage: ndn-traffic-server [options] <Traffic_Configuration_File>
35 Respond to Interests as per provided Traffic_Configuration_File.
jeraldabraham420dbf02014-04-25 22:58:31 -070036 Multiple prefixes can be configured for handling.
Davide Pesavento35185332019-01-14 04:00:15 -050037 Set the environment variable NDN_TRAFFIC_LOGFOLDER to redirect output to a log file.
38 Options:
39 -h [ --help ] print this help message and exit
40 -c [ --count ] arg maximum number of Interests to respond to
41 -d [ --delay ] arg (=0) wait this amount of milliseconds before responding to each Interest
42 -q [ --quiet ] turn off logging of Interest reception/Data generation
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080043
Davide Pesavento35185332019-01-14 04:00:15 -050044 Usage: ndn-traffic [options] <Traffic_Configuration_File>
45 Generate Interest traffic as per provided Traffic_Configuration_File.
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080046 Interests are continuously generated unless a total number is specified.
Davide Pesavento35185332019-01-14 04:00:15 -050047 Set the environment variable NDN_TRAFFIC_LOGFOLDER to redirect output to a log file.
48 Options:
49 -h [ --help ] print this help message and exit
50 -c [ --count ] arg total number of Interests to be generated
51 -i [ --interval ] arg (=1000) Interest generation interval in milliseconds
52 -q [ --quiet ] turn off logging of Interest generation/Data reception
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080053
54
55## 3. Sample Run Instructions ##
56
57__ON MACHINE #1__
58
Davide Pesavento2a7f32b2017-09-02 13:48:13 -040059(NFD must be running)
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080060
Davide Pesavento2a7f32b2017-09-02 13:48:13 -040061Start traffic server:
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080062
Alexander Afanasyevfda32a32014-03-20 10:50:00 -070063 ndn-traffic-server ndn-traffic-server.conf
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080064
65__ON MACHINE #2__
66
Davide Pesavento2a7f32b2017-09-02 13:48:13 -040067(NFD must be running)
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080068
Davide Pesavento2a7f32b2017-09-02 13:48:13 -040069Start the traffic client:
Alexander Afanasyevfda32a32014-03-20 10:50:00 -070070
71 ndn-traffic ndn-traffic-client.conf
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080072
Alexander Afanasyeva8f2a922014-02-26 14:21:56 -080073* These tools need not be used together and can be used individually as well.
Davide Pesavento35185332019-01-14 04:00:15 -050074* Please refer to the sample configuration files provided for details on how to create your own.
75* Use the command line options shown above to adjust traffic configuration.