Hi every body!
If a switch receives a frame with cos=7, it will place it in fastest queue at ingress port, given that cos=7 remained same, would switch put this frame in fastest queue at egress port as well? To put simply cos=7 means at ingress port, the frame be placed in fastest queue, does cos=7 mean, at egress port, that frame be placed in fastest queue at egress port?
thanks a lot!
All switches both L2 & L3 use an internal DSCP value to switch the packet internally.
You are correct in what you say about the native vlan. Because there is no 802.1q tag for the native vlan there will be be no place for a CoS value to be stored in the packet.
"4)I have hunch since DSCP is in ip header so layer 2 switches can not use it. Dscp should be used by routers or mulilayer switch to provide qos. Am i correct? "
As Edison says switches can also use the DSCP markings. It is important to note that DSCP markings "live" in the IP header of a packet and so they remain across different media. CoS markings on the other hand only make sense on ethernet and more specifically, as Edison notes, on L2 trunks. This is because the CoS markings are contained within the 802.1q tag/ISL encapsulation.
1) Do only layer- 3 switches use internal mapping of cos to DSCp to switch packets across switch fabric or layer 2 switches also use this kind of mapping?
Layer2 switches also use the same mapping. See the 2960 documentation:
I understand now cos values can not guarantee the faster processing of frame/packet. cos values are mapped to different queues which in turn determines if the packet will be serviced faster or not.
Am i correct?
3) In layer 2 network, cos is used to provide qos or DSCP can also be used to provide qos in layer 2 network.
CoS is used on trunk ports. DSCP can also be used on Layer2 switches. Please see the link above for more info.
As Jon indicated, the class-of-service value alone does not guaranteed the packet will be serviced faster than any other packet.
Additional configuration must be done at the switch for this to happen. By default, the switch will have DSCP-to-CoS mappings and the CoS will be automatically associated with ingress/egress queues.
However, the expedite queue must be enabled - else the switch will share the load among the available queues. In the case of the 3560, the queueing mechanism is SRR (Shared Round Robin) and if you don't type the priority-queue out command on the interface, the expedite queue will be disabled.
More information regarding QoS in the 3560, can be found at:
Cos 7 is not necessarily put in the "fastest" queue - it depends on many things ie. switch type, whether you have assigned a priority queue, whether you have remapped the Cos to queue maps.
For exmaple on a 3550 switch with 4 egress queues and assuming one of the queues has not been assigned as a priority queue
Cos 0 & 1 are mapped to queue 1
Cos 2 & 3 are mapped to q2
Cos 4 & 5 to q3
Cos 6 & 7 to q4
but it is up to you to decide what weighting and bandwidth is allocated to each queue.
A L3 switch uses an internal DSCP value to switch the packet across the switch fabric. When it receives a packet with a cos marking it looks up the Cos value in the Cos to DSCP map and then uses the DSCP value for QOS while the packet moves through the switch.
When the packet is about to be put in an egress queue the DSCP to QOS map is used to derive the Cos value and then it is placed in the queue that that Cos value has been mapped to.
So if the Cos 7 is mapped to the egress queue with the best service and the internal DSCP value is mapped to Cos 7 then yes a packet with Cos 7 would be placed into the queue with the best service.