Linux Based DiffServ. Router


Published on

My graduation project in BSc. Electronics & Communications in 2002. Linux Based DiffServ. Router, a software to classify the network traffic, DSCP Mark, Shape and Prioritize it according to those classes.

Published in: Technology
  • Be the first to comment

  • Be the first to like this

Linux Based DiffServ. Router

  1. 1. 12/26/11 Cairo University Faculty of Engineering Electronics &Communication dpt. 4th year <ul><ul><ul><li>Supervisor: </li></ul></ul></ul><ul><ul><ul><li>Prof. Dr. Khaled Foad El-Sayed. </li></ul></ul></ul><ul><ul><ul><li>Submitted by: Ashraf Kamal Rahoma </li></ul></ul></ul><ul><ul><ul><li>Hazem Mohamed Sobhi Hassanein </li></ul></ul></ul><ul><ul><ul><li>Hossam El-Sayed Abd Allah </li></ul></ul></ul><ul><ul><ul><li>Tarek Amr Abdallah </li></ul></ul></ul><ul><ul><ul><li>Zein El-Abidin Mohamed WALI </li></ul></ul></ul>Linux-based Implementation Of a Router (B.Sc Graduation project) 2002 DiffServ
  2. 2. 12/26/11 Internet Protocol (IP).was designed to provide best-effort service. • VoIP • FTP QOS: Quality of Service (QoS) implies the ability to differentiate traffic streams and to define a level of performance for those traffic streams across a network. When heavily utilized networks are carrying various types of traffic for different users, QoS is a mean of offering better service Introduction to QoS: <ul><ul><li>Motivation: </li></ul></ul><ul><ul><li>QoS Terminology and Parameters: </li></ul></ul>
  3. 3. 12/26/11 <ul><li>Latency the delay a flow experiences when passing through a device </li></ul><ul><li>Jitter the latency variations </li></ul><ul><li>loss probability bandwidth distribution and availability (throughput or goodput) </li></ul>Parameters
  4. 4. 12/26/11 IntServ vs. DiffServ <ul><ul><li>IntServ overview </li></ul></ul>
  5. 5. 12/26/11 RSVP Protocol
  6. 6. 12/26/11 RSVP Protocol
  7. 7. 12/26/11 RSVP Protocol
  8. 8. 12/26/11 RSVP Protocol
  9. 9. 12/26/11 <ul><ul><li>IntServ vs. DiffServ </li></ul></ul>Each has its won points of strength And weakness
  10. 10. 12/26/11 <ul><ul><li>DiffServ Architecture </li></ul></ul><ul><ul><li>DiffServ Architectural Model </li></ul></ul><ul><ul><li>Differentiated Services Domain </li></ul></ul>DS Boundary Nodes and Interior Nodes: DS Ingress Node and Egress Node: Differentiated Services Region: Traffic Classification and Conditioning: Classifiers: Traffic Profiles: Traffic Conditioners:
  11. 11. 12/26/11 Meters: Markers: Shapers: Droppers: Location of Traffic Conditioners and MF Classifiers: Within the Source Domain: At the Boundary of a DS Domain: In non-DS-Capable Domains: In Interior DS Nodes:
  12. 12. 12/26/11 <ul><ul><li>ToS VS DSCP </li></ul></ul><ul><ul><li>Introduction </li></ul></ul><ul><ul><li>Type of service byte definition </li></ul></ul>
  13. 13. 12/26/11 <ul><ul><li>Type of service byte definition </li></ul></ul>
  14. 14. 12/26/11
  15. 15. 12/26/11 <ul><ul><li>Disadvantages of ToS </li></ul></ul><ul><li>The IP-precedence scheme allows only specification of relative priority of a packet. it has no provisions to specify different drop precedence for packets of a certain priority. </li></ul><ul><li>The 3 bits restrict the number of possible priority classes to 8 </li></ul><ul><li>The ToS mechanism is not powerful enough to allow an application to quantify the level of service it desires. </li></ul>
  16. 16. 12/26/11 <ul><ul><li>Differentiated services field definition </li></ul></ul>
  17. 17. 12/26/11 <ul><ul><li>Per Hop Behavior PHB </li></ul></ul>A per-hop behavior (PHB) is a description of the externally observable forwarding behavior of a DS node applied to a particular DS behavior aggregate (BA). <ul><ul><li>Different PHB’s </li></ul></ul>Currently there are 4 standard different per hop behaviors PHB’s: Default PHB Class-Selector PHB. Assured Forwarding (AFny) PHB. Expedited Forwarding (EF) PHB.
  18. 18. 12/26/11
  19. 19. 12/26/11 <ul><ul><li>DiffServ Support under Linux </li></ul></ul><ul><ul><li>Linux Traffic Control Overview </li></ul></ul>
  20. 20. 12/26/11 <ul><ul><li>Linux Traffic Controller </li></ul></ul>
  21. 21. 12/26/11 <ul><ul><li>Implementation and Code </li></ul></ul><ul><ul><li>TC Implementation </li></ul></ul>
  22. 22. 12/26/11 <ul><li>Note: In this drawing only one AF class is shown for the simplicity of the drawing, the other ones are just the same . </li></ul><ul><li>DSMARK </li></ul><ul><li>CBQ </li></ul><ul><li>pFIFO : </li></ul><ul><ul><ul><li>Low queuing delay (latency). </li></ul></ul></ul><ul><ul><ul><li>Well defined minimum departure rate, i.e. independent of the other traffic at the node. </li></ul></ul></ul><ul><ul><ul><li>No burst. (policing). </li></ul></ul></ul><ul><li>4 CBQ : </li></ul><ul><ul><ul><li>Four AF classes with different fractions of the bandwidth allocated for each. </li></ul></ul></ul><ul><ul><ul><li>In each one we have three dropping precedence’s (RED) </li></ul></ul></ul><ul><ul><ul><li>Bandwidth assurance, </li></ul></ul></ul><ul><ul><ul><li>RED: </li></ul></ul></ul><ul><ul><ul><ul><ul><li>No bandwidth guarantee. </li></ul></ul></ul></ul></ul><ul><ul><ul><ul><ul><li>No quality of service: No policing filters, no shaping. </li></ul></ul></ul></ul></ul>
  23. 23. 12/26/11 <ul><ul><li>Traffic Classes </li></ul></ul><ul><li>Variables: </li></ul><ul><li>Setting Functions: </li></ul><ul><ul><li>Constructor. </li></ul></ul><ul><ul><li>Destructor </li></ul></ul><ul><ul><li>Set Device </li></ul></ul><ul><ul><li>Set Network </li></ul></ul><ul><ul><li>Set Rates </li></ul></ul><ul><ul><li>Set PHB’s </li></ul></ul><ul><ul><li>Set Police </li></ul></ul><ul><ul><li>Set ToS </li></ul></ul>
  24. 24. 12/26/11 Infra-structure Functions: <ul><li>Filtering Functions: </li></ul><ul><ul><li>Make Filter </li></ul></ul><ul><li>Get Command </li></ul>t_start( ) t_reset( ) Make_phb( ) make_EF( ) make_AF( ) make_BE( ) make_Subfilter( ) make_marker( )
  25. 25. 12/26/11 Software implementation <ul><li>Architecture Overview. </li></ul><ul><li>Graphical User Interface (GUI). </li></ul><ul><li>System programming. </li></ul>
  26. 26. 12/26/11 using C++ Classes <ul><li>To ensure encapsulation & independence </li></ul><ul><li>To control the communication & error tracing </li></ul><ul><li>To give the ability to change or update any specific parts. </li></ul>Architecture Overview
  27. 27. 12/26/11 using C++ Classes Architecture Overview
  28. 28. 12/26/11 Detailed view
  29. 29. 12/26/11 Communication between Classes
  30. 30. 12/26/11 GUI tabs PHB configuration tab
  31. 31. 12/26/11 Advanced PHB
  32. 32. 12/26/11 Filter Setup Tab
  33. 33. 12/26/11 Summary view Tab
  34. 34. 12/26/11 TC Experts Tab
  35. 35. 12/26/11 4.4 Testing:
  36. 36. 12/26/11 We have performed testing on 3 basic levels: 1. Marking: Testing if packets were marked according to specified classification. 2. ToS: Testing if the classification according to ToS and monitoring packets flow were mapped to the required PHB 3. PHB’s Implementation: Monitoring different rates assigned to each class 4.5 Testing procedure
  37. 37. 12/26/11 Than You !