README
author Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
Fri, 18 May 2007 18:03:48 +0200
changeset 655 f2ee52034178
parent 643 0d98b6622dfd
child 657 be551a3b07c6
permissions -rw-r--r--
update the documentation section
     1 
     2     The Network Simulator Version 3
     3     -------------------------------
     4 
     5 Table of Content:
     6 -----------------
     7 
     8 1) An Open Source project
     9 2) An overview of the ns-3 project
    10 3) Building ns-3
    11 4) Running ns-3
    12 5) Getting access to the ns-3 documentation
    13 6) Working with the development version of ns-3
    14 
    15 
    16 1) An Open Source project
    17 -------------------------
    18 
    19 ns-3 is an Open Source project and we intend to make this
    20 project a successful collaborative project: we hope that 
    21 the missing pieces of the models we have not yet implemented
    22 will be contributed by the community in an open collaboration
    23 process.
    24 
    25 Contributing to the ns-3 project is still a very informal
    26 process because that process depends heavily on the personality
    27 of the people involved, the amount of time they can invest
    28 and the type of model they want to work on.
    29 
    30 Despite this lack of a formal process, there are a number of 
    31 steps which naturally stem from the open-source roots of the
    32 project. These steps are described in doc/contributing.txt
    33 
    34 2) An overview of the ns-3 project
    35 ----------------------------------
    36 
    37 This package contains the latest version of ns-3 which is aims 
    38 at being a replacement for ns-2. Currently, ns-3 provides a 
    39 number of very simple network simulation models:
    40   - an ipv4 and udp stack
    41   - arp support at the bottom of the stack
    42   - point-to-point physical-layer links
    43   - OnOff traffic generator
    44 
    45 However, the framework is there to make adding new models as 
    46 simple as possible:
    47   - an extensive tracing system can be used to connect
    48     any number of arbitrary trace sources to any number
    49     of trace sinks. This tracing system is decoupled
    50     from the act of serializing the trace events to a 
    51     file: users can and should provide their own
    52     trace handling routines.
    53 
    54   - simple file trace serialization support is included
    55     to both text and pcap files.
    56 
    57   - adding new MAC-level models simply requires subclassing
    58     the pair of classes NetDevice and Channel.
    59 
    60   - adding new traffic generation algorithms is also very 
    61     simple through the Application and the Socket classes.
    62 
    63 3) Building ns-3
    64 ----------------
    65 
    66 The code for the framework and the default models provided
    67 by ns-3 is built as a set of libraries. User simulations
    68 are expected to be written as simple programs which make
    69 use of these ns-3 libraries.
    70 
    71 To build the set of default libraries and the example
    72 programs included in this package, you need to use the
    73 tool 'scons'. Detailed information on how to install
    74 and use scons is included in the file doc/build.txt
    75 
    76 However, the real quick and dirty way to get started is to
    77 type the command "scons" the the directory which contains
    78 this README file. The files built will be copied in the
    79 build-dir/dbg-shared/bin and build-dir/dbg-shared/lib
    80 directories. build-dir/dbg-shared/bin will contain
    81 one binary for each of the sample code in the 'samples'
    82 directory and one binary for each of the detailed examples
    83 found in the 'examples' directory.
    84 
    85 The current codebase is expected to build and run on the
    86 following set of platforms:
    87   - linux x86 gcc 4.2, 4.1, and, 3.4.
    88   - MacOS X ppc and x86
    89 
    90 The current codebase is expected to fail to build on
    91 the following platforms:
    92   - gcc 3.3 and earlier
    93   - optimized builds on linux x86 gcc 4.0 
    94 
    95 Other platforms might or might not work: we welcome 
    96 patches to improve the portability of the code to these
    97 other platforms.
    98 
    99 4) Running ns-3
   100 ---------------
   101 
   102 On Recent Linux systems, once you have built ns-3, it 
   103 should be easy to run the sample programs with the
   104 following command:
   105 
   106 ./build-dir/dbg-shared/bin/simple-p2p
   107 
   108 or:
   109 
   110 cd build-dir/dbg-shared/bin
   111 ./simple-p2p
   112 
   113 That program should generate a simple-p2p.tr text 
   114 trace file and a set of simple-p2p-xx-xx.pcap binary
   115 pcap trace files.
   116 
   117 5) Getting access to the ns-3 documentation
   118 -------------------------------------------
   119 
   120 Once you have verified that your build of ns-3 works by running
   121 the simple-p2p example as outlined in 4) above, it is
   122 quite likely that you will want to get started on reading
   123 some ns-3 documentation. 
   124 
   125 All of that documentation should always be available from
   126 the ns-3 website: http:://www.nsnam.org/ but we
   127 include some of it in this release for ease of use.
   128 
   129 This documentation includes:
   130 
   131   - an architecture document which describes a very 
   132     high-level view of ns-3: it tries to explain the
   133     use-cases the ns-3 developers really focused on when
   134     doing the initial design and then goes on to explain
   135     the structure of the resulting framework.
   136     See the file doc/architecture.pdf
   137 
   138   - a wiki for user-contributed tips: http://www.nsnam.org/wiki/
   139 
   140   - an API documentation generated using doxygen: this is
   141     a reference manual, most likely not very well suited 
   142     as introductory text:
   143     http://www.nsnam.org/doxygen/index.html
   144 
   145 If you want to re-generate this documentation, you can 
   146 easily do so:
   147 
   148   - doc/architecture.pdf is generated from the architecture.tex
   149     file in http://code.nsnam.org/docs
   150 
   151   - the doxygen documentation is generated from the doc/doxygen.conf
   152     configuration file. The command "scons doc" will generate it
   153     as doc/html/index.html if you have installed the doxygen tools 
   154     (see http://www.doxygen.org)
   155 
   156 6) Working with the development version of ns-3
   157 -----------------------------------------------
   158 
   159 If you want to download and use the development version 
   160 of ns-3, you need to use the tool 'mercurial'. A quick and
   161 dirty cheat sheet is included in doc/mercurial.txt but
   162 reading through the mercurial tutorials included on the
   163 mercurial website is usually a good idea if you are not
   164 familiar with it.
   165 
   166 If you have successfully installed mercurial, you can get
   167 a copy of the development version with the following
   168 command:
   169 "hg clone http://code.nsnam.org/ns-3-dev"