- 檢查Pica OS的版本 (only for L2/L3 mode)
#cli - 設定下次開機預設使用的是OVS mode or L2/L3 mode
#sudo picos_boot - 新增OpenFlow Bridge br1
#ovs-vsctl add-br br1 -- set bridge br1 datapath_type=pica8 - 設定br1的OpenFlow Version
目前分類:SDN (8)
- Apr 09 Thu 2015 21:03
[OpenFlow]Pica OS 筆記
- Oct 16 Thu 2014 00:04
在RYU上使用Rest API控制flow entry Part 2/2 (match field 有mask)
- Jul 27 Sun 2014 00:45
Ryu REST API 不同Match Field的下法 Part 2
我已經儘全力了,最右邊還是很大一格,不會自己換行,大家可以用複製的,就可以看到完整的語法了。
Index | Field | Ryu Rest API 語法 |
20 | OXM_OF_ICMPV4_TYPE |
curl -X POST -d '{"dpid":"0000000000000001", "priority":"32766","match":{"eth_type":2048,"ip_proto":1,"icmpv4_type":1}, "actions":[{"type":"OUTPUT","port":2}]}' http://127.0.0.1:8080/stats/flowentry/add |
21 | OXM_OF_ICMPV4_CODE |
curl -X POST -d '{"dpid":"0000000000000001", "priority":"62766","match":{"eth_type":2048,"ip_proto":1,"icmpv4_code":1}, "actions":[{"type":"OUTPUT","port":30}]}' http://127.0.0.1:8080/stats/flowentry/add |
22 | OXM_OF_ARP_OP |
curl -X POST -d '{"dpid":"0000000000000001", "priority":"22766","match":{"eth_type":0x0806,"arp_op":1}, "actions":[{"type":"OUTPUT","port":30}]}' http://127.0.0.1:8080/stats/flowentry/add |
- Jul 25 Fri 2014 21:52
Ryu REST API 不同Match Field的下法 Part 1
Index | Field | Ryu Rest API 語法 |
1 | OXM_OF_IN_PORT | ~# curl -X POST -d '{"dpid":"0000000000000001", "priority":"32766","match":{"in_port":2}, "actions":[{"type":"OUTPUT","port":1}]}' http://127.0.0.1:8080/stats/flowentry/add |
2 | OXM_OF_IN_PHY_PORT | N/A |
3 | OXM_OF_METADATA |
curl -X POST -d '{"dpid":"0000000000000001", "priority":"32766","match":{"metadata":"1234567890"}, "actions":[{"type":"OUTPUT","port":1}]}' http://127.0.0.1:8080/stats/flowentry/add |
4 | OXM_OF_ETH_DST |
curl -X POST -d '{"dpid":"0000000000000001", "priority":"32766","match":{"eth_dst":"00:11:22:33:44:55"}, "actions":[{"type":"OUTPUT","port":1}]}' http://127.0.0.1:8080/stats/flowentry/add |
5 | OXM_OF_ETH_SRC |
curl -X POST -d '{"dpid":"0000000000000001", "priority":"32766","match":{"eth_src":"00:11:22:33:44:55"}, "actions":[{"type":"OUTPUT","port":1}]}' http://127.0.0.1:8080/stats/flowentry/add |
6 | OXM_OF_ETH_TYPE |
curl -X POST -d '{"dpid":"0000000000000001", "priority":"32766","match":{"eth_type":0x86dd}, "actions":[{"type":"OUTPUT","port":1}]}' http://127.0.0.1:8080/stats/flowentry/add |
- Jul 17 Thu 2014 21:18
OpenFlow 1.3 縮寫解釋
在OpenFlow的Spec.裡,常會提到一些縮寫字,但是並沒有一個名詞解釋的總表,所以我自己作了一點,提供給大家作參考
Name | Type |
OFPFC_* | OpenFlow Protocol Flow Control |
OFPPC_* | OpenFlow Protocol Port (role) Control |
OFPET_* | OpenFlow Protocol Error Type |
OFPBMC_* | OpenFlow Protocol Bad Match Code |
OFPBAC_* | OpenFlow Protocol Bad Action Code |
OFPFMC_* | OpenFlow Protocol Flow Modification Code |
OFPGC_* | OpenFlow Protocol Group Command |
OFPPS_* | OpenFlow Protocol Port Status |
OFPPC_* | OpenFlow Protocol Port Config |
OFPMC_* | OpenFlow Protocol Meter Command |
OFPGMFC_* | OpenFlow Protocol Group Modification Failed Code |
OFPMMFC_* | OpenFlow Protocol Meter Modification Failed Code |
OFPT_* | OpenFlow Protocol Type |
OFPP_* | OpenFlow Protocol Port |
OFPPF_ | OpenFlow Protocol Port Feature |
OFPQT_* | OpenFlow Protocol Queue Property(??) |
OFPQ_* | OpenFlow Protocol Queue (??) |
OFPXMC_* | OpenFlow Protocol Extensible Match ClassID |
OFPXMT_OFB_* | OpenFlow Protocol Extensible Match Type_ OpenFlow Basic |
OFPIEH_* | OpenFlow Protocol IPv6 Extension Header |
OFPIT_* | OpenFlow Protocol Insturction Type |
OFPAT_* | OpenFlow Protocol Action Type |
OFPCML_* | OpenFlow Protocol Controller Maximum Length |
OFPC_* | OpenFlow Protocol Capacity |
OFPTT_* | OpenFlow Protocol Table Type |
OFPFF_* | OpenFlow Protocol Flow Flag |
OFPMF_* | OpenFlow Protocol Meter Flag |
OFPMBT_* | OpenFlow Protocol Meter Band Type |
OFPBRC_* | OpenFlow Protocol Bad Request Code |
OFPMP_* | OpenFlow Protocol MultiPart |
OFPTFPT_* | OpenFlow Protocol Table Feature Property Type |
OFPR_* | OpenFlow Protocol Reason (ofp_packet_in_reason) |
OFPPR_* | OpenFlow Protocol Port Reason (ofp_port_reason) |
OFPRR_* | OpenFlow Protocol Flow Remove Reason |
- Jul 08 Tue 2014 23:16
OpenFlow 1.3 PCAP File
以下內容的PCAP檔,可以在下面連結下載。
https://box.nctu.edu.tw/public.php?service=files&t=e8f8a4ff004b8912991d441db8ee19da
拓撲:
(Mininet 2.1.0 192.168.100.7)<---->(RYU Controller 192.168.100.8)
- Jul 03 Thu 2014 00:20
套用封包產生器packETH於mininet OpenFlow環境
學會安裝封包產生器之後,免不了要打打看封包,這裡介紹如何將封包產生器和mininet結合
1. 首先,參考這篇,將Ryu&WEB GUI啟動起來,但是啟動RYU的指令,要換成下面這行,OpenFlow_13才支援等下要作的Push Vlan喔。
#./bin/ryu-manager --verbose --observe-links ryu/topology/switches.py ryu/app/rest_topology.py ryu/app/ofctl_rest.py ryu/app/simple_switch_13.py
2. 接著參考這裡,mininet啟動起來。指令換成下面這行,如此啟動起來的mininet才支援OpenFlow13。
- Jun 02 Mon 2014 14:08
在RYU上使用Rest API控制flow entry part 1/2 (match field 沒有mask)
import了SDN hub的VM後,總是會想要試看看能不能下個Flow Entry,
現在就來試看看如何手動設定flow entry。
1. 啟動SDN HUB VM內的mininet。
#sudo mn --controller=remote --switch ovsk,protocols=OpenFlow13