FR WRED configuration example
Network requirements
As shown in Figure 50,
Router A connects to Router B through an FR network.
Configure WFQ for the FR PVCs of Router A and enable DSCP-based WRED.
On PVCs of Router B, allocate bandwidth for packets with the specific DSCP values and enable DSCP-based WRED for these packets, and configure WFQ and the WRED policy for the other packets.
Figure 50: Network diagram
Configuration procedure
Configure Router A:
# Create traffic behavior wfqwred and configure WFQ and WRED actions in the behavior.
[RouterA] traffic behavior wfqwred [RouterA-behavior-wfqwred] queue wfq queue-number 256 [RouterA-behavior-wfqwred] queue-length 512 [RouterA-behavior-wfqwred] wred dscp [RouterA-behavior-wfqwred] wred dscp af11 low-limit 5 high-limit 10 discard-probability 6 [RouterA-behavior-wfqwred] wred dscp af21 low-limit 10 high-limit 20 discard-probability 8 [RouterA-behavior-wfqwred] quit
# Create QoS policy test and associate traffic behavior wfqwred with the default class default-class in the QoS policy.
[RouterA] qos policy test [RouterA-qospolicy-test] classifier default-class behavior wfqwred [RouterA-qospolicy-test] quit
# Create FR class frclass and apply QoS policy test to FR class frclass.
[RouterA]fr class frclass [RouterA-fr-class-frclass] apply policy test outbound [RouterA-fr-class-frclass] quit
# Configure FR-related parameters for interface Serial 2/1.
[RouterA] interface Serial 2/1 [RouterA-Serial2/1] link-protocol fr [RouterA-Serial2/1] fr map ip 192.168.1.2 60 [RouterA-Serial2/1] ip address 192.168.1.1 255.255.255.0
# Configure the maximum reserved bandwidth for queues on interface Serial 2/1.
[RouterA-Serial2/1] qos reserved-bandwidth pct 70
# Apply the FR class frclass to DLCI 60 of interface Serial 2/1.
[RouterA-Serial2/1] fr dlci 60 [RouterA-fr-dlci-Serial2/1-60] fr-class frclass
Configure Router B:
# Create traffic class af11_31 and configure the class to match DSCP AF11 or AF31.
<RouterB> system-view [RouterB] traffic classifier af11_31 operator or [RouterB-classifier-af11_31] if-match dscp af11 [RouterB-classifier-af11_31] if-match dscp af31 [RouterB-classifier-af11_31] quit
# Create behavior afwred and configure AF and WRED actions in the behavior.
[RouterB] traffic behavior afwred [RouterB-behavior-afwred] queue af bandwidth pct 50 [RouterB-behavior-afwred] wred dscp [RouterB-behavior-afwred] wred dscp af11 low-limit 10 high-limit 40 discard-probability 15 [RouterB-behavior-afwred] wred dscp af31 low-limit 10 high-limit 60 discard-probability 20 [RouterB-behavior-afwred] quit
# Create traffic behavior wfqwred and configure WFQ and WRED actions in the behavior.
[RouterB] traffic behavior wfqwred [RouterB-behavior-wfqwred] queue wfq [RouterB-behavior-wfqwred] wred dscp [RouterB-behavior-wfqwred] wred dscp 0 low-limit 10 high-limit 20 discard-probability 8 [RouterB-behavior-wfqwred] quit
# Create QoS policy test, and associate the default class default-class with behavior wfqwred and class af11_31 with behavior afwred in the QoS policy.
[RouterB] qos policy test [RouterB-qospolicy-test] classifier default-class behavior wfqwred [RouterB-qospolicy-test] classifier af11_31 behavior afwred [RouterB-qospolicy-test] quit
# Create FR class frclass and apply QoS policy test to the class.
[RouterB]fr class frclass [RouterB-fr-class-frclass] apply policy test outbound [RouterB-fr-class-frclass] quit
# Configure FR-related parameters for interface Serial 2/2.
[RouterB] interface serial 2/2 [RouterB-Serial2/2] link-protocol fr [RouterB-Serial2/2] ip address 192.168.1.2 255.255.255.0 [RouterB-Serial2/2] fr traffic-shaping [RouterB-Serial2/2] fr map ip 192.168.1.1 50
# Configure the maximum reserved bandwidth for queues on Serial 2/2.
[RouterB-Serial2/2] qos reserved-bandwidth pct 70
# Apply FR class frclass to DLCI 50.
[RouterB-Serial2/2] fr dlci 50 [RouterB-fr-dlci-Serial2/2-50] fr-class frclass