Posted on October 9, 2017 11:02 am
 |  Asked by Mansur Efendi
 |  8345 views
0
0
Print Friendly, PDF & Email

Hi,

I want to configure rate limit on interface ethernet 4 on Arista Switch. For egress, I have configured with shape command on interface :

#sh run int eth 4

interface Ethernet4

   switchport access vlan 65

   shape rate 300000

 

#show qos interfaces et 4

Ethernet4:

   Trust Mode: COS

   Default COS: 0

   Default DSCP: 0

 

   Port shaping rate: 300000 / 300000 kbps

 

  Tx       Bandwidth                 Shape Rate        Priority  ECN

 Queue     Guaranteed (units)         (units)

   ——————————————————————

   7        – / –    (  –  )       – / –    (  –  )    SP / SP    D

   6        – / –    (  –  )       – / –    (  –  )    SP / SP    D

   5        – / –    (  –  )       – / –    (  –  )    SP / SP    D

   4        – / –    (  –  )       – / –    (  –  )    SP / SP    D

   3        – / –    (  –  )       – / –    (  –  )    SP / SP    D

   2        – / –    (  –  )       – / –    (  –  )    SP / SP    D

   1        – / –    (  –  )       – / –    (  –  )    SP / SP    D

   0        – / –    (  –  )       – / –    (  –  )    SP / SP    D

 

Note: Values are displayed as Operational/Configured

 Thank you

 

0
Posted by Pranav Doshi Doshi
Answered on October 19, 2017 6:18 pm

Hi Masur,

 

You can use storm-control to rate-limit the traffic ingressing on a port. You can choose the type of traffic you want to rate-limit.

Switch(config-if-Et8/3)#storm-control ?

  all              Configure storm control for all packets

  broadcast        Configure storm control for broadcast packets

  multicast        Configure storm control for multicast packets

  unknown-unicast  Configure storm control for uknown unicast packets

0
Posted by Akshay Viswakumar
Answered on October 20, 2017 7:00 am

Hey Mansur,

 

What you’ve mentioned looks like the right way to rate limit traffic in the egress direction.

 

You can actually go even more granular with this and shape the traffic for each Tx queue.

 

(config)#int et 2

(config-if-Et2)#tx-queue 0

(config-if-Et2-txq-0)#shape rate ?

  <50000-100000000>  Shape Rate Kbps

(config-if-Et2-txq-0)#shape rate 50000

(config-if-Et2-txq-0)#tx-queue 2

(config-if-Et2-txq-2)#shape rate 60000

(config-if-Et2-txq-2)#tx-queue 3

(config-if-Et2-txq-3)#shape rate 70000

(config-if-Et2-txq-3)#tx-queue 4

(config-if-Et2-txq-4)#shape rate 50000

(config-if-Et2-txq-4)#exit

(config-if-Et2)#show qos interfaces et2

 

Ethernet2:

 

   Trust Mode: DSCP

   Default COS: 0

   Default DSCP: 0

 

 

   Port shaping rate: disabled

 

 

  Tx    Bandwidth       Shape Rate        Priority  ECN/WRED

 Queue  (percent)        (units)

 ————————————————————

   7      – / –         – / –     ( – )    SP / SP       D

   6      – / –         – / –     ( – )    SP / SP       D

   5      – / –         – / –     ( – )    SP / SP       D

   4      – / –      50.0 / 50.0  (Mbps)   SP / SP       D

   3      – / –      70.0 / 70.0  (Mbps)   SP / SP       D

   2      – / –      60.1 / 60.0  (Mbps)   SP / SP       D

   1      – / –         – / –     ( – )    SP / SP       D

   0      – / –      50.0 / 50.0  (Mbps)   SP / SP       D

 

Note: Values are displayed as Operational/Configured

 

Legend:

RR -> Round Robin

SP -> Strict Priority

 –  -> Not Applicable / Not Configured

ECN/WRED: L -> Queue Length ECN Enabled     W -> WRED Enabled     D -> Disabled

 

 

For ingress, you can try out “policy-map type qos” (mentioned here: https://www.arista.com/en/um-eos/eos-section-26-7-traffic-management-configuration-commands)

 

This will let you configure a policer for ingress rate limiting.

 

The config is a little trickier and goes something like this.

 

1. Create a policy-map

 

(config)#policy-map test1

(config-pmap-qos-test1)#class class-default  [Note: class-default is important here since this is the default class that matches all traffic]

 

Now configure the policer for your requirement. (It’s a single rate two-color policer)

 

(config-pmap-c-qos-test1-class-default)#police cir 100 ?

  bc    Set committed burst rate

  bps   rate in bps (default unit)

  kbps  rate in Kbps

  mbps  rate in Mbps

(config-pmap-c-qos-test1-class-default)#police cir 100 kbps ?

  bc  Set committed burst rate

(config-pmap-c-qos-test1-class-default)#police cir 100 kbps bc ?

  <integer value>  specify burst value

(config-pmap-c-qos-test1-class-default)#police cir 100 kbps bc 10 ?

  bytes   burst size in bytes (default unit)

  kbytes  burst size in kbytes

  mbytes  burst size in mbytes

  <cr>

(config-pmap-c-qos-test1-class-default)#police cir 100 kbps bc 10 kbytes

(config-pmap-c-qos-test1-class-default)#exit

(config-pmap-qos-test1)#exit

(config)#show policy-map test1

Service-policy test1

 

  Class-map: class-default (match-any)

       police cir 100 kbps bc 10 kbytes

 

2. Apply the policy to the interface

 

(config)#int et 2

(config-if-Et2)#service-policy type qos input test1

 

You can check then check the status with this command.

 

(config)#show policy-map test1 summary

Service-policy input: test1

  Hardware programming status: Successful

  Configured on: Ethernet2

Hope this helps!! :D

 

0
Posted by Harsh Mehta
Answered on December 5, 2017 8:22 am

hello Team 

 

i am trying to figure out inegress rate limiting for a customer for 7020R

 

I applied following commands to shape rate for egress

interface Ethernet4

   switchport access vlan 703

 

   shape rate 162

 

For in egress i am not able to define a policy map nor a class map it says paltform does not support , any other workaround for this .

 

dm1-264sw29(config-vlan-703)#exit

  class-map  not supported on this hardware platform

 

 

  class-map  not supported on this hardware platform

 

dm1-264sw29(config-pmap-qos-test1)#class ?

  WORD  Class Map Name

 

dm1-264sw29(config-pmap-qos-test1)#class xyz-162    

 

  police  not supported on this hardware platformce

 

Any suggestions will be appreciated.

 

0
Posted by Sachin M Menon
Answered on December 7, 2017 11:24 am

Hi Harsh,

Currently, we do not support QOS based policy-maps on 7020R platform. We already have an RFE filed to track this feature and would request you to contact the Arista sales team for the ETA.

 

Thanks,

Sachin

0
Posted by vijay duggal
Answered on November 14, 2018 6:31 am

Hello ,

Is it possible to shape traffic at much granular interval like 50-100 mics ?, like on 1 G interface i want to set shape rate at 500Mbps, so is it possible to set at lower level?

Post your Answer

You must be logged in to post an answer.