run_mininet: Specify the controller port

In the latest mininet, the default controller port has been updated
to 6653, but currently the default port of Ryu is 6633.

This patch specifies the controller port by using the constant from
Ryu ofproto module.

Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
IWASE Yusuke 2016-02-22 13:29:51 +09:00 committed by FUJITA Tomonori
parent f2bb13dbb5
commit 4d8c6d3a7c

View File

@ -10,6 +10,8 @@ from mininet.node import UserSwitch
from oslo_config import cfg
from ryu import version
from ryu.ofproto.ofproto_common import OFP_TCP_PORT
if '__main__' == __name__:
@ -30,7 +32,7 @@ if '__main__' == __name__:
net = Mininet(switch=switch, controller=RemoteController)
c0 = net.addController('c0')
c0 = net.addController('c0', port=OFP_TCP_PORT)
s1 = net.addSwitch('s1')
s2 = net.addSwitch('s2')