delaylink.rspec 2.8 KB
Newer Older
1 2 3
<rspec xmlns="http://www.protogeni.net/resources/rspec/2"
       xmlns:delay="http://www.protogeni.net/resources/rspec/ext/delay/1"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4
       xsi:schemaLocation="http://www.protogeni.net/resources/rspec/2 http://www.protogeni.net/resources/rspec/2/request.xsd http://www.protogeni.net/resources/rspec/ext/delay/1 http://www.protogeni.net/resources/rspec/ext/delay/1/request.xsd" type="request">
Leigh B Stoller's avatar
Leigh B Stoller committed
5 6 7
  <!-- This rspec implements the following topology:
  
                 left-link          right-link
8
           left <=========> bridge <==========> right
Leigh B Stoller's avatar
Leigh B Stoller committed
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32

       The "bridge" is a special node type (sliver_type="delay") that
       tells the CM to insert an Emulab delay node instead of a plain
       (router) node. Within the node section, there is an Emulab
       extension section call "sliver_type_shaping" where you define
       the shaping parameters for the two pipes (one in each direction).
       At the moment you can specify bandwidth, delay, and loss, and the
       pipes may be shapped assymetrically. 

       In this example, traffic flowing from left to right are subject
       to the following shaping parameters:

		bandwidth=1000Kbs, latency=50ms, plr=0.0

       while traffic flowing from right to left:

		bandwidth=10000Kbs, latency=25ms, plr=0.01

       You can change the traffic shaping parameters on the fly using
       the Emulab event system, but there is no Protogeni interface to
       do so. Please see the web page for more details.

          https://users.emulab.net/trac/emulab/wiki/BridgeNodes
   -->
33 34 35 36
  <node client_id="left"
        exclusive="true">
    <sliver_type name="raw-pc" />
    <interface client_id="left:if0">
37
        <ip address="10.10.10.1" netmask="255.255.255.0" type="ipv4"/>
38 39 40 41 42 43
    </interface>
  </node>
  <node client_id="right"
        exclusive="true">
    <sliver_type name="raw-pc" />
    <interface client_id="right:if0">
44
        <ip address="10.10.10.2" netmask="255.255.255.0" type="ipv4"/>
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69
    </interface>
  </node>
  <node client_id="bridge"
        exclusive="true">
    <sliver_type name="delay">
      <delay:sliver_type_shaping
         xmlns="http://www.protogeni.net/resources/rspec/ext/delay/1">
        <pipe source="delay:left" dest="delay:right"
              capacity="1000" latency="50"/>
        <pipe source="delay:right" dest="delay:left"
              capacity="10000" latency="25" packet_loss="0.01"/>
      </delay:sliver_type_shaping>
    </sliver_type>
    <interface client_id="delay:left" />
    <interface client_id="delay:right" />
  </node>
  <link client_id="bridge-left">
    <interface_ref client_id="left:if0" />
    <interface_ref client_id="delay:left" />
  </link>
  <link client_id="bridge-right">
    <interface_ref client_id="right:if0" />
    <interface_ref client_id="delay:right" />
  </link>
</rspec>