Skip to content

Split View: [컴퓨터 네트워크] 18. 멀티미디어 네트워킹과 스트리밍

|

[컴퓨터 네트워크] 18. 멀티미디어 네트워킹과 스트리밍

멀티미디어 네트워킹과 스트리밍

멀티미디어 트래픽은 오늘날 인터넷 트래픽의 대부분을 차지합니다. 넷플릭스와 유튜브만으로도 북미 인터넷 다운스트림 트래픽의 50% 이상을 점유합니다.

이 글에서는 비디오와 오디오의 네트워크 특성, 스트리밍 기술의 발전, CDN(Content Delivery Network), VoIP(Voice over IP), 그리고 QoS(Quality of Service) 보장 메커니즘을 살펴봅니다.


1. 멀티미디어 애플리케이션의 분류

멀티미디어 애플리케이션 유형
===============================

1. 저장된 미디어 스트리밍 (Streaming Stored Media)
   - 넷플릭스, 유튜브, 웨이브
   - 사전 녹화된 콘텐츠를 재생
   - 약간의 지연 허용 (버퍼링)

2. 실시간 스트리밍 (Live Streaming)
   - 트위치, 아프리카TV, 스포츠 중계
   - 실시간 콘텐츠를 약간의 지연으로 전달
   - 10초 이내 지연 목표

3. 대화형 실시간 (Interactive Real-Time)
   - VoIP (Skype, Zoom, Discord)
   - 화상 회의, 온라인 게임
   - 150ms 이내 지연 필요 (엄격)

2. 비디오의 특성

2.1 비디오 압축

비디오 압축 원리
==================

비압축 비디오:
  - 해상도: 1920 x 1080 (Full HD)
  - 색상: 24비트/픽셀
  - 프레임: 30fps
  - 비트레이트: 1920 x 1080 x 24 x 30 = 약 1.5 Gbps

압축 후:
  - H.264/AVC: 1~10 Mbps (Full HD)
  - H.265/HEVC: 0.5~5 Mbps (Full HD)

압축 기법:
  1. 공간적 중복 (Spatial Redundancy)
     - 프레임 내 인접 픽셀의 유사성 활용
     - I-프레임: 독립 압축

  2. 시간적 중복 (Temporal Redundancy)
     - 연속 프레임 간 차이만 인코딩
     - P-프레임: 이전 프레임과의 차이
     - B-프레임: 전후 프레임과의 차이

2.2 CBR vs VBR

비트레이트 방식
=================

CBR (Constant Bit Rate):
  비트레이트 일정
  |_______________________________________
  |========================================
  |========================================
  +----------------------------------------> 시간

VBR (Variable Bit Rate):
  장면 복잡도에 따라 비트레이트 변동
  |         ___
  |   __   |   |  _    ___
  |__|  |__|   |_| |__|   |___
  +----------------------------------------> 시간
    정적  동적  정적 동적  정적

VBR이 일반적: 같은 평균 비트레이트에서 더 좋은 화질

3. HTTP 스트리밍과 DASH

3.1 단순 HTTP 스트리밍

HTTP 스트리밍 동작
====================

서버                              클라이언트
  |                                    |
  |<-- HTTP GET (비디오 파일 요청) ----|
  |                                    |
  |--- HTTP 응답 (비디오 데이터) ----->|
  |     TCP를 통해 순차적 전송         |
  |                                    | [수신 버퍼]
  |                                    |     |
  |                                    | [클라이언트 버퍼]
  |                                    |     |
  |                                    | [비디오 재생]

클라이언트 버퍼 동작:
  - 충분한 데이터가 쌓이면 재생 시작
  - TCP가 혼잡 제어로 전송률 조절
  - 버퍼가 비면 리버퍼링 (재생 중단)

3.2 DASH (Dynamic Adaptive Streaming over HTTP)

DASH는 네트워크 상태에 따라 비디오 품질을 동적으로 조절하는 적응형 스트리밍 방식입니다.

DASH 동작 원리
================

서버 측 준비:
  원본 비디오를 여러 비트레이트로 인코딩하고 청크로 분할

  비트레이트 1 (240p):  [C1][C2][C3][C4][C5]...  0.5 Mbps
  비트레이트 2 (480p):  [C1][C2][C3][C4][C5]...  1.5 Mbps
  비트레이트 3 (720p):  [C1][C2][C3][C4][C5]...  3.0 Mbps
  비트레이트 4 (1080p): [C1][C2][C3][C4][C5]...  6.0 Mbps
  비트레이트 5 (4K):    [C1][C2][C3][C4][C5]...  15.0 Mbps

  매니페스트 파일 (MPD): 각 청크의 URL과 비트레이트 정보

클라이언트 동작:
  1. 매니페스트 파일 다운로드
  2. 현재 가용 대역폭 측정
  3. 대역폭에 맞는 비트레이트의 다음 청크 요청
  4. 대역폭 변화에 따라 비트레이트 동적 조절

시간에 따른 비트레이트 변화:
  [720p][720p][1080p][1080p][480p][480p][720p][1080p]
                      ^대역폭 증가  ^대역폭 감소  ^복구

3.3 DASH의 장점

  • 적응형: 네트워크 상태에 자동 적응
  • 표준 HTTP: 방화벽/NAT 통과 용이, CDN 호환
  • 클라이언트 주도: 서버 부담 최소화
  • 끊김 최소화: 품질을 낮춰서라도 재생 유지

4. CDN (Content Delivery Network)

4.1 CDN의 필요성

전 세계 사용자에게 대용량 비디오를 동시에 전달하려면 단일 서버로는 불가능합니다.

CDN 없이 vs CDN 사용
======================

CDN 없이:
  미국 서버 <=============> 한국 사용자 (지연 200ms+)
  미국 서버 <=============> 브라질 사용자 (지연 300ms+)
  미국 서버 <=============> 호주 사용자 (지연 250ms+)
  --> 한 서버에 부하 집중, 긴 지연

CDN 사용:
  [원본 서버]
       |
  [CDN 서버: 서울] <--> 한국 사용자 (지연 10ms)
  [CDN 서버: 상파울루] <--> 브라질 사용자 (지연 15ms)
  [CDN 서버: 시드니] <--> 호주 사용자 (지연 12ms)
  --> 사용자 근처에서 콘텐츠 전달

4.2 CDN 배치 전략

CDN 배치 전략
===============

1. Enter Deep (진입 전략)
   - ISP의 접속 네트워크 내부에 서버 배치
   - 사용자에 매우 가까움
   - 관리 어려움 (서버 수가 매우 많음)
   - Akamai 방식: 전 세계 24만+ 서버

2. Bring Home (집결 전략)
   - IXP(Internet Exchange Point) 근처에 대규모 서버 클러스터 배치
   - 관리 용이
   - 사용자와 약간 더 먼 거리
   - Limelight, Google CDN 방식

4.3 CDN 동작 과정

CDN 콘텐츠 전달 과정
======================

사용자가 video.example.com/movie.mp4 요청:

1. 사용자 브라우저가 DNS 조회: video.example.com
2. 원본 DNS가 CDN의 DNS로 CNAME 리다이렉트
3. CDN DNS가 사용자에게 가장 가까운 CDN 서버 IP 반환
4. 사용자가 CDN 서버에 직접 HTTP 요청
5. CDN 서버가 콘텐츠 전달 (캐시 히트 시 즉시, 미스 시 원본에서 가져옴)

DNS 기반 CDN 서버 선택:
  사용자 위치 --> Local DNS IP --> CDN DNS
  CDN DNS가 지리적으로 가장 가까운 서버 IP 반환

4.4 넷플릭스 아키텍처

넷플릭스 스트리밍 아키텍처
============================

[넷플릭스 클라이언트 앱]
        |
        | 1. 로그인, 검색, 추천
        v
[AWS 클라우드] (넷플릭스 백엔드)
  - 사용자 인증
  - 콘텐츠 추천
  - DRM 라이선스
  - 매니페스트 파일 생성
        |
        | 2. 스트리밍 URL (CDN 서버 주소)
        v
[넷플릭스 클라이언트 앱]
        |
        | 3. DASH 기반 비디오 스트리밍
        v
[넷플릭스 Open Connect CDN]
  - 자체 CDN 인프라
  - ISP 내부에 OCA(Open Connect Appliance) 설치
  - 인기 콘텐츠 사전 배포 (off-peak 시간)

5. VoIP (Voice over IP)

5.1 VoIP의 특성

VoIP 요구사항
===============

- 허용 가능한 지연: 150ms 이하 (양호), 400ms 이하 (허용)
- 패킷 손실: 1~5% 손실은 FEC로 복구 가능
- 지터: 패킷 도착 간격의 변동 --> 플레이아웃 지연으로 보상

음성 인코딩:
  PCM: 8000 samples/sec x 8 bits = 64 Kbps
  패킷화: 20ms마다 160바이트 + 헤더 = 약 200바이트 패킷

5.2 지터와 플레이아웃 지연

지터 (Jitter) 문제
====================

송신 측: 패킷을 일정 간격(20ms)으로 전송
  |P1|  |P2|  |P3|  |P4|  |P5|  (20ms 간격)

네트워크를 거치면 도착 간격이 불규칙:
  |P1|    |P2||P3|      |P4|  |P5|  (가변 간격)

해결: 플레이아웃 버퍼 (Playout Buffer)
  - 수신된 패킷을 버퍼에 저장
  - 일정 지연 후 버퍼에서 균등 간격으로 재생

플레이아웃 지연 설정:
  고정 플레이아웃 지연:
    모든 패킷에 동일한 지연 적용
    지연이 크면: 패킷 손실 적지만 대화 지연 증가
    지연이 작으면: 대화 자연스럽지만 늦은 패킷 폐기

  적응형 플레이아웃 지연:
    말하는 구간(talkspurt) 사이에 지연을 조절
    네트워크 지연의 평균과 분산을 추정하여 동적 조절

5.3 패킷 손실 복구

VoIP 손실 복구 기법
======================

1. FEC (Forward Error Correction)
   방법 A: 중복 패킷 전송
     원본:  [P1][P2][P3][P4]
     XOR:   [P1^P2][P2^P3][P3^P4]
     P2 손실 시: P1^P2 XOR P1 = P2 복구

   방법 B: 저품질 복사본 끼워넣기
     [P1 고품질][P1 저품질 복사 | P2 고품질][P2 저품질 복사 | P3]
     P2 손실 시 P2 저품질 복사본으로 대체

2. 인터리빙 (Interleaving)
   원본:   [1,5,9,13] [2,6,10,14] [3,7,11,15] [4,8,12,16]
   인터리빙: [1,2,3,4] [5,6,7,8] [9,10,11,12] [13,14,15,16]

   한 패킷 손실 시 연속된 손실이 아닌 분산된 손실
   --> 보간(interpolation)으로 복구 가능

6. QoS (Quality of Service)

6.1 QoS의 필요성

멀티미디어 트래픽은 대역폭, 지연, 지터, 손실에 대한 요구사항이 다릅니다.

트래픽별 QoS 요구사항
========================

트래픽 유형  | 대역폭  | 지연    | 지터   | 손실
------------+---------+---------+--------+--------
이메일       | 낮음    | 무관    | 무관   | 0% 필요
웹 브라우징  | 중간    | 낮음    | 무관   | 0% 필요
파일 전송    | 높음    | 무관    | 무관   | 0% 필요
VoIP         | 낮음    | 매우 낮음| 낮음  | 일부 허용
비디오 스트리밍| 높음   | 낮음    | 낮음  | 일부 허용
온라인 게임  | 낮음    | 매우 낮음| 매우 낮음| 일부 허용

6.2 QoS 보장 메커니즘

QoS 메커니즘
==============

1. 마킹 (Marking)
   - 패킷에 우선순위 표시
   - IP 헤더의 ToS/DSCP 필드 사용
   - 높은 우선순위: VoIP, 화상 회의
   - 낮은 우선순위: 파일 다운로드, 이메일

2. 폴리싱 (Policing)
   - 트래픽이 합의된 속도를 초과하지 않도록 제한
   - 토큰 버킷: 토큰이 일정 속도로 생성, 패킷 전송 시 소모

3. 스케줄링 (Scheduling)
   - 우선순위 큐잉, WFQ 등
   - 높은 우선순위 트래픽을 먼저 처리

4. 승인 제어 (Admission Control)
   - 네트워크가 새 플로우를 수용할 수 있는지 판단
   - 수용 불가 시 거부

6.3 토큰 버킷

토큰 버킷 알고리즘
====================

파라미터:
  r = 토큰 생성 속도 (tokens/sec)
  b = 버킷 크기 (최대 토큰 수)

동작:
  - 토큰이 r의 속도로 버킷에 축적
  - 패킷 전송 시 토큰 소모
  - 토큰이 없으면 패킷 대기 또는 폐기
  - 버킷이 가득 차면 새 토큰 폐기

효과:
  - 평균 전송률: r로 제한
  - 순간 버스트: b만큼 허용

  토큰 수
  b |____
    |    \___
    |        \___
    |    버스트   \___평균 r
    +-------------------> 시간

7. Diffserv (Differentiated Services)

Diffserv 아키텍처
===================

인터넷에서 QoS를 제공하기 위한 확장 가능한 프레임워크

동작:
  1. 에지 라우터: 패킷 분류 및 마킹 (DSCP 설정)
  2. 코어 라우터: DSCP 값에 따른 차별화된 처리

DSCP (Differentiated Services Code Point):
  IP 헤더의 ToS 필드 6비트 사용

PHB (Per-Hop Behavior):
  - EF (Expedited Forwarding): 최우선 처리 (VoIP 등)
  - AF (Assured Forwarding): 보장된 전달 (4개 클래스)
  - BE (Best Effort): 기본 처리 (일반 트래픽)

장점: 확장 가능, 플로우별 상태 불필요
단점: 엄격한 QoS 보장 어려움

8. 정리

개념핵심 내용
DASH대역폭에 따라 비디오 품질 동적 조절
CDN사용자 근처 서버에서 콘텐츠 전달
Enter DeepISP 내부에 CDN 서버 배치 (Akamai)
지터패킷 도착 간격의 변동, 플레이아웃 버퍼로 보상
FEC사전에 복구 정보 전송하여 손실 복구
토큰 버킷평균 속도 r 제한, 순간 버스트 b 허용
DiffservDSCP 기반 차별화된 QoS 처리

다음 글에서는 네트워크 보안의 핵심인 암호학, 인증, SSL/TLS, 방화벽을 살펴보겠습니다.


참고 자료

  • James F. Kurose, Keith W. Ross, "Computer Networking: A Top-Down Approach", 6th Edition, Chapter 7
  • RFC 6209 - DASH (Dynamic Adaptive Streaming over HTTP)
  • RFC 2474 - Definition of the Differentiated Services Field

[Computer Networking] 18. Multimedia Networking and Streaming

Multimedia Networking and Streaming

Multimedia traffic accounts for the majority of today's Internet traffic. Netflix and YouTube alone account for over 50% of North American downstream Internet traffic.

In this post, we examine the network characteristics of video and audio, the evolution of streaming technologies, CDN (Content Delivery Network), VoIP (Voice over IP), and QoS (Quality of Service) guarantee mechanisms.


1. Classification of Multimedia Applications

Types of Multimedia Applications
===================================

1. Streaming Stored Media
   - Netflix, YouTube, Hulu
   - Pre-recorded content playback
   - Some delay acceptable (buffering)

2. Live Streaming
   - Twitch, live sports broadcasts
   - Real-time content with slight delay
   - Target: under 10 seconds delay

3. Interactive Real-Time
   - VoIP (Skype, Zoom, Discord)
   - Video conferencing, online gaming
   - Requires under 150ms delay (strict)

2. Video Characteristics

2.1 Video Compression

Video Compression Principles
==============================

Uncompressed Video:
  - Resolution: 1920 x 1080 (Full HD)
  - Color: 24 bits/pixel
  - Frame rate: 30fps
  - Bit rate: 1920 x 1080 x 24 x 30 = ~1.5 Gbps

After Compression:
  - H.264/AVC: 1~10 Mbps (Full HD)
  - H.265/HEVC: 0.5~5 Mbps (Full HD)

Compression Techniques:
  1. Spatial Redundancy
     - Exploits similarity of adjacent pixels within a frame
     - I-frame: Independently compressed

  2. Temporal Redundancy
     - Encodes only differences between consecutive frames
     - P-frame: Difference from previous frame
     - B-frame: Difference from adjacent frames

2.2 CBR vs VBR

Bit Rate Modes
=================

CBR (Constant Bit Rate):
  Constant bit rate
  |_______________________________________
  |========================================
  |========================================
  +----------------------------------------> Time

VBR (Variable Bit Rate):
  Bit rate varies with scene complexity
  |         ___
  |   __   |   |  _    ___
  |__|  |__|   |_| |__|   |___
  +----------------------------------------> Time
    Static Dynamic Static Dynamic Static

VBR is typical: Better quality at the same average bit rate

3. HTTP Streaming and DASH

3.1 Simple HTTP Streaming

HTTP Streaming Operation
==========================

Server                              Client
  |                                    |
  |<-- HTTP GET (video file request) --|
  |                                    |
  |--- HTTP Response (video data) ---->|
  |     Sequential delivery via TCP    |
  |                                    | [Receive Buffer]
  |                                    |     |
  |                                    | [Client Buffer]
  |                                    |     |
  |                                    | [Video Playback]

Client Buffer Behavior:
  - Playback starts when sufficient data accumulates
  - TCP adjusts send rate via congestion control
  - Rebuffering (playback pause) if buffer empties

3.2 DASH (Dynamic Adaptive Streaming over HTTP)

DASH is an adaptive streaming method that dynamically adjusts video quality based on network conditions.

DASH Operating Principle
==========================

Server-Side Preparation:
  Encode original video at multiple bit rates and split into chunks

  Bit rate 1 (240p):  [C1][C2][C3][C4][C5]...  0.5 Mbps
  Bit rate 2 (480p):  [C1][C2][C3][C4][C5]...  1.5 Mbps
  Bit rate 3 (720p):  [C1][C2][C3][C4][C5]...  3.0 Mbps
  Bit rate 4 (1080p): [C1][C2][C3][C4][C5]...  6.0 Mbps
  Bit rate 5 (4K):    [C1][C2][C3][C4][C5]...  15.0 Mbps

  Manifest file (MPD): URL and bit rate info for each chunk

Client Operation:
  1. Download manifest file
  2. Measure current available bandwidth
  3. Request next chunk at bit rate matching bandwidth
  4. Dynamically adjust bit rate as bandwidth changes

Bit rate changes over time:
  [720p][720p][1080p][1080p][480p][480p][720p][1080p]
                      ^BW increase  ^BW decrease  ^Recovery

3.3 Advantages of DASH

  • Adaptive: Automatically adapts to network conditions
  • Standard HTTP: Easy firewall/NAT traversal, CDN compatible
  • Client-driven: Minimizes server burden
  • Minimizes interruption: Maintains playback even at lower quality

4. CDN (Content Delivery Network)

4.1 Need for CDN

A single server cannot simultaneously deliver large video to users worldwide.

Without CDN vs With CDN
=========================

Without CDN:
  US Server <=============> Korean user (200ms+ latency)
  US Server <=============> Brazilian user (300ms+ latency)
  US Server <=============> Australian user (250ms+ latency)
  --> Load concentrated on one server, high latency

With CDN:
  [Origin Server]
       |
  [CDN Server: Seoul] <--> Korean user (10ms latency)
  [CDN Server: Sao Paulo] <--> Brazilian user (15ms latency)
  [CDN Server: Sydney] <--> Australian user (12ms latency)
  --> Content delivered from near the user

4.2 CDN Deployment Strategies

CDN Deployment Strategies
===========================

1. Enter Deep
   - Place servers inside ISP access networks
   - Very close to users
   - Difficult to manage (very many servers)
   - Akamai approach: 240,000+ servers worldwide

2. Bring Home
   - Place large server clusters near IXPs (Internet Exchange Points)
   - Easier to manage
   - Slightly more distant from users
   - Limelight, Google CDN approach

4.3 CDN Operation Process

CDN Content Delivery Process
===============================

User requests video.example.com/movie.mp4:

1. User browser performs DNS lookup: video.example.com
2. Origin DNS redirects to CDN DNS via CNAME
3. CDN DNS returns IP of CDN server closest to user
4. User sends HTTP request directly to CDN server
5. CDN server delivers content (immediately on cache hit, fetches from origin on miss)

DNS-based CDN Server Selection:
  User location --> Local DNS IP --> CDN DNS
  CDN DNS returns IP of geographically closest server

4.4 Netflix Architecture

Netflix Streaming Architecture
=================================

[Netflix Client App]
        |
        | 1. Login, search, recommendations
        v
[AWS Cloud] (Netflix Backend)
  - User authentication
  - Content recommendations
  - DRM licensing
  - Manifest file generation
        |
        | 2. Streaming URL (CDN server address)
        v
[Netflix Client App]
        |
        | 3. DASH-based video streaming
        v
[Netflix Open Connect CDN]
  - Proprietary CDN infrastructure
  - OCA (Open Connect Appliance) installed inside ISPs
  - Popular content pre-distributed (during off-peak hours)

5. VoIP (Voice over IP)

5.1 VoIP Characteristics

VoIP Requirements
===================

- Acceptable delay: Under 150ms (good), under 400ms (tolerable)
- Packet loss: 1~5% loss recoverable with FEC
- Jitter: Variation in packet arrival intervals --> compensated with playout delay

Voice Encoding:
  PCM: 8000 samples/sec x 8 bits = 64 Kbps
  Packetization: 160 bytes every 20ms + header = ~200 byte packets

5.2 Jitter and Playout Delay

Jitter Problem
================

Sender: Sends packets at regular intervals (20ms)
  |P1|  |P2|  |P3|  |P4|  |P5|  (20ms intervals)

After traversing network, arrival intervals become irregular:
  |P1|    |P2||P3|      |P4|  |P5|  (variable intervals)

Solution: Playout Buffer
  - Store received packets in buffer
  - Play back from buffer at regular intervals after fixed delay

Playout Delay Setting:
  Fixed playout delay:
    Same delay applied to all packets
    Large delay: fewer packet losses but increased conversation delay
    Small delay: natural conversation but late packets discarded

  Adaptive playout delay:
    Adjust delay between talkspurts
    Dynamically adjust based on estimated mean and variance of network delay

5.3 Packet Loss Recovery

VoIP Loss Recovery Techniques
================================

1. FEC (Forward Error Correction)
   Method A: Redundant packet transmission
     Original:  [P1][P2][P3][P4]
     XOR:       [P1^P2][P2^P3][P3^P4]
     If P2 lost: P1^P2 XOR P1 = P2 recovered

   Method B: Insert low-quality copy
     [P1 high quality][P1 low copy | P2 high quality][P2 low copy | P3]
     If P2 lost, substitute with P2 low-quality copy

2. Interleaving
   Original:     [1,5,9,13] [2,6,10,14] [3,7,11,15] [4,8,12,16]
   Interleaved:  [1,2,3,4] [5,6,7,8] [9,10,11,12] [13,14,15,16]

   Single packet loss results in distributed rather than consecutive loss
   --> Recoverable via interpolation

6. QoS (Quality of Service)

6.1 Need for QoS

Multimedia traffic has different requirements for bandwidth, delay, jitter, and loss.

QoS Requirements by Traffic Type
===================================

Traffic Type    | Bandwidth | Delay    | Jitter  | Loss
----------------+-----------+----------+---------+--------
Email           | Low       | N/A      | N/A     | 0% needed
Web Browsing    | Medium    | Low      | N/A     | 0% needed
File Transfer   | High      | N/A      | N/A     | 0% needed
VoIP            | Low       | Very Low | Low     | Some OK
Video Streaming | High      | Low      | Low     | Some OK
Online Gaming   | Low       | Very Low | Very Low| Some OK

6.2 QoS Guarantee Mechanisms

QoS Mechanisms
================

1. Marking
   - Mark priority on packets
   - Use ToS/DSCP field in IP header
   - High priority: VoIP, video conferencing
   - Low priority: File downloads, email

2. Policing
   - Limit traffic to not exceed agreed rate
   - Token Bucket: Tokens generated at constant rate, consumed when sending packets

3. Scheduling
   - Priority queuing, WFQ, etc.
   - Process higher priority traffic first

4. Admission Control
   - Determine if network can accommodate new flow
   - Reject if not possible

6.3 Token Bucket

Token Bucket Algorithm
========================

Parameters:
  r = token generation rate (tokens/sec)
  b = bucket size (maximum tokens)

Operation:
  - Tokens accumulate in bucket at rate r
  - Tokens consumed when sending packets
  - If no tokens, packets wait or are discarded
  - New tokens discarded if bucket is full

Effect:
  - Average send rate: limited to r
  - Instantaneous burst: up to b allowed

  Token count
  b |____
    |    \___
    |        \___
    |    Burst    \___Average r
    +-------------------> Time

7. Diffserv (Differentiated Services)

Diffserv Architecture
========================

Scalable framework for providing QoS on the Internet

Operation:
  1. Edge routers: Classify and mark packets (set DSCP)
  2. Core routers: Differentiated treatment based on DSCP value

DSCP (Differentiated Services Code Point):
  Uses 6 bits of the ToS field in IP header

PHB (Per-Hop Behavior):
  - EF (Expedited Forwarding): Highest priority (VoIP, etc.)
  - AF (Assured Forwarding): Guaranteed delivery (4 classes)
  - BE (Best Effort): Default treatment (general traffic)

Advantages: Scalable, no per-flow state needed
Disadvantages: Strict QoS guarantees are difficult

8. Summary

ConceptKey Points
DASHDynamically adjusts video quality based on bandwidth
CDNDelivers content from servers near the user
Enter DeepCDN servers placed inside ISPs (Akamai)
JitterVariation in packet arrival intervals, compensated with playout buffer
FECSends recovery information in advance for loss recovery
Token BucketLimits average rate to r, allows instantaneous burst of b
DiffservDifferentiated QoS treatment based on DSCP

In the next post, we will examine the core of network security: cryptography, authentication, SSL/TLS, and firewalls.


References

  • James F. Kurose, Keith W. Ross, "Computer Networking: A Top-Down Approach", 6th Edition, Chapter 7
  • RFC 6209 - DASH (Dynamic Adaptive Streaming over HTTP)
  • RFC 2474 - Definition of the Differentiated Services Field