doc:updated CORE manual

This commit is contained in:
tgoff0 2015-05-22 00:56:29 +00:00
parent 5838814f07
commit e678c5231b
12 changed files with 201 additions and 146 deletions

View file

@ -40,12 +40,22 @@ emulates layers 1 and 2 (physical and data link) using its pluggable PHY and
MAC models.
The interface between CORE and EMANE is a TAP device. CORE builds the virtual
node using Linux network namespaces, and installs the TAP device into the
namespace. EMANE binds a userspace socket to the device, on the host before it
is pushed into the namespace, for sending and receiving data. The *Virtual
Transport* is the EMANE component responsible for connecting with the TAP
device.
node using Linux network namespaces, installs the TAP device into the
namespace and instantiates one EMANE process in the namespace.
The EMANE process binds a user space socket to the TAP device for
sending and receiving data from CORE.
.. NOTE::
When the installed EMANE version is older than 0.9.2, EMANE runs on the host
and binds a userspace socket to the TAP device, before it is pushed into the
namespace, for sending and receiving data. The *Virtual Transport* was
the EMANE component responsible for connecting with the TAP device.
An EMANE instance sends and receives OTA traffic to and from other
EMANE instances via a control port (e.g. ``ctrl0``, ``ctrl1``).
It also sends and receives Events to and from the Event Service using
the same or a different control port.
EMANE models are configured through CORE's WLAN configuration dialog. A
corresponding EmaneModel Python class is sub-classed for each supported EMANE
model, to provide configuration items and their mapping to XML files. This way
@ -135,9 +145,16 @@ Single PC with EMANE
This section describes running CORE and EMANE on a single machine. This is the
default mode of operation when building an EMANE network with CORE. The OTA
manager interface is off and the virtual nodes use the loopback device for
communicating with one another. This prevents your emulation session from
sending data on your local network and interfering with other EMANE users.
manager and Event service interface are set to use ``ctrl0`` and the virtual nodes
use the primary control channel for communicating with one another. The primary
control channel is automatically activated when a scenario involves EMANE.
Using the primary control channel prevents your emulation session from sending
multicast traffic on your local network and interfering with other EMANE users.
.. NOTE::
When the installed EMANE version is earlier than 0.9.2, the OTA manager and
Event service interfaces are set to use the loopback device.
EMANE is configured through a WLAN node, because it is all about emulating
wireless radio networks. Once a node is linked to a WLAN cloud configured with
@ -197,23 +214,33 @@ be used to achieve geo-location accuracy in this situation.
Clicking the green *Start* button launches the emulation and causes TAP
devices to be created in the virtual nodes that are linked to the EMANE WLAN.
These devices appear with interface names such as eth0, eth1, etc. The EMANE
daemons should now be running on the host:
processes should now be running in each namespace. For a four node scenario:
::
> ps -aef | grep emane
root 10472 1 1 12:57 ? 00:00:00 emane --logl 0 platform.xml
root 10526 1 1 12:57 ? 00:00:00 emanetransportd --logl 0 tr
The above example shows the *emane* and *emanetransportd* daemons started by
CORE. To view the configuration generated by CORE, look in the
> ps -aef | grep emane
root 1063 969 0 11:46 ? 00:00:00 emane -d --logl 3 -r -f /tmp/pycore.59992/emane4.log /tmp/pycore.59992/platform4.xml
root 1117 959 0 11:46 ? 00:00:00 emane -d --logl 3 -r -f /tmp/pycore.59992/emane2.log /tmp/pycore.59992/platform2.xml
root 1179 942 0 11:46 ? 00:00:00 emane -d --logl 3 -r -f /tmp/pycore.59992/emane1.log /tmp/pycore.59992/platform1.xml
root 1239 979 0 11:46 ? 00:00:00 emane -d --logl 3 -r -f /tmp/pycore.59992/emane5.log /tmp/pycore.59992/platform5.xml
The example above shows the EMANE processes started by CORE. To view the configuration generated by CORE, look in the
:file:`/tmp/pycore.nnnnn/` session directory for a :file:`platform.xml` file
and other XML files. One easy way to view this information is by
double-clicking one of the virtual nodes, and typing *cd ..* in the shell to go
up to the session directory.
When EMANE is used to network together CORE nodes, no Ethernet bridging device
is used. The Virtual Transport creates a TAP device that is installed into the
network namespace container, so no corresponding device is visible on the host.
.. _single_pc_emane_figure:
.. figure:: figures/single-pc-emane.*
:alt: Single PC Emane
:align: center
:scale: 75%
Single PC with EMANE
.. index:: Distributed_EMANE
.. _Distributed_EMANE:
@ -226,15 +253,19 @@ Running CORE and EMANE distributed among two or more emulation servers is
similar to running on a single machine. There are a few key configuration items
that need to be set in order to be successful, and those are outlined here.
Because EMANE uses a multicast channel to disseminate data to all NEMs, it is
a good idea to maintain separate networks for data and control. The control
network may be a shared laboratory network, for example, but you do not want
multicast traffic on the data network to interfere with other EMANE users.
The examples described here will use *eth0* as a control interface
It is a good idea to maintain separate networks for data (OTA) and control. The control
network may be a shared laboratory network, for example, and you do not want
multicast traffic on the data network to interfere with other EMANE users. Furthermore,
control traffic could interfere with the OTA latency and thoughput and might affect
emulation fidelity. The examples described here will use *eth0* as a control interface
and *eth1* as a data interface, although using separate interfaces
is not strictly required. Note that these interface names refer to interfaces
present on the host machine, not virtual interfaces within a node.
.. IMPORTANT::
If an auxiliary control network is used, an interface on the host has to be assigned to that network.
See :ref:`Distributed_Control_Network`
Each machine that will act as an emulation server needs to have CORE and EMANE
installed. Refer to the :ref:`Distributed_Emulation` section for configuring
CORE.
@ -255,15 +286,35 @@ turn connects to the other emulation server "slaves". Public key SSH should
be configured from the master to the slaves as mentioned in the
:ref:`Distributed_Emulation` section.
The EMANE models can be configured as described in :ref:`Single_PC_with_EMANE`.
Under the *EMANE* tab of the EMANE WLAN, click on the *EMANE options* button.
This brings
up the emane configuration dialog. The *enable OTA Manager channel* should
be set to *on*. The *OTA Manager device* and *Event Service device* should
be set to something other than the loopback *lo* device. For example, if eth0
is your control device and eth1 is for data, set the OTA Manager device to eth1
and the Event Service device to eth0. Click *Apply* to
save these settings.
be set to a control network device. For example, if you have
a primary and auxiliary control network (i.e. controlnet and controlnet1), and you want
the OTA traffic to have its dedicated network, set the OTA Manager device to ``ctrl1``
and the Event Service device to ``ctrl0``.
The EMANE models can be configured as described in :ref:`Single_PC_with_EMANE`.
Click *Apply* to save these settings.
.. _distributed_emane_figure:
.. figure:: figures/distributed-emane-configuration.*
:alt: Distribute EMANE
:align: center
:scale: 75%
Distributed EMANE Configuration
.. NOTE::
When the installed EMANE version is earlier than 0.9.2, EMANE access to the host machine's
interfaces and OTA manager and Event service devices an be set to physical interfaces.
.. HINT::
Here is a quick checklist for distributed emulation with EMANE.
@ -287,12 +338,9 @@ file and other EMANE XML files are generated. The NEM IDs are automatically
coordinated across servers so there is no overlap. Each server also gets its
own Platform ID.
Instead of using the loopback device for disseminating multicast
EMANE events, an Ethernet device is used as specified in the
*configure emane* dialog.
EMANE's Event Service can be run with mobility or pathloss scripts
as described in
:ref:`Single_PC_with_EMANE`. If CORE is not subscribed to location events, it
An Ethernet device is used for disseminating multicast EMANE events, as specified in the
*configure emane* dialog. EMANE's Event Service can be run with mobility or pathloss scripts
as described in :ref:`Single_PC_with_EMANE`. If CORE is not subscribed to location events, it
will generate them as nodes are moved on the canvas.
Double-clicking on a node during runtime will cause the GUI to attempt to SSH
@ -301,3 +349,11 @@ key SSH configuration should be tested with all emulation servers prior to
starting the emulation.
.. _distributed_emane_network_diagram:
.. figure:: figures/distributed-emane-network.*
:alt: Distribute EMANE
:align: center
:scale: 75%
Notional Distributed EMANE Network Diagram