OpenFlow協議-OpenFlow Switch篇

OpenFlow Switch:

1.Switch Anatomy

            

                                                               圖1 switch anatomy                                                                                                

switch-agent通過OpenFlow協議與一個或多個controllers交互,另外,也通過內部協議與data plane通信。Switch-agent翻譯從controller獲得的命令到低層的指導發送給data plane模塊,並通告內部的data plane模塊到controller.

data plane實現包轉發和處理,然而,根據配置信息,有的時候會將數據包發送給switch-agent來進一步處理。

2.Switch Agent

 

圖2 switch agent

data plane offload: 通常,控制平面會offload OpenFlow中存在的一些功能,但不提供現有的數據平面來實現。

core logic:管理switch,執行data plane命令,管理data plane offload.

OpenFlow protocol: switch端協議

data plane protocol: 用來配置data plane state的內部協議

3.Data Plane


圖3 Data Plane

包括:ports, flow table, flows, classifiers and actions.

數據包通過port到達和離開,數據包使用classifiers模塊,根據flow tables匹配到flows.

flows包括actions集合,和每個數據包匹配到的相對應

classifier, 將每一個數據包和流表中的流入口匹配.

Instructions and actions:一旦數據包匹配到了流入口(在流表中),管理數據包被如何處理

Data plane- packet lifecycle

每個數據包在穿越交換機data plane時具有相同的行爲,當數據包到達時,key被建立,包含從數據包獲得的信息,例如幾個協議域的值,以及從數據包收集到的metadata,例如到達arrival port, arrival time, etc. The key被用來在flow table中選擇一個particular flow,以及相關的action。action包括drop, mutate, queue, forward, or direct that packet to a new flow table。

Packet Arrival:數據包到達在端口,可以是物理端口或虛擬的。記錄到達端口的信息爲後續的source-based processing in the pipeline是很重要的。

Key Extraction:每一個數據包都有很小的元數據模塊部分,called the key, after arrival. key包括several fields from within the packet as well as side information suck as: location of the buffered packet, header values, arrival port, arrival clock, etc. The key is what is fed to the rest of the pipeline.

Table Selection: key用來查找table,然而,多個table可能存在。這種情況下一個table一定要被首先選擇出來,當數據包第一次通過pipeline,默認第一個表將會被選擇。後續的表可能被選擇通過actions或者table misses.

Flow Selection: key用來在table中選擇一個flow, classifier包含匹配key的第一個flow of a table將會是選中的flow.

Action Application: 每一個行包含一個actions集合,來應用到所有的匹配包。當一個流選中了對應的action,將會被執行在相關的數據包上。Actions可能會修改包的state or/and影響treatment of the packet.



http://flowgrammable.org/sdn/openflow/#tab_switch

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