From: Victor Cappuccio (vcappuccio@desca.com)
Date: Sun Jan 28 2007 - 22:20:15 ART
If you want to do it using New Style IOS MQC :D
then look here:
http://www.cisco.com/warp/public/105/qos_subint.html
it says that:
Cisco IOS logical interfaces do not inherently support a state of congestion and do not support the direct application of a service policy that applies a queueing method. Instead, you first need to apply shaping to the subinterface using either generic traffic shaping (GTS) or class-based shaping.
Configuration Steps:
Applying a Hierarchical Policy
Follow these steps to apply a hierarchical policy:
1.
Create a child or lower-level policy that configures a queueing mechanism. In the example below, we configure LLQ using the priority command and CBWFQ using the bandwidth command. Refer to Congestion Management Overview for more information.
policy-map child
class voice
priority 512
2.
Create a parent or top-level policy that applies class-based shaping. Apply the child policy as a command under the parent policy since the admission control for the child class is done based on the shaping rate for the parent class.
policy-map parent
class class-default
shape average 2000000
service-policy child
3.
Apply the parent policy to the subinterface.
interface ethernet0/0.1
service-policy parent
R3 S0.23 --- Fr -- R2
R3(config)#class-map voice
R3(config-cmap)#ma ip dscp ef
R3(config-cmap)#exit
R3(config)#policy-map child
R3(config-pmap)#class voice
R3(config-pmap-c)#priority 512
R3(config-pmap-c)#
R3(config-pmap-c)#policy-map parent
R3(config-pmap)#class class-default
R3(config-pmap-c)#shape average 512000
R3(config-pmap-c)#service-policy child
R3(config-pmap-c)#int s0.23
R3(config-subif)#ser out parent
R3(config-subif)#do show frame-relay map
Serial0.23 (up): point-to-point dlci, dlci 302(0x12E,0x48E0), broadcast
status defined, active
R3(config-subif)#do show policy-map inter s0.23
Serial0.23
Service-policy output: parent
Class-map: class-default (match-any)
0 packets, 0 bytes
5 minute offered rate 0 bps, drop rate 0 bps
Match: any
Traffic Shaping
Target/Average Byte Sustain Excess Interval Increment
Rate Limit bits/int bits/int (ms) (bytes)
2000000/2000000 12500 50000 50000 25 6250
Adapt Queue Packets Bytes Packets Bytes Shaping
Active Depth Delayed Delayed Active
- 0 0 0 0 0 no
Service-policy : child
Class-map: voice (match-all)
0 packets, 0 bytes
5 minute offered rate 0 bps, drop rate 0 bps
Match: ip dscp ef
Queueing
Strict Priority
Output Queue: Conversation 72
Bandwidth 512 (kbps) Burst 12800 (Bytes)
(pkts matched/bytes matched) 0/0
(total drops/bytes drops) 0/0
Class-map: class-default (match-any)
0 packets, 0 bytes
5 minute offered rate 0 bps, drop rate 0 bps
Match: any
R3(config-subif)#
R3(config-subif)#do show frame-relay pvc 302
PVC Statistics for interface Serial0 (Frame Relay DTE)
DLCI = 302, DLCI USAGE = LOCAL, PVC STATUS = ACTIVE, INTERFACE = Serial0.23
input pkts 163269 output pkts 119204 in bytes 14618202
out bytes 12180126 dropped pkts 0 in pkts dropped 0
out pkts dropped 0 out bytes dropped 0
in FECN pkts 0 in BECN pkts 0 out FECN pkts 0
out BECN pkts 0 in DE pkts 0 out DE pkts 0
out bcast pkts 85659 out bcast bytes 10166564
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
pvc create time 1w1d, last time pvc status changed 1w1d
I found this link for Subinterface http://www.cisco.com/warp/public/63/idb_limit.html
Verification:
R3(config-pmap-c)#do ping
Protocol [ip]:
Target IP address: 192.168.23.2
Repeat count [5]: 1486
Datagram size [100]: 100
Timeout in seconds [2]: 0
Extended commands [n]: y
Source address or interface:
Type of service [0]: 0Xb8 !! SET EF BIT
Set DF bit in IP header? [no]:
Validate reply data? [no]:
Data pattern [0xABCD]:
Loose, Strict, Record, Timestamp, Verbose[none]:
Sweep range of sizes [n]:
Type escape sequence to abort.
Sending 512000, 100-byte ICMP Echos to 192.168.23.2, timeout is 0 seconds:
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
......................................................................
Success rate is 0 percent (0/1486)
R3(config-pmap-c)#do show policy-map int s0.23
Serial0.23
Service-policy output: parent
Class-map: class-default (match-any)
1518 packets, 159496 bytes
5 minute offered rate 4000 bps, drop rate 0 bps
Match: any
Traffic Shaping
Target/Average Byte Sustain Excess Interval Increment
Rate Limit bits/int bits/int (ms) (bytes)
512000/512000 3200 12800 12800 25 1600
Adapt Queue Packets Bytes Packets Bytes Shaping
Active Depth Delayed Delayed Active
- 0 1518 159496 0 0 no
Service-policy : child
Class-map: voice (match-all)
1486 packets, 154544 bytes <<<<<<<<<<<<<<<<<<<<<<<<<<< See there?
5 minute offered rate 4000 bps, drop rate 0 bps
Match: ip dscp ef
Queueing
Strict Priority
Output Queue: Conversation 72
Bandwidth 512 (kbps) Burst 12800 (Bytes)
(pkts matched/bytes matched) 0/0
(total drops/bytes drops) 0/0
Class-map: class-default (match-any)
32 packets, 4952 bytes
5 minute offered rate 0 bps, drop rate 0 bps
Match: any
R3(config-pmap-c)#
-----Mensaje original-----
De: nobody@groupstudy.com en nombre de Edison Ortiz
Enviado el: dom 28/01/2007 13:51
Para: Bit Gossip
CC: ccielab
Asunto: Re: policing and wfq with mqc
There are 2 ways:
1) show frame pvc 221
2) show policy-map interface
On 1/28/07, Bit Gossip <bit.gossip@chello.nl> wrote:
>
> My task requires to configure a certain service-policy to do policing
> and wfq between r2 and r1 which are connected via a fr pvc attached to a
> serial interface s4/0.221.
> I have found 2 approches; are they both correct?
> For the second one I dont know how to show and monitor the
> service-policy!
> BTW: it is not possible to attach the service-policy to the sub-if
> because wfq is not supported for sub-if
> Thanks,
> Luca.
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> - attach the policy to s4/0
>
> interface Serial4/0
> service-policy output S6
> ...
>
>
> in this case I can easily show the effect and monitor the counters:
>
>
> r2#show policy-map int s4/0
>
> Serial4/0
>
> Service-policy output: S6
>
> Class-map: S6-2 (match-all)
> 0 packets, 0 bytes
> 30 second offered rate 0 bps, drop rate 0 bps
> Match: access-group name S6-2
> police:
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> - attach the policy to dlci 221
>
> interface Serial4/0
> bandwidth 115200
> no ip address
> encapsulation frame-relay
> load-interval 30
> serial restart-delay 0
> no frame-relay inverse-arp
> !
> interface Serial4/0.221 point-to-point
> bandwidth 64
> ip address 10.1.122.2 255.255.255.0
> frame-relay interface-dlci 221
> class S6
>
> map-class frame-relay S6
> service-policy output S6
>
>
> But in this case I dont know how to monitor it?
> r2# show policy-map interface s4/0
>
> r2#
>
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html
This archive was generated by hypermail 2.1.4 : Thu Feb 08 2007 - 23:46:57 ART