Thomas Vachuska | eec8b19 | 2016-12-14 16:58:08 -0800 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | # ----------------------------------------------------------------------------- |
| 3 | # Creates a replica of the GEANT topology using ONOS null provider |
| 4 | # ----------------------------------------------------------------------------- |
| 5 | |
Simon Hunt | fe3d7b4 | 2017-04-05 11:19:45 -0700 | [diff] [blame^] | 6 | # config |
| 7 | host=${1:-localhost} |
| 8 | nports=24 |
| 9 | sleepfor=5 |
| 10 | |
| 11 | |
| 12 | # start custom simulation.. |
| 13 | onos ${host} null-simulation start custom |
| 14 | |
| 15 | |
| 16 | ## unfortunately, it takes a time for the sim to start up |
| 17 | # this is not ideal... |
| 18 | |
| 19 | echo |
| 20 | echo "Sleeping while sim starts up... (${sleepfor} seconds)..." |
| 21 | echo |
| 22 | sleep ${sleepfor} |
| 23 | |
| 24 | # Add devices, links, and hosts |
Thomas Vachuska | eec8b19 | 2016-12-14 16:58:08 -0800 | [diff] [blame] | 25 | onos ${1:-localhost} <<-EOF |
| 26 | |
Simon Hunt | fe3d7b4 | 2017-04-05 11:19:45 -0700 | [diff] [blame^] | 27 | null-create-device switch ATH ${nports} 37.984149 23.7279843 |
| 28 | null-create-device switch LIS ${nports} 38.707792 -9.1365069 |
| 29 | null-create-device switch LON ${nports} 51.507321 -0.1276473 |
| 30 | null-create-device switch BRU ${nports} 50.846556 4.351697 |
| 31 | null-create-device switch PAR ${nports} 48.856610 2.3514992 |
| 32 | null-create-device switch DUB ${nports} 53.349764 -8.2602731 |
| 33 | null-create-device switch MAD ${nports} 40.416704 -3.7035824 |
| 34 | null-create-device switch GEN ${nports} 46.201755 6.1466014 |
| 35 | null-create-device switch MIL ${nports} 45.466797 9.1904984 |
| 36 | null-create-device switch SOF ${nports} 42.697721 23.3225964 |
| 37 | null-create-device switch BUC ${nports} 44.436141 26.1027443 |
| 38 | null-create-device switch VIE ${nports} 48.208353 15.3725042 |
| 39 | null-create-device switch FRA ${nports} 50.110652 8.6820934 |
| 40 | null-create-device switch COP ${nports} 55.686724 9.5700724 |
| 41 | null-create-device switch TLN ${nports} 59.437215 24.7453688 |
| 42 | null-create-device switch RIG ${nports} 56.949397 24.1051846 |
| 43 | null-create-device switch KAU ${nports} 54.898106 23.9117515 |
| 44 | null-create-device switch POZ ${nports} 52.408266 16.9335199 |
| 45 | null-create-device switch PRA ${nports} 50.087465 14.4212503 |
| 46 | null-create-device switch BRA ${nports} 48.135908 18.1597440 |
| 47 | null-create-device switch ZAG ${nports} 45.813154 15.9770298 |
| 48 | null-create-device switch LJU ${nports} 46.049865 14.5068921 |
| 49 | null-create-device switch BUD ${nports} 47.498381 19.0404707 |
| 50 | null-create-device switch MLT ${nports} 35.898754 14.5134889 |
| 51 | null-create-device switch LUX ${nports} 49.815868 6.1296751 |
| 52 | null-create-device switch MAR ${nports} 43.296174 5.3699525 |
| 53 | null-create-device switch HAM ${nports} 50.699641 10.6301627 |
| 54 | null-create-device switch AMS ${nports} 50.828525 -4.546936 |
| 55 | null-create-device switch STO ${nports} 43.296174 5.3699525 |
| 56 | null-create-device switch OSL ${nports} 53.550341 10.000654 |
| 57 | null-create-device switch HEL ${nports} 52.374436 4.89799560 |
Thomas Vachuska | eec8b19 | 2016-12-14 16:58:08 -0800 | [diff] [blame] | 58 | |
| 59 | null-create-link direct ATH MIL |
| 60 | null-create-link direct MIL ATH |
| 61 | null-create-link direct MIL VIE |
| 62 | null-create-link direct MIL MAR |
| 63 | null-create-link direct MIL GEN |
| 64 | null-create-link direct GEN MIL |
| 65 | null-create-link direct MIL MLT |
| 66 | null-create-link direct GEN FRA |
| 67 | null-create-link direct FRA GEN |
| 68 | null-create-link direct GEN PAR |
| 69 | null-create-link direct PAR GEN |
| 70 | null-create-link direct GEN PAR |
| 71 | null-create-link direct FRA POZ |
| 72 | null-create-link direct GEN MAR |
| 73 | null-create-link direct MAR MAD |
| 74 | null-create-link direct MAD PAR |
| 75 | null-create-link direct MAD LIS |
| 76 | null-create-link direct LIS LON |
| 77 | null-create-link direct LON LIS |
| 78 | null-create-link direct LON PAR |
| 79 | null-create-link direct LON DUB |
| 80 | null-create-link direct DUB LON |
| 81 | null-create-link direct LON BRU |
| 82 | null-create-link direct BRU AMS |
| 83 | null-create-link direct AMS LUX |
| 84 | null-create-link direct LUX FRA |
| 85 | null-create-link direct AMS HAM |
| 86 | null-create-link direct HAM FRA |
| 87 | null-create-link direct HAM COP |
| 88 | null-create-link direct COP AMS |
| 89 | null-create-link direct FRA POZ |
| 90 | null-create-link direct FRA PRA |
| 91 | null-create-link direct FRA BUD |
| 92 | null-create-link direct FRA VIE |
| 93 | null-create-link direct POZ PRA |
| 94 | null-create-link direct POZ KAU |
| 95 | null-create-link direct KAU RIG |
| 96 | null-create-link direct ZAG VIE |
| 97 | null-create-link direct ZAG BUD |
| 98 | null-create-link direct BUD PRA |
| 99 | null-create-link direct BUD BRA |
| 100 | null-create-link direct BUD BUC |
| 101 | null-create-link direct BUD SOF |
| 102 | null-create-link direct BUD LJU |
| 103 | null-create-link direct BUC SOF |
| 104 | null-create-link direct BUC VIE |
| 105 | null-create-link direct VIE BRA |
| 106 | null-create-link direct RIG TLN |
| 107 | null-create-link direct TLN HAM |
| 108 | null-create-link direct OSL STO |
| 109 | null-create-link direct STO HEL |
| 110 | null-create-link direct STO COP |
| 111 | null-create-link direct OSL COP |
| 112 | null-create-link direct TLN HEL |
| 113 | |
| 114 | null-create-host ATH 192.168.1.1 34.984149 24.7279843 |
| 115 | null-create-host LIS 192.168.1.2 37.707792 -7.1365069 |
| 116 | null-create-host LON 192.168.1.3 53.507321 -1.1276473 |
| 117 | null-create-host BRU 192.168.1.4 49.046556 4.351697 |
| 118 | null-create-host PAR 192.168.1.5 46.856610 2.3514992 |
| 119 | null-create-host DUB 192.168.1.6 54.349764 -8.2602731 |
| 120 | null-create-host MAD 192.168.1.7 37.416704 -3.7035824 |
| 121 | null-create-host GEN 192.168.1.8 45.001755 4.1466014 |
| 122 | null-create-host MIL 192.168.1.9 45.466797 6.6904984 |
| 123 | null-create-host SOF 192.168.1.10 42.697721 27.9225964 |
| 124 | null-create-host BUC 192.168.1.11 47.436141 26.1027443 |
| 125 | null-create-host VIE 192.168.1.12 48.208353 13.3725042 |
| 126 | null-create-host FRA 192.168.1.13 48.110652 9.2820934 |
| 127 | null-create-host COP 192.168.1.14 57.186724 9.5700724 |
| 128 | null-create-host TLN 192.168.1.15 59.437215 26.7453688 |
| 129 | null-create-host RIG 192.168.1.16 56.949397 26.1051846 |
| 130 | null-create-host KAU 192.168.1.17 52.898106 24.9117515 |
| 131 | null-create-host POZ 192.168.1.18 50.408266 19.3335199 |
| 132 | null-create-host PRA 192.168.1.19 50.087465 16.4212503 |
| 133 | null-create-host BRA 192.168.1.20 48.835908 19.1597440 |
| 134 | null-create-host ZAG 192.168.1.21 43.213154 16.4770298 |
| 135 | null-create-host LJU 192.168.1.22 46.049865 13.2068921 |
| 136 | null-create-host BUD 192.168.1.23 47.898381 20.2404707 |
| 137 | null-create-host MLT 192.168.1.24 32.898754 14.5134889 |
| 138 | null-create-host LUX 192.168.1.25 48.815868 6.5296751 |
| 139 | null-create-host MAR 192.168.1.26 43.296174 5.3699525 |
| 140 | null-create-host HAM 192.168.1.27 50.828525 -4.546936 |
| 141 | null-create-host AMS 192.168.1.28 43.374436 3.3699525 |
| 142 | null-create-host STO 192.168.1.29 52.699641 11.6301627 |
| 143 | null-create-host OSL 192.168.1.30 51.374436 7.39799560 |
| 144 | null-create-host HEL 192.168.1.31 61.325117 16.0710935 |
| 145 | |
| 146 | EOF |