Commit f5b81d1a authored by Mike Hibler's avatar Mike Hibler
Browse files

Add IXP documentation from Abhijeet

parent ecda7f61
<!--
EMULAB-COPYRIGHT
Copyright (c) 2000-2003 University of Utah and the Flux Group.
All rights reserved.
-->
<center>
<h1>Integration of Intel IXP network processors</h1>
</center>
The IXP1200 network processor is now integrated into Emulab, and
available to external researchers for remote experimentation.
Similar to other emulab resources, an IXP1200 node can
be allocated through an ns script or through the Netbuild GUI.
It can be configured as part of any arbitrary topology with end-nodes,
traffic generators, routers, links etc. This makes it easy to
allocate, experiment with, and evaluate an IXP based application.
<p>
Currently, we have installed 4 ENP2505 cards (aka Bridalveil), with
Intel SDK 2.01 software. We soon plan to incorporate more IXP1200
nodes as we make space in our machine room, and also IXP2400 cards as
we get them from Intel.
<h2>Contents</h2>
<ul>
<li> <a href="#GettingStarted">Getting Started in Emulab</a>
<li> <a href="#Creating">Creating an IXP1200 experiment</a>
<ul>
<li> <a href="#ns">Using ns file</a>
<li> <a href="#Netbuild">Using Netbuild</a>
</ul>
<li> <a href="#CustomApp">Running your custom application on the IXP1200</a>
<ul>
<li> <a href="#startupcmd">Startup command</a>
<li> <a href="#samplecmd">A Sample Startup command</a>
</ul>
<li> <a href="#testexpt">Test Experiment to get started using IXP1200 in Emulab</a>
<li> <a href="#nodeusage">Node usage policies</a>
<li> <a href="#notes">Setup Notes</a>
</ul>
<hr>
<a NAME="GettingStarted"></a>
<center>
<h2>Getting Started in Emulab</h2>
</center>
<p>
To start using IXP nodes in Emulab, you would first need an account
in Emulab. See <a href="http://www.emulab.net/doc.php3">
Emulab Documentation </a> for more details; especially if you are
using Emulab for the first time.
</p>
<hr>
<a NAME="Creating"></a>
<center>
<h2>Creating an IXP1200 experiment</h2>
</center>
An IXP1200 node can be allocated in an experiment in two ways:
using an ns script or through a Java GUI called Netbuild.
<ul>
<li> <a href="#ns">Using ns file</a>
<li> <a href="#Netbuild">Using Netbuild</a>
</ul>
<ul>
<a NAME="ns"></a>
<li> <h3>Using ns file</h3>
<p>
Here's a sample ns file, which allocates an IXP1200 node and two
end-nodes connected in a simple linear topology.
<code><pre>
source tb_compat.tcl
set ns [new Simulator]
#Create an ixp node
set myixp [$ns node]
#set its type to ixp-bv hardware
tb-set-hardware $myixp ixp-bv
#Create the host which houses the IXP card
set myixphost [$ns node]
# Set the host and ixp association
tb-bind-parent $myixp $myixphost
# Create end nodes
set n0 [$ns node]
set n1 [$ns node]
#Create links between the end nodes and the IXP
$ns duplex-link $myixp $n0 100Mb 0ms DropTail
$ns duplex-link $myixp $n1 100Mb 0ms DropTail
#set up static routing on all nodes
$ns rtproto Static
$ns run
</pre></code>
When the above ns file is submitted, Emulab creates an experiment with
the requested nodes, creates the topology specified above, and does
the following:
<ul>
<li>Routes are automatically generated between all nodes; interface
configuration information like IP addresses is generated for the
IXP interfaces as well as other nodes. Emulab uses this to
create config files for the Intel L3Fwdr reference design
(route.l3fwdr, ixsys.l3fwdr) as a sample. The user can run this
application to get familiar with the MicroAce architecture,
and also to understand how the IXPs are set up in Emulab.
<p>
<li>The IXP card control interface (pci/eth interface) is set up, and
the card is reachable/can reach the outside world through the host.
<p>
<li> An experimenter's project directory (/proj/$projectid) and the
SDK 2.01 workspace (/opt) are mounted on the card.
<p>
<li> Hosts file, dns resolver files are automatically set up.
<p>
<li>The experimenter can login to the card and run the l3fwdr
application as a test application to see how things are set
up. To login to the card, ssh into the IXP host.
You can then either telnet to the card or access the card console
from the IXP host. The linux on the card has just a root account
with no password.
<p>
<ul>
<li>To telnet to the card, run
<p>
<code><pre>
telnet myixp.myexp.myproj.emulab.net
</code></pre>
<p>
where myixp is the name of your
ixp card in your ns file, myexp is your experiment name and
myproj is your project name.
<p>
<li>To access the card's console, do
<p>
<code><pre>
sudo minicom ixp
</code></pre>
</ul>
<p>
Once logged into the card, do the following:
<p>
<code><pre>
cd /opt/ixasdk/bin/arm-be
./ixstart /opt/config/ixsys.l3fwdr
</code></pre>
<p>
This will start up the reference L3Fwdr application on the card.
You can then ping the end-nodes through the IXP router, or ping the
end-nodes from the IXP.
</ul>
</p>
<a NAME="Netbuild"></a>
<li> <h3>Using Netbuild</h3>
<p>
You can use <a href="https://www.emulab.net/buildui/bui.php3">Netbuild </a>, a Java GUI, for creating your experiment
topology. See <a
href="http://www.emulab.net/doc/docwrapper.php3?docname=netbuilddoc.html">
Netbuild Documentation </a> for details. When setting the type of the
IXP node, use ixp-bv.
</p>
<p>
</ul>
More complicated topologies with LANs, emulated links, routers etc.,
can be similarly created to test your IXP based application,
using either an ns file or Netbuild.
<hr>
<a NAME="CustomApp"></a>
<center>
<h2>Running your custom application on the IXP1200</h2>
</center>
Typically, an experimenter will write his/her own
application, and evaluate it inside Emulab. Once you have done some
basic testing of your application, you can automate its startup in
your experiment. To do this, Emulab supports startup commands which
are run on the card on bootup.
<ul>
<li> <a href="#startupcmd">Startup Commands</a>
<li> <a href="#samplecmd">A sample Startup Command</a>
</ul>
<ul>
<a NAME="startupcmd"></a>
<li> <h3>Startup Commands</h3>
<p>
Your ns script can include this:
<p>
<code<pre>
tb-set-node-startup $myixp "/opt/ixasdk/bin/arm-be/mycustomapp /opt/ixasdk/bin/arm-be/mycustomapp.config"
</code></pre>
<p>
This will start up the above command line on the IXP1200 card after
the card has booted up. To create a config file for your custom
application, you might need access to interface/route configuration that
Emulab has generated. This information is stored by Emulab in a file
whose path is exported on the card in the environment variable $USERCONFIG.
<p>
The $USERCONFIG file has interface/route configuration lines with the
following format:
<p>
<code><pre>
# interface number IP Netmask Broadcast Mac
interface 0 10.1.2.2 10.1.2.255 255.255.255.0 00:00:AC:11:AC:00
<p>
# route destination netmask gateway interface-number
route 10.1.2.2 255.255.255.0 0.0.0.0 0
</code></pre>
<p>
This format is deliberatly similar to the format used by MicroAce
config files. This information can be used by your startup command to
generate config files on the fly and then invoke your custom
application with the generated config files.
<p>
For example, consider an application which does routing (using
the Intel L3Fwdr reference design) and adds its own functionality like
Filtering. Your startup command can use the emulab config file to
generate the route config files, then invoke your application with
these config files. Your application (for example ixconfig) in turn
will configure all the MicroAces, download code to the microengines
etc.
<p>
<a NAME="samplecmd"></a>
<li> <h3>A sample Startup Command</h3>
Emulab creates route config files which are exported on
the card in /opt/config/ixsys.l3fwdr and /opt/config/route.l3fwdr.
You can try the following startup command in an experiment.
<p>
<code><pre>
tb-set-node-startup $myixp "/opt/ixasdk/bin/arm-be/ixstart /opt/config/ixsys.l3fwdr"
</code></pre>
<p>
This will initialize and download Intel's L3Fwdr Reference design to
the microengines.
</ul>
<!-- Startup commands can be set up in the ns file, or added later by
editing the node info for the IXP node and rebooting the IXP host.-->
<hr>
<a NAME="testexpt"></a>
<center>
<h2>Test Experiment to get started</h2>
</center>
Before creating your own topologies, its advisable to try the
following first, to get familiar with IXP configuration inside
Emulab.
<ul>
<li> Use the above sample ns file to create an experiment. Log into the
IXP node, then manually start the L3fwdr application.
<p>
<code><pre>
cd /opt/ixasdk/bin/arm-be
./ixstart /opt/config/ixsys.l3fwdr
</code></pre>
<p>
Test the application by using ping between the end-nodes.
<p>
<li> Add a startup command for the IXP node. Once an experiment is
already created, you can still add a startup command by editing a
node's information. From your experiment webpage, click on the
ixp node in the Node ID column. Then click "Edit Node Info" in
the Node Options table. Add the following startup command in
the "Startup Command" entry in the form.
<p>
<code><pre>
/opt/ixasdk/bin/arm-be/ixstart /opt/config/ixsys.l3fwdr
</code></pre>
<p>
Then reboot the IXP host, this time you do not have to manually start
the routing application, it is started automatically by Emulab. Again
try pinging between end-nodes to see if the application works.
</ul>
<p>
Once you are familiar with how the IXP1200 is set up inside Emulab,
you could try richer topologies and your own startup commands.
<hr>
<a NAME="nodeusage"></a>
<center>
<h2>Node Usage Policies</h2>
</center>
Emulab has certain <a
href="http://www.emulab.net/docwrapper.php3?docname=swapping.html">
Node Usage Policies</a> to facilitate sharing of resources among
experimenters. Since we have limited number of boards available,
please use resources in accordance with these policies.
<hr>
<a NAME="notes"></a>
<center>
<h2>Setup Notes</h2>
</center>
<ul>
<li> Two filespaces are mounted on the card (on the linux on the StrongArm): your project directories are
mounted on the card at /proj/$projectid, and the Intel SDK 2.01 is
mounted at /opt. Files that you create in /proj/$projectid survive
across experiments and swapouts of the same experiment. Files in /opt
are lost across experiments and swapouts. So typically, you would
want to save your code (MicroAces, apps etc) in /proj/$projectid.
Look at the following FAQ entry, <a
href="http://www.emulab.net/docwrapper.php3?docname=faq.html#UTT-5">Where
do I store files needed by my experiment? </a> for details.
<p>
<li> Currently, Windows developer workbench is not supported. So you would
have to compile your microcode on your windows machine, then copy it
over to the card. You cannot use the windows based debugger.
However printf's equivalent method of debugging works fine; your
microcode can write debug information to Scratch memory and an
application on the StrongArm can read and print it. This is a
useful debugging technique.
</ul>
......@@ -40,6 +40,9 @@
<li> <a href="docwrapper.php3?docname=vnodes.html">
Multiplexed Virtual Nodes</a>
<img src="../new.gif" alt="&lt;NEW&gt;">
<li> <a href="docwrapper.php3?docname=ixp.html">
Using IXP network processors</a>
<img src="../new.gif" alt="&lt;NEW&gt;">
</ul>
<li> <a href="#BatchMode">Batch Mode Experiments</a>
<li> <a href="#CustomOS">Creating your own disk image</a>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment