OcNOS-RON : Quality of Service Guide : Quality of Service Configuration Guide : Shaping Configuration : L2/L3 Interface
L2/L3 Interface
The following steps describe how to configure Shaping.
 
#configure terminal
Enter configure mode.
(config)#qos enable
Enable QoS globally.
(config)#qos statistics
Enable QoS statistics.
(config)#commit
Committing the configuration
(config)#policy-map type queuing default P1
Configure policy-map of type queuing with name P1, and enter into policy-map mode
(config-pmap-que)#class type queuing default q0
Configure class type queuing of type default and enter into class map configuration mode
(config-pmap-c-que)#shape 200 mbps
Configure shaping to 200 mbps
(config-pmap-c-que)#exit
Exit out of policy-class mode
(config-pmap-que)#exit
Exit out of Policy-map mode
(config)#class-map type qos c1
Enter Class-map mode
(config-cmap-qos)#match dscp 10
Configure match criteria as dscp 10
(config-cmap-qos)#match cos 3
Configure match criteria as cos 3
(config-cmap-qos)#exit
Exit out of class-map mode
(config)#class-map type qos c2
Enter Class-map mode
(config-cmap-qos)#match dscp 22
Configure match criteria as dscp 22
(config-cmap-qos)#match cos 4
Configure match criteria as cos 4
(config-cmap-qos)#exit
Exit out of class-map mode
(config)#policy-map type qos pmap1
Configure policy-map with name pmap1 and enter policy-map mode
(config-pmap-qos)#class type qos c1
Assign Class c1 to Policy-map pmap1
(config-pmap-c-qos)#set queue 2
Set queue 2 for frames with either cos 3 or dscp 10
(config-pmap-c-qos)#exit
Exit out of pmap-c mode
(config-pmap-qos)#class type qos c2
Assign Class c2 to Policy-map pmap1
(config-pmap-c-qos)#set queue 3
Set queue 3 for frames with either cos 4 or dscp 22
(config-pmap-c-qos)#exit
Exit out of pmap-c mode
(config-pmap-qos)#exit
Exit policy-map mode
(config)#interface xe3
Enter interface mode
(config-if)#service-policy type queuing output P1
Attach service-policy P1 of type queuing on out direction
(config-if)#exit
Exit out of interface mode
(config)#interface xe2
Enter interface mode
(config-if)#service-policy type qos input pmap1
Attach service-policy pmap1 of type qos on in direction
(config-if)#exit
Exit out of interface mode
(config)#bridge 1 protocol rstp vlan-bridge
Specify VLAN for bridge 1.
(config)#vlan database
Enter the VLAN configuration mode.
(config-vlan)#vlan 2-3 bridge 1 state enable
Enable VLAN (2-3) on bridge 1. Specifying the enable state.
(config-vlan)#exit
Exit the VLAN configuration mode.
(config)#interface vlan1.2
Enter interface mode.
(config-if)# ip address 10.1.1.2/24
Configure the IP address.
(config-if)#exit
Exit the interface mode.
(config)#interface vlan1.3
Enter interface mode.
(config-if)# ip address 20.1.1.1/24
Configure the IP address.
(config-if)#exit
Exit the interface mode.
(config)#interface xe2
Enter interface mode.
(config-if)#switchport
Configure xe2 as a Layer 2 port.
(config-if)#bridge-group 1
Associate the interface with bridge group 1.
(config-if)#switchport mode trunk
Configure port as a trunk.
(config-if)#switchport trunk allowed vlan all
Allow all the VLANs on the xe3 interface.
(config-if)#exit
Exit the interface mode.
(config)#interface xe3
Enter interface mode.
(config-if)#switchport
Configure xe3 as a Layer 2 port.
(config-if)#bridge-group 1
Associate the interface with bridge group 1.
(config-if)#switchport mode trunk
Configure port as a trunk.
(config-if)#switchport trunk allowed vlan all
Allow all the VLANs on the xe3 interface.
(config-if)#exit
Exit the interface mode
(config)#commit
Committing the configuration
Last modified date: 07/14/2023