Hi,Allen

On 2014年12月25日 17:09, Allen wrote:
> Thank you very much! The DSCP value has remarked as your advice when the band 
> is exceeded.

I'm glad it worked.

thanks

> 
> 
> ------------------ 原始邮件 ------------------
> *发件人:* "Minoru TAKAHASHI";<[email protected]>;
> *发送时间:* 2014年12月25日(星期四) 中午1:15
> *收件人:* "Allen"<[email protected]>;
> *抄送:* "ryu-devel"<[email protected]>;
> *主题:* Re: [Ryu-devel] Problem About Dscp_Remark of Meter_Band_Type
> 
> Hi, Allen
> 
> On 2014年12月24日 21:04, Allen wrote:
>> Hello,
>>
>> 
>>
>> I encountered a problem that the DSCP_REMARK of Meter_Band_Type doesn’t work.
>>
>> 
>>
>> I was set the rate=1M and prec_level=3 in OFPMeterBandDscpRemark of bands 
>> and test by iperfdup 2M src dst in Mininet .However,when I am parsing the 
>> packets by wireshark,I found the dscp still keep the original 
>> value(ip_dscp=11).I can’t see any change.
> 
> OFspec 1.3.4 says:
>   The prec_level field indicates by which amount the drop precedence of the 
> packet should be increased
>   if the band is exceeded. This band increases the encoded drop precedence by 
> this amount, not the raw
>   DSCP value ; it always result in a valid DSCP value, and DSCP values that 
> do not encode a drop
>   precedence are not modified.
> 
> I think that there is a need to modify the setting of prec_level(now 3) and 
> DSCP value of the test packet(now 11).
> 
> For example, if you set these values as follows,
> 
>   bands = [parser.OFPMeterBandDscpRemark(rate=1000, burst_size=10, 
> prec_level=1)]
>   DSCP value of the test packet: 18 (AF21)
> 
> Then,if the band is exceeded, DSCP values will remark to 20(AF22).
> 
> thanks
> 
>>
>> 
>>
>> Partial code:
>>
>> 1:
>>
>> bands = [parser.OFPMeterBandDscpRemark(rate=1000, burst_size=10, 
>> prec_level=3)]
>>
>> meter_mod= parser.OFPMeterMod(datapath=datapath, command=ofproto.OFPMC_ADD,
>>
>>                               flags=ofproto.OFPMF_KBPS, meter_id=1, 
>> bands=bands)
>>
>> datapath.send_msg(meter_mod)
>>
>> 2:
>>
>> actions= [parser.OFPActionOutput(out_port)]
>>
>> match = parser.OFPMatch(in_port=in_port, 
>> eth_dst=dst,ip_proto=17,eth_type=0x0800)
>>
>> self.modify_meter(datapath, match,actions)
>>
>> 3:
>>
>> def modify_meter(self, datapath, match,actions):
>>
>>     ofproto = datapath.ofproto
>>
>>     parser = datapath.ofproto_parser
>>
>>     inst = [parser.OFPInstructionMeter(meter_id=1),
>>
>>             
>> parser.OFPInstructionActions(ofproto.OFPIT_APPLY_ACTIONS,actions)]
>>
>>     mod = parser.OFPFlowMod(datapath=datapath, command=ofproto.OFPFC_ADD,
>>
>>                           match=match, instructions=inst)
>>
>> datapath.send_msg(mod)
>>
>> 
>>
>> Environment:Ubuntu 12.04+Ryu+Mininet+Ofsoftswitch13
>>
>> 
>>
>> Thanks‍
>>
>>
>>
>> ------------------------------------------------------------------------------
>> Dive into the World of Parallel Programming! The Go Parallel Website,
>> sponsored by Intel and developed in partnership with Slashdot Media, is your
>> hub for all things parallel software development, from weekly thought
>> leadership blogs to news, videos, case studies, tutorials and more. Take a
>> look and join the conversation now. http://goparallel.sourceforge.net
>>
>>
>>
>> _______________________________________________
>> Ryu-devel mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/ryu-devel
>>

------------------------------------------------------------------------------
Dive into the World of Parallel Programming! The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to