file networks.dml


# database of preconfigured networks supporting
# the model usa1b.dml

networks [

    network100 [
      Net [
        router [ id 0
         interface [ id 0 _extends .dictionary.1Gb ]    # not attached
         interface [ id 1 _extends .dictionary.1Gb ]    # not attached
         #interface [ id 2 _extends .dictionary.1Gb ]    # not attached
         interface [ id 3 _extends .dictionary.100Mb ]
         interface [ id 4 _extends .dictionary.100Mb ]
         interface [ id 5 _extends .dictionary.100Mb ]
         interface [ id 6 _extends .dictionary.100Mb ]
         _find .dictionary.routerGraph.graph
        ]

        # all hosts are identical. 4 lans @ 25 hosts per lan = 100 hosts

        host [
          idrange [from 1 to 25]
         _find .dictionary.client100Mb.interface
         _find .dictionary.client100Mb.graph
         nhi_route [dest default interface 0 next_hop 0(3)]
        ]
        host [
          idrange [from 26 to 50]
         _find .dictionary.client100Mb.interface
         _find .dictionary.client100Mb.graph
         nhi_route [dest default interface 0 next_hop 0(4)]
        ]
        host [
          idrange [from 51 to 75]
         _find .dictionary.client100Mb.interface
         _find .dictionary.client100Mb.graph
         nhi_route [dest default interface 0 next_hop 0(5)]
        ]
        host [
          idrange [from 76 to 100]
         _find .dictionary.client100Mb.interface
         _find .dictionary.client100Mb.graph
         nhi_route [dest default interface 0 next_hop 0(6)]
        ]

        link [ delay 0.001
         attach 0(3)
         attach 1(0) attach 2(0) attach 3(0) attach 4(0) attach 5(0)
         attach 6(0) attach 7(0) attach 8(0) attach 9(0) attach 10(0)
         attach 11(0) attach 12(0) attach 13(0) attach 14(0) attach 15(0)
         attach 16(0) attach 17(0) attach 18(0) attach 19(0) attach 20(0)
         attach 21(0) attach 22(0) attach 23(0) attach 24(0) attach 25(0)
        ]

        link [ delay 0.001
         attach 0(4)
         attach 26(0) attach 27(0) attach 28(0) attach 29(0) attach 30(0)
         attach 31(0) attach 32(0) attach 33(0) attach 34(0) attach 35(0)
         attach 36(0) attach 37(0) attach 38(0) attach 39(0) attach 40(0)
         attach 41(0) attach 42(0) attach 43(0) attach 44(0) attach 45(0)
         attach 46(0) attach 47(0) attach 48(0) attach 49(0) attach 50(0)
        ]

        link [ delay 0.001
         attach 0(5)
         attach 51(0) attach 52(0) attach 53(0) attach 54(0) attach 55(0)
         attach 56(0) attach 57(0) attach 58(0) attach 59(0) attach 60(0)
         attach 61(0) attach 62(0) attach 63(0) attach 64(0) attach 65(0)
         attach 66(0) attach 67(0) attach 68(0) attach 69(0) attach 70(0)
         attach 71(0) attach 72(0) attach 73(0) attach 74(0) attach 75(0)
        ]

        link [ delay 0.001
         attach 0(6)
         attach 76(0) attach 77(0) attach 78(0) attach 79(0) attach 80(0)
         attach 81(0) attach 82(0) attach 83(0) attach 84(0) attach 85(0)
         attach 86(0) attach 87(0) attach 88(0) attach 89(0) attach 90(0)
         attach 91(0) attach 92(0) attach 93(0) attach 94(0) attach 95(0)
         attach 96(0) attach 97(0) attach 98(0) attach 99(0) attach 100(0)
        ]
      ]
    ] # end network100

  #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

   network50 [
      Net [
        router [ id 0
         interface [ id 0 _extends .dictionary.1Gb ]    # not attached
         interface [ id 1 _extends .dictionary.1Gb ]    # not attached
         interface [ id 2 _extends .dictionary.1Gb ]    # not attached
         interface [ id 3 _extends .dictionary.100Mb ]
         interface [ id 4 _extends .dictionary.100Mb ]
         _find .dictionary.routerGraph.graph
        ]

        # all hosts are identical. 2 lans @ 25 hosts per lan = 50 hosts

        host [
          idrange [from 1 to 25]
         _find .dictionary.client100Mb.interface
         _find .dictionary.client100Mb.graph
         nhi_route [dest default interface 0 next_hop 0(3)]
        ]
        host [
          idrange [from 26 to 50]
         _find .dictionary.client100Mb.interface
         _find .dictionary.client100Mb.graph
         nhi_route [dest default interface 0 next_hop 0(4)]
        ]

        link [ delay 0.001
         attach 0(3)
         attach 1(0) attach 2(0) attach 3(0) attach 4(0) attach 5(0)
         attach 6(0) attach 7(0) attach 8(0) attach 9(0) attach 10(0)
         attach 11(0) attach 12(0) attach 13(0) attach 14(0) attach 15(0)
         attach 16(0) attach 17(0) attach 18(0) attach 19(0) attach 20(0)
         attach 21(0) attach 22(0) attach 23(0) attach 24(0) attach 25(0)
        ]

        link [ delay 0.001
         attach 0(4)
         attach 26(0) attach 27(0) attach 28(0) attach 29(0) attach 30(0)
         attach 31(0) attach 32(0) attach 33(0) attach 34(0) attach 35(0)
         attach 36(0) attach 37(0) attach 38(0) attach 39(0) attach 40(0)
         attach 41(0) attach 42(0) attach 43(0) attach 44(0) attach 45(0)
         attach 46(0) attach 47(0) attach 48(0) attach 49(0) attach 50(0)
        ]
      ]
    ] # end network50

  #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

   network4 [
      Net [
        router [ id 0
         interface [ id 0 _extends .dictionary.10Gb ]
         interface [ id 1 _extends .dictionary.10Gb ]
         interface [ id 2 _extends .dictionary.10Gb ]
         interface [ id 3 _extends .dictionary.10Gb ]   # not attached
         _find .dictionary.routerGraph.graph
        ]
        router [ id 1
         interface [ id 0 _extends .dictionary.10Gb ]
         interface [ id 1 _extends .dictionary.10Gb ]
         interface [ id 2 _extends .dictionary.10Gb ]
         #interface [ id 3 _extends .dictionary.10Gb ]   # not attached
         _find .dictionary.routerGraph.graph
        ]

        host [ idrange [ from 2 to 5 ]
          _extends .dictionary.server10Gb
          route [dest default interface 0]
        ]

        link [ attach 0(2) attach 1(0) delay 0.001 ]
        link [ attach 0(0) attach 2(0) delay 0.001 ]
        link [ attach 0(1) attach 3(0) delay 0.001 ]
        link [ attach 1(1) attach 4(0) delay 0.001 ]
        link [ attach 1(2) attach 5(0) delay 0.001 ]
      ]
    ]  # end of network4

  #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

  # we will use unattached interfaces 0:0(0) and 1(0)

    network33 [
      Net [
        Net [ id 0 _extends .networks.network100.Net ]
        Net [ id 2 _extends .networks.network100.Net ]
        Net [ id 3 _extends .networks.network100.Net ]
        Net [ id 4 _extends .networks.network100.Net ]

        router [ id 1
         interface [ id 0 _extends .dictionary.10Gb ]   # not attached
         interface [ id 1 _extends .dictionary.1Gb ]
         interface [ id 2 _extends .dictionary.1Gb ]
         interface [ id 3 _extends .dictionary.1Gb ]
         interface [ id 4 _extends .dictionary.1Gb ]
         _find .dictionary.routerGraph.graph
        ]
      
        # ptp links

        link [ attach 0:0(1) attach 1(4) delay 0.005 ]
        link [ attach 1(1) attach 4:0(0) delay 0.005 ]
        link [ attach 2:0(0) attach 1(3) delay 0.001 ]
        link [ attach 3:0(0) attach 1(2) delay 0.001 ]
        link [ attach 2:0(1) attach 3:0(1) delay 0.001 ]
      ]
    ]  # end of network33

  #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

 # will use unattached interfaces 0:0(0) and 1(0)

    network34 [
      Net [
        Net [ id 0 _extends .networks.network100.Net ]
        Net [ id 2 _extends .networks.network100.Net ]
        Net [ id 3 _extends .networks.network100.Net ]
        Net [ id 4 _extends .networks.network100.Net ]
        Net [ id 5 _extends .networks.network100.Net ]

        router [ id 1
         interface [ id 0 _extends .dictionary.10Gb ]   # not attached
         interface [ id 1 _extends .dictionary.1Gb ]
         interface [ id 2 _extends .dictionary.1Gb ]
         interface [ id 3 _extends .dictionary.1Gb ]
         interface [ id 4 _extends .dictionary.1Gb ]
         interface [ id 5 _extends .dictionary.1Gb ]
         _find .dictionary.routerGraph.graph
        ]
      
        # ptp links

        link [ attach 0:0(0) attach 1(5) delay 0.005 ]
        link [ attach 2:0(0) attach 1(4) delay 0.005 ]
        link [ attach 3:0(0) attach 1(3) delay 0.005 ]
        link [ attach 4:0(0) attach 1(1) delay 0.005 ]
        link [ attach 5:0(0) attach 1(2) delay 0.005 ]
        link [ attach 2:0(1) attach 3:0(1) delay 0.001 ]
      ]
    ]  # end of network34

     #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

 network21 [
      Net [
        router [ id 0
         interface [ id 0 _extends .dictionary.10Gb ]   # not attached
         interface [ id 1 _extends .dictionary.1Gb ]
         interface [ id 2 _extends .dictionary.1Gb ]
         _find .dictionary.routerGraph.graph
        ]
        router [ id 1
         interface [ id 0 _extends .dictionary.10Gb ]   # not attached
         interface [ id 1 _extends .dictionary.1Gb ]
         interface [ id 2 _extends .dictionary.1Gb ]
         _find .dictionary.routerGraph.graph
        ]

        Net [ id 2 _extends .networks.network50.Net]
        Net [ id 3 _extends .networks.network50.Net]
        Net [ id 4 _extends .networks.network100.Net]

        router [ id 5
         interface [ id 0 _extends .dictionary.1Gb ]
         interface [ id 1 _extends .dictionary.1Gb ]
         interface [ id 2 _extends .dictionary.1Gb ]
         _find .dictionary.routerGraph.graph
        ]

        Net [ id 6 _extends .networks.network100.Net]
        Net [ id 7  _extends .networks.network100.Net]


        link [ attach 0(1) attach 1(2) delay 0.010 ]
        link [ attach 0(2) attach 2:0(0) delay 0.001 ]
        link [ attach 2:0(1) attach 3:0(2) delay 0.010 ]
        link [ attach 2:0(2) attach 4:0(0) delay 0.005 ]

        link [ attach 1(1) attach 3:0(0) delay 0.001 ]
        link [ attach 3:0(1) attach 5(0) delay 0.001 ]
        link [ attach 5(2) attach 6:0(0) delay 0.010 ]
        link [ attach 5(1) attach 7:0(0) delay 0.010 ]
      ]
    ]  # end of network21

   #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
   # little backbone

    network1 [
      Net [
       router [ id 0
        interface [ id 0 _extends .dictionary.10Gb ] 
        interface [ id 1 _extends .dictionary.10Gb ]
        interface [ id 2 _extends .dictionary.10Gb ]    # not attached
        interface [ id 3 _extends .dictionary.10Gb ]    # not attached
        _find .dictionary.routerGraph.graph
       ]
       router [ id 1
        interface [ id 0 _extends .dictionary.10Gb ] 
        interface [ id 1 _extends .dictionary.10Gb ]    # not attached
        interface [ id 2 _extends .dictionary.10Gb ]
        _find .dictionary.routerGraph.graph
       ]
       router [ id 2
        interface [ id 0 _extends .dictionary.10Gb ]    # not attached 
        interface [ id 1 _extends .dictionary.10Gb ]
        interface [ id 2 _extends .dictionary.10Gb ]
        interface [ id 3 _extends .dictionary.10Gb ]    # not attached
        interface [ id 4 _extends .dictionary.100Gb ]   # not attached
        _find .dictionary.routerGraph.graph
       ]

       link [ attach 0(1) attach 1(2) delay 0.01] # 10 ms delay
       link [ attach 1(0) attach 2(1) delay 0.01]
       link [ attach 0(0) attach 2(2) delay 0.01]
      ]
    ] # end of network1

     #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

 
    as2 [
      Net [
        AS_status boundary
        ospf_area 0

       # a big BGP router with multiple unattached interfaces
       # that will provide attachment points for inter-domain links
       
       router [ id 10
        interface [ id 0 _extends .dictionary.100Gb ]
        interface [ id 1 _extends .dictionary.100Gb ]
        interface [ id 2 _extends .dictionary.100Gb ]
        interface [ id 3 _extends .dictionary.100Gb ]
        interface [ id 4 _extends .dictionary.100Gb ]
        interface [ id 5 _extends .dictionary.100Gb ]
        interface [ id 6 _extends .dictionary.100Gb ]
        interface [ id 7 _extends .dictionary.100Gb ]
        interface [ id 8 _extends .dictionary.100Gb ]
        interface [ id 9 _extends .dictionary.100Gb ]
        interface [ id 10 _extends .dictionary.100Gb ]
        interface [ id 11 _extends .dictionary.100Gb ]
        interface [ id 12 _extends .dictionary.100Gb ]
        interface [ id 13 _extends .dictionary.100Gb ] # attached to AS-internal
        _find .dictionary.BGProuterGraph.graph
       ]       

       Net [id 0 _extends .networks.network1.Net]    # backbone
       Net [id 1 _extends .networks.network4.Net]    # server farm
       Net [id 2 _extends .networks.network33.Net]
       Net [id 3 _extends .networks.network21.Net]
       Net [id 4 _extends .networks.network34.Net]
       
       
       link [ attach 10(13) attach 0:2(4) delay 0.003]
       
       
       # router between backbone and net 3
       router [ id 5
        interface [ id 0 _extends .dictionary.10Gb ] 
        interface [ id 1 _extends .dictionary.10Gb ]
        interface [ id 2 _extends .dictionary.10Gb ]
        interface [ id 3 _extends .dictionary.10Gb ]
        _find .dictionary.routerGraph.graph
       ]

       # router between backbone and net 2
       router [ id 6
        interface [ id 0 _extends .dictionary.10Gb ] 
        interface [ id 1 _extends .dictionary.10Gb ]
        interface [ id 2 _extends .dictionary.10Gb ]
        interface [ id 3 _extends .dictionary.10Gb ]
        _find .dictionary.routerGraph.graph
       ]

       # router between backbone and net 4
       router [ id 7
        interface [ id 0 _extends .dictionary.10Gb ] 
        interface [ id 1 _extends .dictionary.10Gb ]
        interface [ id 2 _extends .dictionary.10Gb ]
        interface [ id 3 _extends .dictionary.10Gb ]
        _find .dictionary.routerGraph.graph
       ]

       link [ attach 5(1) attach 6(3) delay 0.005]

       # links from backbone routers 0,1,2 to routers 5, 6, 7, 1:0 
       link [ attach 0:0(2) attach 5(0) delay 0.01]
       link [ attach 0:1(1) attach 6(0) delay 0.01]
       link [ attach 0:2(0) attach 1:0(3) delay 0.01]
       link [ attach 0:2(3) attach 7(0) delay 0.01]
       link [ attach 0:0(3) attach 7(1) delay 0.01]

       # links to connect router 5 to net 3
       link [ attach 5(2) attach 3:1(0) delay 0.005]
       link [ attach 5(3) attach 3:0(0) delay 0.005]

       # similarly links to connect router 6 to net 2 
       link [ attach 6(2) attach 2:0:0(0) delay 0.005]
       link [ attach 6(1) attach 2:1(0) delay 0.005]

       # similarly links to connect router 7 to net 4
       link [ attach 7(3) attach 4:0:0(1) delay 0.005]
       link [ attach 7(2) attach 4:1(0) delay 0.005]
      ]
    ]  # end of as2

] # end of networks database