Configuration

Mini-NDN uses a configuration file describing the topology and its parameters to setup a network. It can be generated by the GUI or written by hand or scripts.

Configuration file format:

The [nodes] section:

At the bare minimum, the node section describes the nodes present in the topology.

[nodes]
a: _
b: _

Additionally each node can take the following parameters:

  • app : Default application(s) to be started on a node (specify ‘_’ if no app needs to be started - required). The app is the only parameter which needs double quotes (see example below).

  • cpu : Amount of cpu available to a node (0.00 - 1.00), optional

  • mem : Amount of memory available to a node in KB

  • cache : Amount of cache memory available to a node in KB

    e.g.)

    [nodes] a: _ cpu=0.3 b: app=”sample app 1; sampleapp2.sh” cpu=0.3

One can also specify log levels for each node’s NFD and NLSR:

[nodes]
a: _ nfd-log-level=DEBUG nlsr-log-level=DEBUG
b: _ nfd-log-level=INFO

To specify for log level for certain modules of NFD, directly modify /usr/loca/etc/ndn/nfd.conf, such as:

default_level NONE

; You may override default_level by assigning a logging level
; to the desired module name. Module names can be found in two ways:
;
; Run:
;   nfd --modules
;
; Or look for NFD_LOG_INIT(<module name>) statements in source files.
; Note that the "nfd." prefix can be omitted.
;
; Example module-level settings:
;
; FibManager DEBUG
Forwarder INFO

This will turn on FORWARDER logging to INFO for all nodes.

Example configuration file

[nodes]
a: _ cpu=0.3
b: app="sampleApp1; ./sampleApp2.sh" cpu=0.3
[links]
a:b delay=10ms bw=100

Note that sampleApp1 and sampleApp2 must be either installed in the system (ex: /usr/bin) or an absolute path needs to be given.

See ndn_utils/topologies for more sample files