Example Node Configurations

The following code is an example configuration of a laptop node (short hostname is user-laptop) that was configured with both DTN2 and ION to talk to itself and one other node on the DTNBONE. DTN2 was configured with TCP, ION with UDP.

ION Config File

IMPORTANT!! Code Release ion-2.0_r245_ou710

Check your code release! This example may not be applicable or need modification for other versions (newer or older)

## begin ionadmin

# Initialize and Start
1 1 ""
s

## end ionadmin

## begin bpadmin
#

# Initialize and DTN2 scheme (can't set EID anymore?)
1
a scheme dtn 'dtn2fw' 'dtn2adminep'

# Establish valid endpoints
a endpoint dtn://user-laptop.dtn x
a endpoint dtn://user-laptop.dtn/store q
a endpoint dtn://user-laptop.dtn/temp x
a endpoint dtn://user-laptop.dtn/echo x

# Configure protocols in use
a protocol udp 1400 16

# Add an induct. (listen)
#   Add an induct to accept bundles using udp.
#   Can you tell ION to listen on "all" ie: INADDR_ANY?
a induct udp user-laptop.dtnbone.ocp.ohiou.edu:4556 udpcli

# Add an outduct. (send to anyone via udp)
a outduct udp '*' udpclo

## end bpadmin

## begin dtn2admin

# Set your routes
a plan //user-laptop.dtn x udp/*,user-laptop.dtnbone.ocp.ohiou.edu:4556
a plan //unit017.dtn/ x udp/*,unit017.dtnbone.ocp.ohiou.edu:5017

## end dtn2admin

DTN2 Config File

IMPORTANT!! Code Release dtnd version 2.6.0

Check your code release! This example may not be applicable or need modification for other versions (newer or older)

## DTN2 Configuration

log /dtnd info "dtnd parsing configuration..."

# Settings for the socket based console protocol.
# (this interprets user commands)
#
console set addr 127.0.0.1
console set port 5050

# console set prompt <prompt>
# Set the prompt string.  Helps if running multiple dtnd's
#
set shorthostname [lindex [split [info hostname] .] 0]
console set prompt "$shorthostname dtn% "

# Set the storage system to be used
storage set type berkeleydb
# The server port to connect to (on localhost)
# Note that 62345 has no special significance -- chosen randomly
storage set server_port 62345
# The external data store schema location, which can be
# found in dtn2/oasys/storage/DS.xsd.
storage set schema /etc/DS.xsd

# storage directory
set dbdir "/usr/var/dtn"

# Set the directory to be used for bundle payload files
storage set payloaddir $dbdir/bundles

# Set the database name (appended with .db as the filename in berkeley
# db, used as-is for SQL variants
storage set dbname     DTN

# When using berkeley db, set the directory to be used for the
# database files and the name of the files and error log.
storage set dbdir      $dbdir/db

# Set the algorithm used for dtn routing.
route set type static

# Set the local administrative id of this node.
route local_eid "dtn://[info hostname].dtn"

# Add an input interface to listen on addr:port for incoming bundles
# from other tcp / udp convergence layers
#
interface add tcp0 tcp
#interface add udp0 udp

# link add <name> <nexthop> <type> <clayer> <args...>
# Add a link to a peer node.
link add unit017_link unit017.dtnbone.ocp.ohiou.edu:5017 ONDEMAND tcp

# route add <dest> <link|peer>
# Add a route to the given bundle endpoint id pattern <dest> using the
route add dtn://unit017.dtn/* unit017_link

log /dtnd info "dtnd configuration parsing complete"

## emacs settings to use tcl-mode by default
## Local Variables: ***
## mode:tcl ***
## End: ***

DtnBone/Disconnectathon/ExampleNodeConfigurations (last edited 2009-07-28 15:56:09 by JosephIshac)