Wednesday, 12 July 2023

Plumbing... QoS

Rule no 1. QoS does not help in situations where there is no enough bandwidth but helps optimize performance by prioritization of the traffic which helps to mitigate issues that occur periodically on the network.


Most common problems to solve:

1. Jitter: control the difference in delay between packets

2. Packet loss: Ensure that traffic capable of handling packet loss is dropped before traffic that cannot

3. TCP global synchronisation - refers to a network performance issue that can occur in congested or heavily loaded networks. It occurs when multiple TCP connections simultaneously reduce their sending rates due to congestion, resulting in periods of low network utilisation followed by sudden bursts of increased traffic


Main concepts:

1. Packet classification. Process of identifying different types of the network traffic based on its characteristic/flow (IP information, port, protocol, markings). 

  
2.  Traffic marking involves setting specific values (bits) in packet headers to indicate its priority following mechanisms can be used:

- at layer 3 by setting DSCP or IP precedence

- at layer 2 by setting CoS bits (Ethernet 802.1q defines three bits priority)

- when using MPLS by setting EXP bits

  
3.  Traffic classification can be also achieved with ACLs, NBAR (Network Based Application Recognition)

 
4. Congestion management/avoidance - RED and WRED two mechanisms to keep the traffic going by dropping randomly or per threshold traffic ahead of expected congestion. main difference between the two is that WRED provide more granular control over what is dropped. 

- marking is used to determine queue for each packet

- queues are used to make sure delay sensitive flows are not dropped i.e.: VoIP traffic is transmitted and not dropped.

- non-delay sensitive packets/lower priority queues may randomly drop traffic 

RED - Random Early Detection (treats all packets the equally)
       - avoids TCP global synchronisation streams, drops or marks packets randomly before queues are full
  
WRED - Weighted Random Early Detection (RED with more granular approach in terms of traffic classification, different queues and probability profiles)


5. Queuing or also called buffering uses two main mechanisms: LLQ and CBWFQ
    LLQ - Low Latency Queueing (extension of CBWFQ) adds strict-priority capability provides both bandwidth and latency guarantee. Recommended for real time traffic.
  both use to manage and schedule packets during congestion times.
    CBWFQ - Class-Based Weighted Fair Queuing - data traffic management only


6. Policing and shaping - both are traffic managment techniques used to enforce bandwidth limitation. Shaping rate/delay traffic to configured requirement. Policing monitors traffic and drops or remarks it if the configured limit is reached.


Traffic characteristics:


- Voice traffic:

  - smooth

  - benign

  - drop sensitive - less that 1%

  - delay sensitive - less 150ms one way delay / 30ms jitter

  - UDP


- voice/video conference traffic:

  - bursty and greedy:

    - dependent on codec and video quality

  - drop sensitive (less that 1%)

  - delay sensitive (150ms one way delay / 30ms jitter)

  - UDP


- Data traffic:

  - smooth or bursty

  - bening or greedy

  - drop insensitive

  - delay insensitive

  - TCP or UDP (TCP prevelent)

  

Traffic is often split into different traffic classes such us:

- premium (or platinium)

   - VoIP

   - Video conferencing

- gold

   - critical

- silver

  - Transactional

- Best Effort

   - Web traffic

   - email

   - etc...





Monday, 1 May 2023

OSPF area types and operations (JUNIPER - REVIEW)

OSPF area types allow networks to be segmented into smaller areas to reduce the amount of routing information that needs to be exchangedThe backbone area is the central area of the OSPF network and must exist in every OSPF network. Standard areas are connected to the backbone area and have their own LSDBs, while stub areas and NSSAs block external routing information to reduce the amount of routing information exchanged between areas. Totally stubby areas block both external and inter-area routes. Routers within the same area share the same LSDB and use it to calculate the shortest path to a destination network.


OSPF defines several types of areas, each with different functions and characteristics below are the OSPF area types and their operations:


Backbone Area (Area 0) - The backbone area (also called Area 0 - area id must be 0 / 0.0.0.0 in 32bit notation) is the central area of an OSPF network and it must exist in every OSPF multiarea network. All other areas must be connected to the backbone area directly, exeption her ei sthe use of Virtual-Link/tunnel. The backbone area is responsible for distributing routing information to other areas, and it forms the foundation of the entire OSPF network.


Standard Areas (Non-Backbone Areas) - Standard areas (also called non-backbone areas) are areas that are connected to the backbone area. Same as Backbone area Standard areas are identified by Area ID which must be different than 0 (or 0.0.0.0). Each standard area has its own link-state database (LSDB) that contains information about the network topology within that area. 


Stub Areas - Stub areas are standard areas that do not receive external routing information. External routing information is information about networks outside the OSPF domain. Stub areas are used to reduce the amount of routing information that needs to be exchanged between areas. Instead of receiving external routing information, stub areas use a default route to forward traffic to networks outside the OSPF domain. Stub areas can be configured as totally stubby areas, where no inter-area or external routes are allowed, or as not-so-stubby areas (NSSAs), which allow the injection of external routes but with some limitations.


Totally Stubby Areas - Totally stubby areas are a type of stub area that not only blocks external routes, but also inter-area routes. This means that routers within the totally stubby area only know about routes within their own area and the default route to reach networks outside the OSPF domain.


Not-So-Stubby Areas (NSSAs) - NSSAs are a type of stub area that allow the injection of external routes, but with some limitations. Unlike standard areas, NSSAs do not receive external routing information directly. Instead, an NSSA border router (ASBR) injects external routes into the NSSA as Type 7 LSAs, which are then translated into Type 5 LSAs by an NSSA Area Border Router (ABR) before being propagated into other areas.

Plumbing... QoS

Rule no 1. QoS does not help in situations where there is no enough bandwidth but helps optimize performance by prioritization of the traffi...