我使用OpenDaylight作为控制器在mininet上有一个简单的拓扑结构(1个交换机,2个主机)。我只希望这2个主机在它们之间进行通信(ICMP数据包),但是我不想使用l2switch插件,我试图学习如何手动配置流(使用OpenFlowPlugin)以便能够在这些主机之间进行PING。
我在OpenDaylight中安装了4个功能:odl-openflowjava-protocol; odl-openflowplugin-southbound; odl-openflowplugin-flow-services; odl-openflowplugin-flow-services-rest。
将拓扑连接到opendaylight之后,我将2个流放在交换机openflow:1上(使用Postman):
1º-将具有10.0.0.2/8(主机2地址)作为目标地址的所有流量发送到openflow:1:2端口。
网址:http://localhost:8181/restconf/config/opendaylight-inventory:nodes/node/openflow:1/table/0/flow/1
操作:PUT
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<flow xmlns="urn:opendaylight:flow:inventory">
<hard-timeout>0</hard-timeout>
<idle-timeout>0</idle-timeout>
<cookie>1</cookie>
<priority>0</priority>
<flow-name>flow1</flow-name>
<match>
<ipv4-destination>10.0.0.2/8</ipv4-destination>
</match>
<id>1</id>
<table_id>0</table_id>
<instructions>
<instruction>
<order>0</order>
<apply-actions>
<action>
<output-action>
<output-node-connector>2</output-node-connector>
</output-action>
<order>0</order>
</action>
</apply-actions>
</instruction>
</instructions>
</flow>
2º将所有具有10.0.0.1/8(主机1地址)作为目标地址的流量发送到openflow:1:1端口
网址:http://localhost:8181/restconf/config/opendaylight-inventory:nodes/node/openflow:1/table/0/flow/2
操作:PUT
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<flow xmlns="urn:opendaylight:flow:inventory">
<hard-timeout>0</hard-timeout>
<idle-timeout>0</idle-timeout>
<cookie>1</cookie>
<priority>0</priority>
<flow-name>flow2</flow-name>
<match>
<ipv4-destination>10.0.0.1/8</ipv4-destination>
</match>
<id>2</id>
<table_id>0</table_id>
<instructions>
<instruction>
<order>0</order>
<apply-actions>
<action>
<output-action>
<output-node-connector>1</output-node-connector>
</output-action>
<order>0</order>
</action>
</apply-actions>
</instruction>
</instructions>
</flow>
完成此步骤后,我仍然无法在主机之间ping通。我的问题是我在这里缺少什么/做错了什么,我需要创建什么流程才能在这两个主机之间进行ping操作?