Brian O'Connor

Adding more T-ports to big topo

Setting up bidirectional T-ports in OpticalPathProvisioner

Change-Id: I4e97b2eb53d3d4182aae9c98a227de982f492950
(cherry picked from commit d6843bed)
...@@ -192,7 +192,9 @@ public class OpticalPathProvisioner { ...@@ -192,7 +192,9 @@ public class OpticalPathProvisioner {
192 } 192 }
193 // provision both directions 193 // provision both directions
194 intents.addAll(getOpticalPath(one.location(), two.location())); 194 intents.addAll(getOpticalPath(one.location(), two.location()));
195 - intents.addAll(getOpticalPath(two.location(), one.location())); 195 + // note: bi-directional intent is set up
196 + // HostToHost Intent requires symmetric path!
197 + //intents.addAll(getOpticalPath(two.location(), one.location()));
196 } else if (intent instanceof PointToPointIntent) { 198 } else if (intent instanceof PointToPointIntent) {
197 PointToPointIntent p2pIntent = (PointToPointIntent) intent; 199 PointToPointIntent p2pIntent = (PointToPointIntent) intent;
198 intents.addAll(getOpticalPath(p2pIntent.ingressPoint(), p2pIntent.egressPoint())); 200 intents.addAll(getOpticalPath(p2pIntent.ingressPoint(), p2pIntent.egressPoint()));
...@@ -265,8 +267,13 @@ public class OpticalPathProvisioner { ...@@ -265,8 +267,13 @@ public class OpticalPathProvisioner {
265 Intent opticalIntent = new OpticalConnectivityIntent(appId, 267 Intent opticalIntent = new OpticalConnectivityIntent(appId,
266 srcWdmPoint, 268 srcWdmPoint,
267 dstWdmPoint); 269 dstWdmPoint);
270 + Intent opticalIntent2 = new OpticalConnectivityIntent(appId,
271 + dstWdmPoint,
272 + srcWdmPoint);
268 log.info("Creating optical intent from {} to {}", srcWdmPoint, dstWdmPoint); 273 log.info("Creating optical intent from {} to {}", srcWdmPoint, dstWdmPoint);
274 + log.info("Creating optical intent from {} to {}", dstWdmPoint, srcWdmPoint);
269 connectionList.add(opticalIntent); 275 connectionList.add(opticalIntent);
276 + connectionList.add(opticalIntent2);
270 277
271 break; 278 break;
272 } 279 }
......
...@@ -28,7 +28,7 @@ class SmallOpticalTopo( Topo ): ...@@ -28,7 +28,7 @@ class SmallOpticalTopo( Topo ):
28 o9ann = { "latitude": 40.8, "longitude": -73.1, "optical.regens": 0 } 28 o9ann = { "latitude": 40.8, "longitude": -73.1, "optical.regens": 0 }
29 O9 = self.addSwitch( 'JFK-M10', dpid='0000ffffffffff09', annotations=o9ann, cls=OpticalSwitch ) 29 O9 = self.addSwitch( 'JFK-M10', dpid='0000ffffffffff09', annotations=o9ann, cls=OpticalSwitch )
30 o10ann = { "latitude": 33.8, "longitude": -84.1, "optical.regens": 0 } 30 o10ann = { "latitude": 33.8, "longitude": -84.1, "optical.regens": 0 }
31 - O10 = self.addSwitch( 'ATL-S10', dpid='0000ffffffffff0A', annotations=o10ann, cls=OpticalSwitch ) 31 + O10 = self.addSwitch( 'ATL-S10', dpid='0000ffffffffff0a', annotations=o10ann, cls=OpticalSwitch )
32 32
33 33
34 SFOR10 = self.addSwitch( 'SFO-R10', dpid='0000ffffffff0001', annotations={"latitude": 37.6, "longitude": -122.3} ) 34 SFOR10 = self.addSwitch( 'SFO-R10', dpid='0000ffffffff0001', annotations={"latitude": 37.6, "longitude": -122.3} )
......
...@@ -29,17 +29,17 @@ class BigOpticalTopo( Topo ): ...@@ -29,17 +29,17 @@ class BigOpticalTopo( Topo ):
29 o9ann = { "latitude": 46.836379, "longitude": -100.796917, "optical.regens": 0 } 29 o9ann = { "latitude": 46.836379, "longitude": -100.796917, "optical.regens": 0 }
30 O9 = self.addSwitch( 'BSMRNDJC', dpid='0000ffffffffff09', annotations=o9ann, cls=OpticalSwitch ) 30 O9 = self.addSwitch( 'BSMRNDJC', dpid='0000ffffffffff09', annotations=o9ann, cls=OpticalSwitch )
31 o10ann = { "latitude": 30.449722, "longitude": -91.184167, "optical.regens": 0 } 31 o10ann = { "latitude": 30.449722, "longitude": -91.184167, "optical.regens": 0 }
32 - O10 = self.addSwitch( 'BTRGLAMA', dpid='0000ffffffffff0A', annotations=o10ann, cls=OpticalSwitch ) 32 + O10 = self.addSwitch( 'BTRGLAMA', dpid='0000ffffffffff0a', annotations=o10ann, cls=OpticalSwitch )
33 o11ann = { "latitude": 41.881484, "longitude": -87.640432, "optical.regens": 4 } 33 o11ann = { "latitude": 41.881484, "longitude": -87.640432, "optical.regens": 4 }
34 - O11 = self.addSwitch( 'CHCGILCL', dpid='0000ffffffffff0B', annotations=o11ann, cls=OpticalSwitch ) 34 + O11 = self.addSwitch( 'CHCGILCL', dpid='0000ffffffffff0b', annotations=o11ann, cls=OpticalSwitch )
35 o12ann = { "latitude": 35.224924, "longitude": -80.837502, "optical.regens": 0 } 35 o12ann = { "latitude": 35.224924, "longitude": -80.837502, "optical.regens": 0 }
36 - O12 = self.addSwitch( 'CHRLNCCA', dpid='0000ffffffffff0C', annotations=o12ann, cls=OpticalSwitch ) 36 + O12 = self.addSwitch( 'CHRLNCCA', dpid='0000ffffffffff0c', annotations=o12ann, cls=OpticalSwitch )
37 o13ann = { "latitude": 32.785278, "longitude": -79.938056, "optical.regens": 0 } 37 o13ann = { "latitude": 32.785278, "longitude": -79.938056, "optical.regens": 0 }
38 - O13 = self.addSwitch( 'CHTNSCDT', dpid='0000ffffffffff0D', annotations=o13ann, cls=OpticalSwitch ) 38 + O13 = self.addSwitch( 'CHTNSCDT', dpid='0000ffffffffff0d', annotations=o13ann, cls=OpticalSwitch )
39 o14ann = { "latitude": 41.498333, "longitude": -81.686943, "optical.regens": 0 } 39 o14ann = { "latitude": 41.498333, "longitude": -81.686943, "optical.regens": 0 }
40 - O14 = self.addSwitch( 'CLEVOH02', dpid='0000ffffffffff0E', annotations=o14ann, cls=OpticalSwitch ) 40 + O14 = self.addSwitch( 'CLEVOH02', dpid='0000ffffffffff0e', annotations=o14ann, cls=OpticalSwitch )
41 o15ann = { "latitude": 39.965279, "longitude": -82.996666, "optical.regens": 0 } 41 o15ann = { "latitude": 39.965279, "longitude": -82.996666, "optical.regens": 0 }
42 - O15 = self.addSwitch( 'CLMBOH11', dpid='0000ffffffffff0F', annotations=o15ann, cls=OpticalSwitch ) 42 + O15 = self.addSwitch( 'CLMBOH11', dpid='0000ffffffffff0f', annotations=o15ann, cls=OpticalSwitch )
43 o16ann = { "latitude": 42.36745, "longitude": -71.084918, "optical.regens": 0 } 43 o16ann = { "latitude": 42.36745, "longitude": -71.084918, "optical.regens": 0 }
44 O16 = self.addSwitch( 'CMBRMA01', dpid='0000ffffffffff10', annotations=o16ann, cls=OpticalSwitch ) 44 O16 = self.addSwitch( 'CMBRMA01', dpid='0000ffffffffff10', annotations=o16ann, cls=OpticalSwitch )
45 o17ann = { "latitude": 39.102778, "longitude": -84.516944, "optical.regens": 0 } 45 o17ann = { "latitude": 39.102778, "longitude": -84.516944, "optical.regens": 0 }
...@@ -61,17 +61,17 @@ class BigOpticalTopo( Topo ): ...@@ -61,17 +61,17 @@ class BigOpticalTopo( Topo ):
61 o25ann = { "latitude": 29.748333, "longitude": -95.36528, "optical.regens": 0 } 61 o25ann = { "latitude": 29.748333, "longitude": -95.36528, "optical.regens": 0 }
62 O25 = self.addSwitch( 'HSTNTX01', dpid='0000ffffffffff19', annotations=o25ann, cls=OpticalSwitch ) 62 O25 = self.addSwitch( 'HSTNTX01', dpid='0000ffffffffff19', annotations=o25ann, cls=OpticalSwitch )
63 o26ann = { "latitude": 30.33071, "longitude": -81.43, "optical.regens": 0 } 63 o26ann = { "latitude": 30.33071, "longitude": -81.43, "optical.regens": 0 }
64 - O26 = self.addSwitch( 'JCVLFLCL', dpid='0000ffffffffff1A', annotations=o26ann, cls=OpticalSwitch ) 64 + O26 = self.addSwitch( 'JCVLFLCL', dpid='0000ffffffffff1a', annotations=o26ann, cls=OpticalSwitch )
65 o27ann = { "latitude": 39.096649, "longitude": -94.578716, "optical.regens": 0 } 65 o27ann = { "latitude": 39.096649, "longitude": -94.578716, "optical.regens": 0 }
66 - O27 = self.addSwitch( 'KSCYMO09', dpid='0000ffffffffff1B', annotations=o27ann, cls=OpticalSwitch ) 66 + O27 = self.addSwitch( 'KSCYMO09', dpid='0000ffffffffff1b', annotations=o27ann, cls=OpticalSwitch )
67 o28ann = { "latitude": 40.5899999,"longitude": -73.6699993, "optical.regens": 0 } 67 o28ann = { "latitude": 40.5899999,"longitude": -73.6699993, "optical.regens": 0 }
68 - O28 = self.addSwitch( 'Island', dpid='0000ffffffffff1C', annotations=o28ann, cls=OpticalSwitch ) 68 + O28 = self.addSwitch( 'LGISLAND', dpid='0000ffffffffff1c', annotations=o28ann, cls=OpticalSwitch )
69 o29ann = { "latitude": 34.051227, "longitude": -118.252958, "optical.regens": 0 } 69 o29ann = { "latitude": 34.051227, "longitude": -118.252958, "optical.regens": 0 }
70 - O29 = self.addSwitch( 'LSANCA03', dpid='0000ffffffffff1D', annotations=o29ann, cls=OpticalSwitch ) # LSANCA03 Connected to packet node 70 + O29 = self.addSwitch( 'LSANCA03', dpid='0000ffffffffff1d', annotations=o29ann, cls=OpticalSwitch ) # LSANCA03 Connected to packet node
71 o30ann = { "latitude": 36.168056, "longitude": -115.138889, "optical.regens": 0 } 71 o30ann = { "latitude": 36.168056, "longitude": -115.138889, "optical.regens": 0 }
72 - O30 = self.addSwitch( 'LSVGNV02', dpid='0000ffffffffff1E', annotations=o30ann, cls=OpticalSwitch ) 72 + O30 = self.addSwitch( 'LSVGNV02', dpid='0000ffffffffff1e', annotations=o30ann, cls=OpticalSwitch )
73 o31ann = { "latitude":38.249167, "longitude": -85.760833, "optical.regens": 0 } 73 o31ann = { "latitude":38.249167, "longitude": -85.760833, "optical.regens": 0 }
74 - O31 = self.addSwitch( 'LSVLKYCS', dpid='0000ffffffffff1F', annotations=o31ann, cls=OpticalSwitch ) 74 + O31 = self.addSwitch( 'LSVLKYCS', dpid='0000ffffffffff1f', annotations=o31ann, cls=OpticalSwitch )
75 o32ann = { "latitude": 34.740833, "longitude": -92.271942, "optical.regens": 2 } 75 o32ann = { "latitude": 34.740833, "longitude": -92.271942, "optical.regens": 2 }
76 O32 = self.addSwitch( 'LTRKARFR', dpid='0000ffffffffff20', annotations=o32ann, cls=OpticalSwitch ) 76 O32 = self.addSwitch( 'LTRKARFR', dpid='0000ffffffffff20', annotations=o32ann, cls=OpticalSwitch )
77 o33ann = { "latitude": 25.779167, "longitude": -80.195, "optical.regens": 0 } 77 o33ann = { "latitude": 25.779167, "longitude": -80.195, "optical.regens": 0 }
...@@ -93,17 +93,17 @@ class BigOpticalTopo( Topo ): ...@@ -93,17 +93,17 @@ class BigOpticalTopo( Topo ):
93 o41ann = { "latitude": 40.767497, "longitude": -73.989713, "optical.regens": 0 } 93 o41ann = { "latitude": 40.767497, "longitude": -73.989713, "optical.regens": 0 }
94 O41 = self.addSwitch( 'NYCMNY54', dpid='0000ffffffffff29', annotations=o41ann, cls=OpticalSwitch ) 94 O41 = self.addSwitch( 'NYCMNY54', dpid='0000ffffffffff29', annotations=o41ann, cls=OpticalSwitch )
95 o42ann = { "latitude": 35.470833, "longitude": -97.515274, "optical.regens": 0 } 95 o42ann = { "latitude": 35.470833, "longitude": -97.515274, "optical.regens": 0 }
96 - O42 = self.addSwitch( 'OKCYOKCE', dpid='0000ffffffffff2A', annotations=o42ann, cls=OpticalSwitch ) 96 + O42 = self.addSwitch( 'OKCYOKCE', dpid='0000ffffffffff2a', annotations=o42ann, cls=OpticalSwitch )
97 o43ann = { "latitude": 37.805556, "longitude": -122.268889, "optical.regens": 2 } 97 o43ann = { "latitude": 37.805556, "longitude": -122.268889, "optical.regens": 2 }
98 - O43 = self.addSwitch( 'OKLDCA03', dpid='0000ffffffffff2B', annotations=o43ann, cls=OpticalSwitch ) 98 + O43 = self.addSwitch( 'OKLDCA03', dpid='0000ffffffffff2b', annotations=o43ann, cls=OpticalSwitch )
99 o44ann = { "latitude": 41.259167, "longitude":-95.940277, "optical.regens": 0 } 99 o44ann = { "latitude": 41.259167, "longitude":-95.940277, "optical.regens": 0 }
100 - O44 = self.addSwitch( 'OMAHNENW', dpid='0000ffffffffff2C', annotations=o44ann, cls=OpticalSwitch ) 100 + O44 = self.addSwitch( 'OMAHNENW', dpid='0000ffffffffff2c', annotations=o44ann, cls=OpticalSwitch )
101 o45ann = { "latitude": 28.543279, "longitude": -81.377502, "optical.regens": 0 } 101 o45ann = { "latitude": 28.543279, "longitude": -81.377502, "optical.regens": 0 }
102 - O45 = self.addSwitch( 'ORLDFLMA', dpid='0000ffffffffff2D', annotations=o45ann, cls=OpticalSwitch ) # ORLDFLMA Connected to packet node 102 + O45 = self.addSwitch( 'ORLDFLMA', dpid='0000ffffffffff2d', annotations=o45ann, cls=OpticalSwitch ) # ORLDFLMA Connected to packet node
103 o46ann = { "latitude": 39.946446, "longitude": -75.184139, "optical.regens": 0 } 103 o46ann = { "latitude": 39.946446, "longitude": -75.184139, "optical.regens": 0 }
104 - O46 = self.addSwitch( 'PHLAPASL', dpid='0000ffffffffff2E', annotations=o46ann, cls=OpticalSwitch ) 104 + O46 = self.addSwitch( 'PHLAPASL', dpid='0000ffffffffff2e', annotations=o46ann, cls=OpticalSwitch )
105 o47ann = { "latitude": 33.450361, "longitude": -112.07709, "optical.regens": 0 } 105 o47ann = { "latitude": 33.450361, "longitude": -112.07709, "optical.regens": 0 }
106 - O47 = self.addSwitch( 'PHNXAZMA', dpid='0000ffffffffff2F', annotations=o47ann, cls=OpticalSwitch ) # PHNXAZMA Connected to packet node 106 + O47 = self.addSwitch( 'PHNXAZMA', dpid='0000ffffffffff2f', annotations=o47ann, cls=OpticalSwitch ) # PHNXAZMA Connected to packet node
107 o48ann = { "latitude":40.441387, "longitude": -79.995552, "optical.regens": 0 } 107 o48ann = { "latitude":40.441387, "longitude": -79.995552, "optical.regens": 0 }
108 O48 = self.addSwitch( 'PITBPADG', dpid='0000ffffffffff30', annotations=o48ann, cls=OpticalSwitch ) 108 O48 = self.addSwitch( 'PITBPADG', dpid='0000ffffffffff30', annotations=o48ann, cls=OpticalSwitch )
109 o49ann = { "latitude":41.818889, "longitude": -71.415278, "optical.regens": 0 } 109 o49ann = { "latitude":41.818889, "longitude": -71.415278, "optical.regens": 0 }
...@@ -125,39 +125,43 @@ class BigOpticalTopo( Topo ): ...@@ -125,39 +125,43 @@ class BigOpticalTopo( Topo ):
125 o57ann = { "latitude": 29.429445, "longitude": -98.488892, "optical.regens": 0 } 125 o57ann = { "latitude": 29.429445, "longitude": -98.488892, "optical.regens": 0 }
126 O57 = self.addSwitch( 'SNANTXCA', dpid='0000ffffffffff39', annotations=o57ann, cls=OpticalSwitch ) # SNANTXCA Connected to packet node 126 O57 = self.addSwitch( 'SNANTXCA', dpid='0000ffffffffff39', annotations=o57ann, cls=OpticalSwitch ) # SNANTXCA Connected to packet node
127 o58ann = { "latitude": 34.418889, "longitude": -119.7, "optical.regens": 0 } 127 o58ann = { "latitude": 34.418889, "longitude": -119.7, "optical.regens": 0 }
128 - O58 = self.addSwitch( 'SNBBCA01', dpid='0000ffffffffff40', annotations=o58ann, cls=OpticalSwitch ) 128 + O58 = self.addSwitch( 'SNBBCA01', dpid='0000ffffffffff3a', annotations=o58ann, cls=OpticalSwitch )
129 o59ann = { "latitude":32.746944, "longitude": -117.158611, "optical.regens": 0 } 129 o59ann = { "latitude":32.746944, "longitude": -117.158611, "optical.regens": 0 }
130 - O59= self.addSwitch( 'SNDGCA02', dpid='0000ffffffffff41', annotations=o59ann, cls=OpticalSwitch ) 130 + O59 = self.addSwitch( 'SNDGCA02', dpid='0000ffffffffff3b', annotations=o59ann, cls=OpticalSwitch )
131 o60ann = { "latitude":37.785143, "longitude": -122.397263, "optical.regens": 0 } 131 o60ann = { "latitude":37.785143, "longitude": -122.397263, "optical.regens": 0 }
132 - O60 = self.addSwitch( 'SNFCCA21', dpid='0000ffffffffff42', annotations=o60ann, cls=OpticalSwitch ) 132 + O60 = self.addSwitch( 'SNFCCA21', dpid='0000ffffffffff3c', annotations=o60ann, cls=OpticalSwitch )
133 o61ann = { "latitude": 37.333333, "longitude": -121.892778, "optical.regens": 0 } 133 o61ann = { "latitude": 37.333333, "longitude": -121.892778, "optical.regens": 0 }
134 - O61 = self.addSwitch( 'SNJSCA02', dpid='0000ffffffffff43', annotations=o61ann, cls=OpticalSwitch ) # SNJSCA02 Connected to packet node 134 + O61 = self.addSwitch( 'SNJSCA02', dpid='0000ffffffffff3d', annotations=o61ann, cls=OpticalSwitch ) # SNJSCA02 Connected to packet node
135 o62ann = { "latitude": 39.795278, "longitude": -89.649444, "optical.regens": 0 } 135 o62ann = { "latitude": 39.795278, "longitude": -89.649444, "optical.regens": 0 }
136 - O62 = self.addSwitch( 'SPFDILSD', dpid='0000ffffffffff44', annotations=o62ann, cls=OpticalSwitch ) 136 + O62 = self.addSwitch( 'SPFDILSD', dpid='0000ffffffffff3e', annotations=o62ann, cls=OpticalSwitch )
137 o63ann = { "latitude": 47.654724, "longitude": -117.419167, "optical.regens": 0 } 137 o63ann = { "latitude": 47.654724, "longitude": -117.419167, "optical.regens": 0 }
138 - O63 = self.addSwitch( 'SPKNWA01', dpid='0000ffffffffff45', annotations=o63ann, cls=OpticalSwitch ) 138 + O63 = self.addSwitch( 'SPKNWA01', dpid='0000ffffffffff3f', annotations=o63ann, cls=OpticalSwitch )
139 o64ann = { "latitude": 38.633335, "longitude": -90.215279, "optical.regens": 0 } 139 o64ann = { "latitude": 38.633335, "longitude": -90.215279, "optical.regens": 0 }
140 - O64 = self.addSwitch( 'STLSMO09', dpid='0000ffffffffff46', annotations=o64ann, cls=OpticalSwitch ) 140 + O64 = self.addSwitch( 'STLSMO09', dpid='0000ffffffffff40', annotations=o64ann, cls=OpticalSwitch )
141 o65ann = { "latitude": 47.606945, "longitude": -122.333336, "optical.regens": 0 } 141 o65ann = { "latitude": 47.606945, "longitude": -122.333336, "optical.regens": 0 }
142 - O65 = self.addSwitch( 'STTLWA06', dpid='0000ffffffffff47', annotations=o65ann, cls=OpticalSwitch ) 142 + O65 = self.addSwitch( 'STTLWA06', dpid='0000ffffffffff41', annotations=o65ann, cls=OpticalSwitch )
143 o66ann = { "latitude": 43.049444, "longitude": -76.1475, "optical.regens": 3 } 143 o66ann = { "latitude": 43.049444, "longitude": -76.1475, "optical.regens": 3 }
144 - O66 = self.addSwitch( 'SYRCNYSU', dpid='0000ffffffffff48', annotations=o66ann, cls=OpticalSwitch ) 144 + O66 = self.addSwitch( 'SYRCNYSU', dpid='0000ffffffffff42', annotations=o66ann, cls=OpticalSwitch )
145 o67ann = { "latitude": 28.0225, "longitude": -82.522778, "optical.regens": 0 } 145 o67ann = { "latitude": 28.0225, "longitude": -82.522778, "optical.regens": 0 }
146 - O67 = self.addSwitch( 'TAMQFLFN', dpid='0000ffffffffff49', annotations=o67ann, cls=OpticalSwitch ) 146 + O67 = self.addSwitch( 'TAMQFLFN', dpid='0000ffffffffff43', annotations=o67ann, cls=OpticalSwitch )
147 o68ann = { "latitude": 32.224444, "longitude": -110.968333, "optical.regens": 0 } 147 o68ann = { "latitude": 32.224444, "longitude": -110.968333, "optical.regens": 0 }
148 - O68 = self.addSwitch( 'TCSNAZMA', dpid='0000ffffffffff4A', annotations=o68ann, cls=OpticalSwitch ) 148 + O68 = self.addSwitch( 'TCSNAZMA', dpid='0000ffffffffff44', annotations=o68ann, cls=OpticalSwitch )
149 - o69ann = { "latitude": 30.456389,"longitude": -84.290833, "optical.regens": 0 } 149 + o69ann = { "latitude": 30.456389, "longitude": -84.290833, "optical.regens": 0 }
150 - O69 = self.addSwitch( 'TLHSFLAT', dpid='0000ffffffffff4B', annotations=o69ann, cls=OpticalSwitch ) 150 + O69 = self.addSwitch( 'TLHSFLAT', dpid='0000ffffffffff45', annotations=o69ann, cls=OpticalSwitch )
151 - o70ann = { "latitude": 41.65,"longitude": -83.538056, "optical.regens": 2 } 151 + o70ann = { "latitude": 41.65, "longitude": -83.538056, "optical.regens": 2 }
152 - O70 = self.addSwitch( 'TOLDOH21', dpid='0000ffffffffff4C', annotations=o70ann, cls=OpticalSwitch ) 152 + O70 = self.addSwitch( 'TOLDOH21', dpid='0000ffffffffff46', annotations=o70ann, cls=OpticalSwitch )
153 - o71ann = { "latitude": 36.151669,"longitude": -95.985832, "optical.regens": 0 } 153 + o71ann = { "latitude": 36.151669, "longitude": -95.985832, "optical.regens": 0 }
154 - O71 = self.addSwitch( 'TULSOKTB', dpid='0000ffffffffff4D', annotations=o71ann, cls=OpticalSwitch ) 154 + O71 = self.addSwitch( 'TULSOKTB', dpid='0000ffffffffff47', annotations=o71ann, cls=OpticalSwitch )
155 - o72ann = { "latitude": 38.88306 ,"longitude": -77.01028, "optical.regens": 0 } 155 + o72ann = { "latitude": 38.88306 , "longitude": -77.01028, "optical.regens": 0 }
156 - O72 = self.addSwitch( 'WASHDCSW', dpid='0000ffffffffff4E', annotations=o72ann, cls=OpticalSwitch ) # WASHDCSW Connected to packet node 156 + O72 = self.addSwitch( 'WASHDCSW', dpid='0000ffffffffff48', annotations=o72ann, cls=OpticalSwitch ) # WASHDCSW Connected to packet node
157 - o73ann = { "latitude": 39.739167,"longitude": -75.553889, "optical.regens": 0 } 157 + o73ann = { "latitude": 39.739167, "longitude": -75.553889, "optical.regens": 0 }
158 - O73 = self.addSwitch( 'WLMGDE01', dpid='0000ffffffffff4F', annotations=o73ann, cls=OpticalSwitch ) 158 + O73 = self.addSwitch( 'WLMGDE01', dpid='0000ffffffffff49', annotations=o73ann, cls=OpticalSwitch )
159 - o74ann = { "latitude": 26.709391,"longitude": -80.05278, "optical.regens": 0 } 159 + o74ann = { "latitude": 26.709391, "longitude": -80.05278, "optical.regens": 0 }
160 - O74 = self.addSwitch( 'WPBHFLAN', dpid='0000ffffffffff50', annotations=o74ann, cls=OpticalSwitch ) 160 + O74 = self.addSwitch( 'WPBHFLAN', dpid='0000ffffffffff4a', annotations=o74ann, cls=OpticalSwitch )
161 + o75ann = { "latitude": 29.57, "longitude": -96.7, "optical.regens": 0 }
162 + O75 = self.addSwitch( 'AUSTTXGR', dpid='0000ffffffffff4b', annotations=o75ann, cls=OpticalSwitch )
163 + #o25ann = { "latitude": 29.748333, "longitude": -95.36528, "optical.regens": 0 }
164 + #o57ann = { "latitude": 29.429445, "longitude": -98.488892, "optical.regens": 0 }
161 165
162 166
163 # Packet Layer switches 167 # Packet Layer switches
...@@ -195,8 +199,8 @@ class BigOpticalTopo( Topo ): ...@@ -195,8 +199,8 @@ class BigOpticalTopo( Topo ):
195 self.addLink( O4, O8, port1=101, port2=105, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 271, "durable": "true" }, cls=OpticalLink ) # ATLNGATL BRHMALMT 199 self.addLink( O4, O8, port1=101, port2=105, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 271, "durable": "true" }, cls=OpticalLink ) # ATLNGATL BRHMALMT
196 self.addLink( O4, O12, port1=102, port2=106, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 436, "durable": "true" }, cls=OpticalLink ) # ATLNGATL CHRLNCCA 200 self.addLink( O4, O12, port1=102, port2=106, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 436, "durable": "true" }, cls=OpticalLink ) # ATLNGATL CHRLNCCA
197 self.addLink( O4, O26, port1=103, port2=105, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 566, "durable": "true" }, cls=OpticalLink ) # ATLNGATL JCVLFLCL 201 self.addLink( O4, O26, port1=103, port2=105, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 566, "durable": "true" }, cls=OpticalLink ) # ATLNGATL JCVLFLCL
198 - self.addLink( O5, O25, port1=101, port2=106, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 283, "durable": "true" }, cls=OpticalLink ) # AUSTTXGR HSTNTX01 202 + self.addLink( O75, O25, port1=101, port2=106, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 283, "durable": "true" }, cls=OpticalLink ) # AUSTTXGR HSTNTX01
199 - self.addLink( O5, O57, port1=102, port2=105, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 141, "durable": "true" }, cls=OpticalLink ) # AUSTTXGR SNANTXCA 203 + self.addLink( O75, O57, port1=102, port2=105, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 141, "durable": "true" }, cls=OpticalLink ) # AUSTTXGR SNANTXCA
200 self.addLink( O7, O46, port1=101, port2=106, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 170, "durable": "true" }, cls=OpticalLink ) # BLTMMDCH PHLAPASL 204 self.addLink( O7, O46, port1=101, port2=106, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 170, "durable": "true" }, cls=OpticalLink ) # BLTMMDCH PHLAPASL
201 self.addLink( O7, O48, port1=102, port2=105, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 378, "durable": "true" }, cls=OpticalLink ) # BLTMMDCH PITBPADG 205 self.addLink( O7, O48, port1=102, port2=105, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 378, "durable": "true" }, cls=OpticalLink ) # BLTMMDCH PITBPADG
202 self.addLink( O7, O70, port1=103, port2=107, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 68, "durable": "true" }, cls=OpticalLink ) # BLTMMDCH WASHDCSW 206 self.addLink( O7, O70, port1=103, port2=107, annotations={ "optical.waves": 80, "optical.type": "WDM", "optical.kms": 68, "durable": "true" }, cls=OpticalLink ) # BLTMMDCH WASHDCSW
...@@ -341,31 +345,34 @@ class BigOpticalTopo( Topo ): ...@@ -341,31 +345,34 @@ class BigOpticalTopo( Topo ):
341 self.addLink( ATLNGATLR, O4, port1=5, port2=13, speed1=10000, annotations={ "bandwidth": 100000, "optical.type": "cross-connect", "durable": "true" }, cls=OpticalLink ) 345 self.addLink( ATLNGATLR, O4, port1=5, port2=13, speed1=10000, annotations={ "bandwidth": 100000, "optical.type": "cross-connect", "durable": "true" }, cls=OpticalLink )
342 self.addLink( ATLNGATLR, O4, port1=6, port2=14, speed1=10000, annotations={ "bandwidth": 100000, "optical.type": "cross-connect", "durable": "true" }, cls=OpticalLink ) 346 self.addLink( ATLNGATLR, O4, port1=6, port2=14, speed1=10000, annotations={ "bandwidth": 100000, "optical.type": "cross-connect", "durable": "true" }, cls=OpticalLink )
343 347
344 - # Create Hosts 1..11
345 - h1 = self.addHost( 'h1' )
346 - h2 = self.addHost( 'h2' )
347 - h3 = self.addHost( 'h3' )
348 - h4 = self.addHost( 'h4' )
349 - h5 = self.addHost( 'h5' )
350 - h6 = self.addHost( 'h6' )
351 - h7 = self.addHost( 'h7' )
352 - h8 = self.addHost( 'h8' )
353 - h9 = self.addHost( 'h9' )
354 - h10 = self.addHost( 'h10' )
355 - h11 = self.addHost( 'h11' )
356 348
357 # Attach hosts to the packet layer switches 349 # Attach hosts to the packet layer switches
358 - self.addLink( SNJSCA02R, h1, port1=1 ) 350 + for i in range( 1, 4 ): #don't make this more than 4!!!!!
359 - self.addLink( SNANTXCAR, h2, port1=1 ) 351 + # Create Hosts 1..11
360 - self.addLink( ROCHNYXAR, h3, port1=1 ) 352 + h1 = self.addHost( 'h1d%d' % i, ip='10.0.1.%d/16' % i )
361 - self.addLink( PHNXAZMAR, h4, port1=1 ) 353 + h2 = self.addHost( 'h2d%d' % i, ip='10.0.2.%d/16' % i )
362 - self.addLink( ORLDFLMAR, h5, port1=1 ) 354 + h3 = self.addHost( 'h3d%d' % i, ip='10.0.3.%d/16' % i )
363 - self.addLink( NWRKNJ02R, h6, port1=1 ) 355 + h4 = self.addHost( 'h4d%d' % i, ip='10.0.4.%d/16' % i )
364 - self.addLink( MPLSMNDTR, h7, port1=1 ) 356 + h5 = self.addHost( 'h5d%d' % i, ip='10.0.5.%d/16' % i )
365 - self.addLink( LSANCA03R, h8, port1=1 ) 357 + h6 = self.addHost( 'h6d%d' % i, ip='10.0.6.%d/16' % i )
366 - self.addLink( DLLSTXTLR, h9, port1=1 ) 358 + h7 = self.addHost( 'h7d%d' % i, ip='10.0.7.%d/16' % i )
367 - self.addLink( ATLNGATLR, h10, port1=1 ) 359 + h8 = self.addHost( 'h8d%d' % i, ip='10.0.8.%d/16' % i )
368 - self.addLink( WASHDCSWR, h11, port1=1 ) 360 + h9 = self.addHost( 'h9d%d' % i, ip='10.0.9.%d/16' % i )
361 + h10 = self.addHost( 'h10d%d' % i, ip='10.0.10.%d/16' % i )
362 + h11 = self.addHost( 'h11d%d' % i, ip='10.0.11.%d/16' % i )
363 +
364 + port = i + 6
365 + self.addLink( SNJSCA02R, h1, port1=port )
366 + self.addLink( SNANTXCAR, h2, port1=port )
367 + self.addLink( ROCHNYXAR, h3, port1=port )
368 + self.addLink( PHNXAZMAR, h4, port1=port )
369 + self.addLink( ORLDFLMAR, h5, port1=port )
370 + self.addLink( NWRKNJ02R, h6, port1=port )
371 + self.addLink( MPLSMNDTR, h7, port1=port )
372 + self.addLink( LSANCA03R, h8, port1=port )
373 + self.addLink( DLLSTXTLR, h9, port1=port )
374 + self.addLink( ATLNGATLR, h10, port1=port )
375 + self.addLink( WASHDCSWR, h11, port1=port )
369 376
370 if __name__ == '__main__': 377 if __name__ == '__main__':
371 import sys 378 import sys
......
...@@ -220,10 +220,11 @@ def startOE( net ): ...@@ -220,10 +220,11 @@ def startOE( net ):
220 onosDir = os.environ[ 'ONOS_ROOT' ] 220 onosDir = os.environ[ 'ONOS_ROOT' ]
221 except: 221 except:
222 onosDir = findDir( 'onos' ) 222 onosDir = findDir( 'onos' )
223 - os.environ[ 'ONOS_ROOT' ] = onosDir
224 if not onosDir: 223 if not onosDir:
225 error( 'Please set ONOS_ROOT environment variable!\n' ) 224 error( 'Please set ONOS_ROOT environment variable!\n' )
226 return False 225 return False
226 + else:
227 + os.environ[ 'ONOS_ROOT' ] = onosDir
227 228
228 info( '*** Writing Topology.json file\n' ) 229 info( '*** Writing Topology.json file\n' )
229 with open( 'Topology.json', 'w' ) as outfile: 230 with open( 'Topology.json', 'w' ) as outfile:
...@@ -284,7 +285,7 @@ def startOE( net ): ...@@ -284,7 +285,7 @@ def startOE( net ):
284 intf2 = intfList[ 0 ] 285 intf2 = intfList[ 0 ]
285 intf.node.attach( findTap( intf2.node, intf2.node.ports[ intf2 ] ) ) 286 intf.node.attach( findTap( intf2.node, intf2.node.ports[ intf2 ] ) )
286 287
287 - info( '*** Press any key to push Topology.json to onos...\n' ) 288 + info( '*** Press ENTER to push Topology.json to onos...\n' )
288 raw_input() # FIXME... we should eventually remove this 289 raw_input() # FIXME... we should eventually remove this
289 info( '*** Pushing Topology.json to ONOS\n' ) 290 info( '*** Pushing Topology.json to ONOS\n' )
290 output = quietRun( '%s/tools/test/bin/onos-topo-cfg %s Topology.json' % ( onosDir, net.controllers[ 0 ].ip ), shell=True ) 291 output = quietRun( '%s/tools/test/bin/onos-topo-cfg %s Topology.json' % ( onosDir, net.controllers[ 0 ].ip ), shell=True )
......