Hi,

I can successfully install one wildcard. But when I want to install two
wildcards, the latter one will replace the first one. For example:
            match=parser.OFPMatch(ipv4_dst=('10.0.*2*
.0','255.255.255.0'),eth_type=0x800)
            actions=[parser.OFPActionOutput(5)]

inst=[parser.OFPInstructionActions(ofproto.OFPIT_APPLY_ACTIONS,actions)]

mod=parser.OFPFlowMod(datapath=datapath,table_id=1,priority=1,match=match,instructions=inst)
            datapath.send_msg(mod)

            match=parser.OFPMatch(ipv4_dst=('10.0.*3*
.0','255.255.255.0'),eth_type=0x800)
            actions=[parser.OFPActionOutput(5)]

inst=[parser.OFPInstructionActions(ofproto.OFPIT_APPLY_ACTIONS,actions)]

mod=parser.OFPFlowMod(datapath=datapath,table_id=1,priority=1,match=match,instructions=inst)
            datapath.send_msg(mod)
There will be only one wildcard, whose match is (10.0.3.0, 255.255.255.0).

But when I tried different priorities:
            match=parser.OFPMatch(ipv4_dst=('10.0.*2*
.0','255.255.255.0'),eth_type=0x800)
            actions=[parser.OFPActionOutput(5)]

inst=[parser.OFPInstructionActions(ofproto.OFPIT_APPLY_ACTIONS,actions)]
            mod=parser.OFPFlowMod(datapath=datapath,table_id=1,priority=*2*
,match=match,instructions=inst)
            datapath.send_msg(mod)

            match=parser.OFPMatch(ipv4_dst=('10.0.*3*
.0','255.255.255.0'),eth_type=0x800)
            actions=[parser.OFPActionOutput(5)]

inst=[parser.OFPInstructionActions(ofproto.OFPIT_APPLY_ACTIONS,actions)]
            mod=parser.OFPFlowMod(datapath=datapath,table_id=1,priority=*1*
,match=match,instructions=inst)
            datapath.send_msg(mod)
Both rules are installed successfully.

Could anyone tell me why?

Yuliang



2014-07-29 0:04 GMT+08:00 Yuliang Li <liyuliang...@gmail.com>:

> It works! Thanks!
>
>
> 2014-07-28 17:59 GMT+08:00 Wei-Li Tang <alex...@xinguard.com>:
>
> Hello,
>>
>> You can use a tuple to specify an IP network instead. For example,
>>
>> match = parser.OFPMatch(ipv4_dst=('10.0.0.0', '255.255.255.0'),
>> eth_type=0x0800)
>>
>>
>> 2014-07-28 17:34 GMT+08:00 Yuliang Li <liyuliang...@gmail.com>:
>>
>>> Hi all,
>>>
>>> I want to use wildcard in Ryu. But when I typed
>>>     "match=parser.OFPMatch(ipv4_dst='10.0.0.0/24',eth_type=0x800)",
>>> I got
>>>     "ValueError: IPAddress() does not support netmasks or subnet
>>> prefixes! See documentation for details".
>>>
>>> Could anyone tell me how to use wildcard in Ryu? Thanks a lot!
>>>
>>> Yuliang
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Infragistics Professional
>>> Build stunning WinForms apps today!
>>> Reboot your WinForms applications with our WinForms controls.
>>> Build a bridge from your legacy apps to the future.
>>>
>>> http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
>>> _______________________________________________
>>> Ryu-devel mailing list
>>> Ryu-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/ryu-devel
>>>
>>>
>>
>>
>> --
>> Sincerely,
>>
>> Wei-Li Tang
>> RD Engineer, Xinguard Inc.
>>
>
>
------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. 
Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
_______________________________________________
Ryu-devel mailing list
Ryu-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to