[NW] 4th : Transport Layer

seunghyunΒ·2023λ…„ 3μ›” 1일
0

πŸ’»

λͺ©λ‘ 보기
10/15

Introduction

Transport Layer πŸ›œ

λͺ©μ μ§€ ν”„λ‘œμ„ΈμŠ€μ— μ•Œλ§žκ²Œ λ°°λ‹¬ν•΄μ£ΌλŠ” 일이 Transport Layer 의 기본적인 역할이닀.

Multiplexing/Demultiplexing

βœ”οΈ multiplexing as sender: λ‹€μˆ˜μ˜ μž…λ ₯을 ν•˜λ‚˜λ‘œ 좜λ ₯

  • handle data from multiple sockets, add transport header (later used for demultiplexing)

βœ”οΈ demultiplexing as receiver: λͺ©μ μ§€ ν”„λ‘œμ„ΈμŠ€μ— μ•Œλ§žκ²Œ λ³΄λ‚΄μ£ΌλŠ” 것

  • use header info to deliver received segments to correct socket

Connection-oriented demultiplexing: example

βœ”οΈ TCP socket identified by 4-tuple
TCP μ†ŒμΌ“μ€ 고유의 id λ₯Ό 가진닀. id 의 4가지 κ΅¬μ„±μš”μ†ŒλŠ” λ‹€μŒκ³Ό κ°™λ‹€.

  • source IP address
  • source port number
  • dest IP address
  • dest port number

βœ”οΈ demux: receiver uses all four values (4-tuple) to direct segment to appropriate socket

UDP segment header

  • checksum πŸ‘‰ error detection
  • μˆœμ„œ κ°œλ…μ€ μ—†κ³  error κ°€ μ—†μœΌλ©΄ μ „λ‹¬ν•œλ‹€. μœ μ‹€λ˜λ”λΌλ„ μ–΄μ©” 수 μ—†λ‹€.
  • μœ μ‹€ κ°€λŠ₯성은 μžˆμ„μ§€μ–Έμ • μ •ν™•νžˆ μ „λ‹¬ν•˜λ €λ˜ ν”„λ‘œμ„ΈμŠ€μ—κ²Œ 전달할 수 μžˆλ‹€.

TCP

Overview

βœ”οΈ point-to-point:

  • one sender, one receiver

βœ”οΈ reliable 🎯, in-order byte stream:

  • no "message boundaries"

βœ”οΈ pipelined:

  • TCP congestion and flow control set window size

βœ”οΈ a send & receive buffers

βœ”οΈ full duplex data:

  • bi-directional data flow in same connection
  • MSS: maximum segment size

βœ”οΈ connection-oriented:

  • handshaking (exchange of control msgs) init's sender, receiver state before data exchange

βœ”οΈ flow controlled: 🎯

  • sender will not overwhelm receiver

TCP segment structure

3 Way Hand Shaking

Closing TCP Connection

Congestion control 🎯

πŸ’‘ too many sources sending too much data too fast for network to handle.

  • lost packets (buffer overflow at routers)
  • long delays (queueing in router buffers)

λ„€νŠΈμ›Œν¬ 상황에 λ§žμΆ°μ„œ, 혼작 상황을 κ³ λ €ν•΄μ„œ λ³΄λ‚΄λŠ” 양을 μ‘°μ ˆν•΄μ£ΌλŠ” 것.
λ„€νŠΈμ›Œν¬ 혼작 상황을 μ–΄λ–»κ²Œ μ•Œ 수 μžˆμ„κΉŒ?

(μ°Έκ³ ! UDP λŠ” no congestion control)

λ„€νŠΈμ›Œν¬ 상황이 μ’‹μœΌλ©΄ MSSκ°€ μ¦κ°€ν•œλ‹€. μœ μ‹€ν•  κ°€λŠ₯성이 있으면 쀄인닀


πŸ”— Reference

  • OSI 7계측
  • OSI 7계측 κ·Έλ¦Ό
  • [KOCW] 이석볡 κ΅μˆ˜λ‹˜μ˜ μ»΄ν“¨ν„°λ„€νŠΈμ›Œν¬ κ°•μ˜λ₯Ό μˆ˜κ°•ν•˜κ³  μ •λ¦¬ν•œ λ‚΄μš©μž…λ‹ˆλ‹€.

잘λͺ»λœ λ‚΄μš©μ΄ μžˆλ‹€λ©΄ λŒ“κΈ€λ‘œ μ•Œλ €μ£Όμ‹œλ©΄ κ°μ‚¬ν•˜κ² μŠ΅λ‹ˆλ‹€ 😊

0개의 λŒ“κΈ€