Floodlight+mininet測試OpenFlow方法

首先啓動floodlight控制器和預裝有mininet的虛擬機

控制器:192.168.56.1

虛擬機:192.168.56.99


啓動控制器日誌:

09:46:08.359 INFO [n.f.c.m.FloodlightModuleLoader:main] Loading default modules
09:46:09.756 INFO [n.f.c.i.Controller:main] Controller role set to MASTER
09:46:09.806 INFO [n.f.c.i.Controller:main] Flush switches on reconnect -- Disabled
09:46:12.733 INFO [n.f.l.i.LinkDiscoveryManager:main] Setting autoportfast feature to OFF
09:46:13.494 INFO [o.s.s.i.c.FallbackCCProvider:main] Cluster not yet configured; using fallback local configuration
09:46:13.495 INFO [o.s.s.i.SyncManager:main] [32767] Updating sync configuration ClusterConfig [allNodes={32767=Node [hostname=localhost, port=6642, nodeId=32767, domainId=32767]}, authScheme=CHALLENGE_RESPONSE, keyStorePath=/etc/floodlight/auth_credentials.jceks, keyStorePassword is unset]
09:46:13.799 INFO [o.s.s.i.r.RPCService:main] Listening for internal floodlight RPC on localhost/127.0.0.1:6642
09:46:14.458 INFO [n.f.c.i.Controller:main] Listening for switch connections on 0.0.0.0/0.0.0.0:6633
09:46:18.488 INFO [n.f.j.JythonServer:debugserver-main] Starting DebugServer on :6655


虛擬機中啓動mininet,控制器設置爲192.168.56.1

mn --controller=remote --ip=192.168.56.1 --port=6633

frontpage_diagram.png

可以更改參數改變網絡拓撲的情況具體操作方法見mininet文檔。

可以通過ssh -X轉發方式連接到虛擬機上,打開虛擬機中的wireshark,抓包分析openflow包。

可以在虛擬機中配置虛擬交換機的流表項:

dpctl add-flow tcp:127.0.0.1:6634 in_port=1,actions=output:1


發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章