Title: How to configure QOS on Ruijie Switch? [Print this page] Author: GTAC-Sophia Time: 2023-6-28 10:45 Title: How to configure QOS on Ruijie Switch? Application scenario:
Qos policy-map can associate ACL with QoS policy-map to implement rate limiting based on specific packet flows (for example, limiting http traffic only for web pages or limiting traffic only for users on the XX network segment). The flexible configuration of ACLs enables customers to customize rate limiting for different traffic. Of course, the configuration in this mode is relatively complicated. When the customer needs policy-map mode, it can be used to limit port limits.
It is similar to assigning a fixed bandwidth to a certain port. The control mode is simple and the configuration is simple. If the customer has the above requirements, you can use the rate-limit mode to limit the traffic rate. 1. Networking requirements:
All branches of an organization connect to the core switch through MSTP lines and share the unified network egress. Because branches have different scales, the administrator wants to set the uplink and download rates for the ports connected to each branch. 2.Networking topology:
3.configuration points: 1)Use policy-map to limit the rate
(1) Use ACL to classify traffic
(2) Configure the class-map ACL
(3) Associate Policy-map with class-map and set traffic policies
(4) The interface invokes Policy-map 2)Userate-limit to limit speed
(1) Apply rate-limit directly to the interface 4.configuration steps
1)Use ACL to classify traffic
Ruijie>en
Ruijie#config ter
Ruijie(config)#access-list 100 permit ip192.168.1.0 0.0.0.255 any ------> Define the data flows on network segment company a. If you want to match all the traffic, you can set it to permit ip any any
Ruijie(config)# class-map companya
Ruijie(config-cmap)# match access-group 100
Ruijie(config-cmap)#exit
Ruijie(config)# policy-map companya
Ruijie(config-pmap)#class companya
Ruijie(config-pmap-c)#police 10000 1024exceed-action drop
Ruijie(config-pmap-c)#exit
Ruijie(config-pmap)#exit
Ruijie(config)# interface gigabitEthernet 1/1
Ruijie(config-if-GigabitEthernet1/1)#service-policy input companya
------>
Note:
1.Run the rate-limit command to setthe rate limit and burst traffic. How to set the burst value? Consider thefollowing experience:
1) The burst value is in the range of(2,4,8,16,32,64, * *1024, 2*1024,4*1024,16*1024).
2) It is recommended that the buffercapacity of the token bucket be at least 200ms, that is, (CIR/8) x 200ms, thatis, the minimum recommended value = Rate limit /40
3) If unexpected services such asvideo and file transmission exist on the network, increase the token bucketcapacity to improve QOS burst tolerance.
According to the above threeprinciples, it is recommended to select the value of burst value (limit value/10) and select the value closest to the x power of 2.
2)Configurerate-limit to limit the rate of traffic on the port
Ruijie(config)#interface gigabitEthernet 1/1------> Enter the interface
Ruijie(config-if-GigabitEthernet 1/1)#rate-limitinput 10000 1024
Ruijie(config-if-GigabitEthernet 1/1)#rate-limitoutput 10000 1024
Ruijie(config)#interface gigabitEthernet 1/2------> Enter the interface
Ruijie(config-if-GigabitEthernet 1/2)#rate-limitinput 8000 1024
Ruijie(config-if-GigabitEthernet 1/2)#rate-limitoutput 8000 1024
Ruijie(config)#interface gigabitEthernet 1/3------> Enter the interface
Ruijie(config-if-GigabitEthernet 1/3)#rate-limitoutput 20000 2048
Ruijie(config-if-GigabitEthernet 1/3)#rate-limitoutput 20000 2048
------> Note:
1.Run the rate-limit command to set the rate limit and burst traffic. How to set the burst value? Consider the following experience:
1) The burst value is in the range of(2,4,8,16,32,64, * *1024, 2*1024,4*1024,16*1024).
2) It is recommended that the buffer capacity of the token bucket be at least 200ms, that is, (CIR/8) x 200ms, that is, the minimum recommended value = Rate limit /40
3) If unexpected services such as video and file transmission exist on the network, increase the token bucket capacity to improve QOS burst tolerance.
According to the above three principles, it is recommended to select the value of burst value (limit value/10) and select the value closest to the x power of 2.
Command interpretation:
rate-limit input|output kbps burst-bytes
Input | output: the user wants to limit the flow of Input or output.
kbps: indicates the rate upper limit of the traffic that the user wants. The unit is kbps.
Burst-bytes: This refers to the size of the burst traffic (token bucket size) in kb ytes. 5.Configurationverificatio
1)Runthe Ruijie#show policy-map interface gigabitEthernet 1/1 command to view theQOS policies called by the interface
GigabitEthernet 1/1 input (tc policy): companya
Class companya
current token tbf: NULL
params: 10000 kbps, 1024 limit, 0 extended limit , 0 pir
conformed 0 packets, 0 bytes; action: drop 0
exceeded 0 packets, 0 bytes; action: none 0
violated 0 packets, 0 bytes; action: none 0
cbucket 0, cbs 0; ebucket 0 ebs 0
2)Run the Ruijie#show mls qos rate-limit command to view the rate-limit policy of the interface
Interface: GigabitEthernet 1/1
rate limit input Kbps = 10000 burst = 1024
rate limit output Kbps = 10000 burst = 1024
Interface: GigabitEthernet 1/2
rate limit input Kbps = 10000 burst = 1024
rate limit output Kbps = 10000 burst = 1024
Interface: GigabitEthernet 1/3
rate limit input Kbps = 10000 burst = 1024
rate limit output Kbps = 10000 burst = 1024
Welcome to Ruijie Community (https://community.ruijienetworks.com/)