Man Linux: Main Page and Category List


       bgpsim - BGP4 routing environment simulator


       Usage: bgpsim [-i router_id] [-p port] [-f file] [-v] [-o output]

       BGPsim  simulates  complex BGP4 routing environments with possibly high
       levels of routing instability/change.

       BGPsim includes a perl program,, which is  used  to  generate
       ASCII  descriptions  of  BGP  traffic for use with route_btoa and sbgp.
       (The BGPsim Perl code is still quite rough.)


       BGPsim [-f configuration_file] [-l routing table] [-v] [-s] [-m]


          -f configuration_file
                 Read the specified configuration  file.  By  default,  bgpsim
                 to read ./bgpsim.conf.

                 Turn on verbose logging to standard output. This is useful to
                 turn on logging before the debug commands are read in the
                 configuration file.

                 By default, BGPSim does not set mandatory BGP attributes,
                 including origin, nexthop and ASPath. If this flag is used,
                 BGPsim will add these attributes and prepend the local AS to
                 the ASPath.

                 Use a new dump format.


       By default,  BGPsim  looks  for  "./bgpsim.conf".  The  format  of  the
       configuration  file  is described below. BGPsim also has an interactive
       (Cisco Systems router-like) interface:  telnet  to  port  5674  on  the
       machine running BGPsim.


       BGPsim  does not include mandatory attributes by default. You will need
       to explicitly include a nexthop, origin, and apsath attribute  in  your
       BGPsim configuration. Also note that BGPSim does not prepend its own AS
       by default.

         Sample Configuration File

       A sample BGPsim configuration file is shown below.

       network-list 1 range stability 10 jitter 4 map 1  !
       route-map  1  set  nexthop set aspath 185 123 23 23 12 set
       origin igp !

       network-list 2 range stability  9  jitter  3
       change  12  jitter  4  route-map  2  3  !   route-map  2  set  next-hop set as-path  185  123  23  23  12  set  origin  igp  set
       community 56:123 set dpa as 56 121 set local-preference 23 !  route-map
       3 set as-path 185 100 10 102 set origin igp set community  100:345  set
       dpa as 3 23 set local-preference 83 !  router bgp 185
         neighbor remote-as 65
         neighbor remote-as 165

          This file describes two simulation processes, as defined by
          network-list  1  and 2, which changes routes to two BGP peers (AS 65

          The first simulation process, network-list 1, changes routes
          ( and as defined in range  every  10  seconds.
          simulates an announcement of the routes first, and then a withdrawal
          after 10 seconds. Ten seconds after the withdraw, the next
          announcement is propagated. Thus the announcements and withdraws are
          repeated every 10 seconds. These routes have attributes defined in
          route-map 1: nexthop is and aspath is a sequence of 123
          23 23 12.

          The second network list describes simulation of the range of routes
          from to (i.e.,
, etc.) All of these routes have an initial aspath of
          (123 23 23 12), a next-hop of, and others as  defined
          route-map  2.  These attributes change every 12 seconds among route-
          2 and 3.

          The peers (AS 65 and AS165) receive routing updates originated by
          these two simulation processes.

         Configuration Commands

          For information about the uii, debug, and access-list configuration
          commands, see Chapter 2, "Getting Started." In addition to the MRTd
          configuration commands, the following are available in BGPsim to
          simulate routing changes:

          Defines a network-list with . This definition behaves like a routing
              process  which  generates routing changes within a range defined
              range subcommand by an interval defined by stability subcommand,
              changing route attributes as specified by change and route-map

          Options include:


          Defines a range to announce and withdraw, starting with up to
              (inclusive). The range is along classful boundaries.

          [jitter ]

              Defines an interval in second to change routes. Routes are
              announced  first  and  then  withdrawn after the interval. Thus,
              the   interval,   announce   and   withdraw    repeat.    Jitter
              a random number of seconds between 0 and <jitter number> to the

          [jitter ]

              Defines  an  interval  in  second to change attributes of routes
              announced. route-map subcommand defines a sequence. Jitter
              adds/subtracts a random <number> of seconds from the timer.

          map ...

          Defines a sequence of route-maps to be used. The next route-mapis
              adopted after the interval defined in change subcommand. At the
              end of list, the first route-map is adopted as a next. The first
              route-map behaves as a default, that is, this is always adopted
              before adopting other route-maps.

          file ...

          Loads  routes from routing table dump file rather than using a range

          BGPSim also adds several commands to bgp router commands:

          neighbor stability

          Define stability for TCP peering session with this peer.

         Interactive Interface Commands

          The BGPsim interactive interface supports the following commands in
          addition to MRTd interactive interface commands:

          show simulation

          stop simulation

          start simulation

       You can find more documentation in /usr/share/doc/mrt/html/