Create Date: Mar 3 2013 10:00AM
I found this solution and I believe it is worth sharing:
How to set the rate-limit on egress and ingress port?
Platform: Summit X450, X450a, and X450e, X460, X650, X440, X670, X350, X150, X480 and most BD8k platforms
Version: All EXOS
To set 20 M ingress and egress traffic from port 1
Create vlan test
Configure test tag 10
Configure test add po 1
Configure test ipa 10.10.10.1/24
Create vlan v2
Configure v2 tag 20
Configure v2 add po 2
Configure v2 ipa 20.20.20.1/24
ena ipf
Ixia------------------port (2) x450port (1) ----------------ixia
Set Ixia to send both way line rate traffic.
For Egress rate limit
Configure ports 1 rate-limit egress 20 Mbps => this will rate limit the egress traffic from port 1 to 20 M (doesn’t matter where this traffic is coming from)
Sh port 1, 2 utilization
Link Utilization Averages Thu Oct 2 22:46:10 2008
Port Link Link Receive Peak Rx Transmit Peak Transmit
Status Speed % bandwidth % bandwidth % bandwidth % bandwidth
================================================================================
1 A 1000 100.00 100.00 2.00 100.00
2 A 1000 100.00 100.00 100.00 100.00
================================================================================
Note: remember 20 Mbps for 1 gig port is 2%
For ingress rate limit
For all Broadcom platforms, we have to create a meter and link it to a policy for ingress rate limit,
Here are the steps to do that,
1. create and configure a meter
2. create a policy file and link this meter to that policy file
3. Now apply the policy to the ingress port.
Step-1 creates and configures a meter
Create meter meter-TEST1
Configure meter meter-TEST1 committed-rate 20 Mbps out-actions drop
Step-2 create a policy file and link this meter to that policy file
Edit policy blnmtlb2swe_TEST1.pol
entry rule1
{
if match all {
}
then
{
meter meter-TEST1;
}
}
Check policy blnmtlb2swe_TEST1
Configure access-list blnmtlb2swe_TEST1 ports 1 ingress => this will rate limit all the ingress traffic coming from port 1 to 20 M (doesn’t matter where this traffic is egressing)
Sh port 1, 2 utilization
Link Utilization Averages Thu Oct 2 22:46:10 2008
Port Link Link Receive Peak Rx Transmit Peak Transmit
Status Speed % bandwidth % bandwidth % bandwidth % bandwidth
================================================================================
1 A 1000 100.00 100.00 2.00 100.00
2 A 1000 100.00 100.00 2.00 100.00
================================================================================
Note: We have to remember that we configure the rate-limit on ingress port, but we can see the output on egress port (port 2)
(from ethernet)