Friday, January 28, 2011

Create a New Protocol in QoS


QoS, or Quality of Service, is a protocol used to provide a high level of audio or video reception. This service is meant to provide a near flawless delivery of signals so the person at the receiving end will not have delivery breakdowns, interference or dropped calls.

The traditional delivery method was "best-effort" such as email or data downloads. However, with new communication technologies offering new delivery features, "best effort" was not good enough. The predictability and guarantee delivery of a signal is important.
 
Instructions
 
1.  Connect the PC to the router with a console cable. One end of the cable attaches to the PC, and the  other end to the console port on the router. Start the router. Launch a HyperTerminal program on the PC by clicking "Start"

2.  Go to "All Programs" and locate the HyperTerminal program. Double-click the HyperTerminal program. When the router connection is complete, the router screen will appear. This will automatically launch the router editor. The next step is to define and configure the type of traffic to control.

3.  Type "enable" on the router to enter privileged mode. Now you can define the traffic that will be critical and not so critical. 

4.  Type "configure terminal" and type the following one line at a time the following: 

 "Access-list 140 Permit TCP any any eq !Critical QoS Ports"

 "Access-list 141 Permit TCP any any eq !Not Critical Qos Ports"

 These commands create two access lists, 140 and 141. They will permit any traffic, (note however, we still have to introduce the actual QoS features; that is in step 6.) The next step will create a class-map to define traffic groups 

5. Type the following commands, while still in configuration mode:

"Class-map match-all CRITICAL;" followed by

"Match access-group 140."

These commands define the critical traffic to an access-group.

6.  Type "Class-map match-all NOTCRITICAL" followed by

"Match access-group 141." This command defines the traffic that is not critical.

7. Type "Policy-map QoS Class CRITICAL Priority Percent 50."

"Class NOTCRITICAL Priority Percent 49."

"Class class-default."

8.  Type " set dscp default," to complete the configuration followed by"Fair-queue" and "random-detect." DSCP is Differentiated Services Code Point and this is used to define traffic based on types of services and priorities.

Fair-Queue is a scheduling algorithm to allow multiple packet flows to share the communications link capacity. Random detect avoids bandwidth congestion by randomly dropping packets before a threshold is met. This keeps the traffic flowing.


9.  Type "Interface FastEthernet 1/10." This command puts you into the router interface mode where you can configure the interface that will control the traffic.


10. Type "Service-policy output QoS." The policy map "QoS" comes from step 6. This command creates a new QoS protocol, and assigned it to the FastEthernet interface. You can now control the audio and video traffic.