Hi Ryu Developers,

Could you please help me with the following REST API query ?

I need to configure  a new learning flow on the switch through a new REST API 
with given input parameters.

I took the json example given in the following path
https://github.com/osrg/ryu/blob/a3c8c591d9e6fe1353f7ba54f56a40f09d301f79/ryu/tests/unit/ofproto/json/of13/libofproto-OFP13-flow_mod.packet.json
and tried to frame the following command to give it as an input to ofctl 
mod_flow_entry() function 

#########################################################################################################

cookie=0
cookie_mask=0 
flags=0
hard_timeout=0
idle_timeout=0
priority=10
table_id=0

instructions=[parser.OFPInstructionActions(dp.ofproto.OFPIT_APPLY_ACTIONS,[parser.NXActionLearn(cookie=0,
 experimenter=8992, fin_hard_timeout=0, fin_idle_timeout=0, flags=0, 
hard_timeout=300, idle_timeout=0, priority=2, specs=[ { 
parser.NXFlowSpecMatch(dst=[ "00:00:00:00:00:01", 0 ], n_bits=48, src=[ 
"00:00:00:00:00:02", 0 ] ) }, { parser.NXFlowSpecLoad( dst=[ 100, 0 ], 
n_bits=12, src=0 ) }, { parser.NXFlowSpecLoad( dst=[ 12, 0 ], n_bits=64, src=[ 
24, 0 ] ) }, { parser.NXFlowSpecOutput(dst="", n_bits=32, src=[ 1, 1 ] ) } ], 
subtype=16, table_id=99 )]), parser.OFPInstructionGotoTable(100)]

msg = parser.OFPFlowMod(datapath     = dp,
                                priority     = priority,
                                table_id     = table_id,
                                instructions = instructions)
dp.send_msg(msg)


#########################################################################################################

This learning flow is not getting configured on the switch due to command  
syntax error.
There is some mistake with the command syntax.

Could you please send me an example of a learning flow similar to what i have 
done ? or is it possible to point out the mistake in above syntax ?
Thank you.

Regards,
Karthika Krishnamurthy.
------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity planning
reports.http://sdm.link/zohodev2dev
_______________________________________________
Ryu-devel mailing list
Ryu-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to