From 237994203f93612c140186ccf0920b43e5fcb702 Mon Sep 17 00:00:00 2001 From: stevenvanrossem Date: Fri, 19 Feb 2016 10:33:09 +0100 Subject: [PATCH] update openflow port for ryu --- .gitignore | 0 emuvim/api/zerorpcapi_DCNetwork.py | 7 +++++-- emuvim/cli/monitor.py | 0 emuvim/dcemulator/monitoring.py | 0 emuvim/dcemulator/net.py | 4 +++- emuvim/example_topology.py | 1 - 6 files changed, 8 insertions(+), 4 deletions(-) mode change 100644 => 100755 .gitignore mode change 100644 => 100755 emuvim/api/zerorpcapi_DCNetwork.py mode change 100644 => 100755 emuvim/cli/monitor.py mode change 100644 => 100755 emuvim/dcemulator/monitoring.py diff --git a/.gitignore b/.gitignore old mode 100644 new mode 100755 diff --git a/emuvim/api/zerorpcapi_DCNetwork.py b/emuvim/api/zerorpcapi_DCNetwork.py old mode 100644 new mode 100755 index 24becd3..b60093d --- a/emuvim/api/zerorpcapi_DCNetwork.py +++ b/emuvim/api/zerorpcapi_DCNetwork.py @@ -34,9 +34,12 @@ class ZeroRpcApiEndpointDCNetwork(object): python_install_path = site.getsitepackages()[0] ryu_path = python_install_path + '/ryu/app/simple_switch_13.py' ryu_path2 = python_install_path + '/ryu/app/ofctl_rest.py' + # change the default Openflow controller port to 6653 (official IANA-assigned port number), as used by Mininet + # Ryu still uses 6633 as default + ryu_option = '--ofp-tcp-listen-port' + ryu_of_port = '6653' ryu_cmd = 'ryu-manager' - self.ryu_process = Popen([ryu_cmd, ryu_path, ryu_path2]) - + self.ryu_process = Popen([ryu_cmd, ryu_path, ryu_path2, ryu_option, ryu_of_port]) def connectDCNetwork(self, net): self.net = net diff --git a/emuvim/cli/monitor.py b/emuvim/cli/monitor.py old mode 100644 new mode 100755 diff --git a/emuvim/dcemulator/monitoring.py b/emuvim/dcemulator/monitoring.py old mode 100644 new mode 100755 diff --git a/emuvim/dcemulator/net.py b/emuvim/dcemulator/net.py index 609d46c..324c4d3 100755 --- a/emuvim/dcemulator/net.py +++ b/emuvim/dcemulator/net.py @@ -27,9 +27,11 @@ class DCNetwork(Dockernet): self.dcs = {} # create a Mininet/Dockernet network # call original Docker.__init__ and setup default controller + #Dockernet.__init__( + # self, controller=RemoteController, switch=OVSKernelSwitch, **kwargs) Dockernet.__init__( self, controller=RemoteController, switch=OVSKernelSwitch, **kwargs) - self.addController('c0') + self.addController('c0', controller=RemoteController) # graph of the complete DC network self.DCNetwork_graph=nx.DiGraph() diff --git a/emuvim/example_topology.py b/emuvim/example_topology.py index 9412863..2342fd1 100755 --- a/emuvim/example_topology.py +++ b/emuvim/example_topology.py @@ -37,7 +37,6 @@ def create_topology1(): mon_api = ZeroRpcApiEndpointDCNetwork("0.0.0.0", 5151) mon_api.connectDCNetwork(net) mon_api.start() - """ 2. Add (logical) data centers to the topology (each data center is one "bigswitch" in our simplified -- 2.25.1