Network Layer
Network Layer
Network Layer (Layer 3)
- Layer 3의 main mission: source host가 보내는 데이터를 destination host까지 전달하는 것 👉 host-to-host communication
- Most complex layers
- Network layer protocls in every host(only data plane) & router(data & control plane)
- data plane = forwarding / control plane = routing
- Delevering segment from sending to receiving host
- sending host: encapsulates segments(Layer 4) into datagrams
- intermediate routers: forwards datagram - router examines header fields in all IP datagrams
- receiving host: decapsulates datagram into segments
인터넷 라우터와 호스트에서 사용되는 Layer 2 프로토콜은 다양할 수 있으나 Layer 3은 모두 IP를 사용한다.
Virtual Circuit (Packet-swithed) Network (ATM)
V.C.P.S (Virtual Circuit Packet-Switched) Network
- Complexity inside network
- Fixed some path for pkts belongs to the same msg 👉 in-order delivery
- Resource (buffer, BW, CPU) 예약 가능
- Connection service
Datagram (Packet-switched) Network (Internet - IP 기반)
Datagram Network
- Simple inside network, complexity at "edge" -> "smart" end systems
- IP는 다양한 Layer 2 프로토콜 위에서도 성공적으로 동작 가능
- Connectionless service: pkt이 same msg에서 나온 것인지 알 수 없음, 독립적으로 처리
- 하나의 msg에 속한 여러 개의 pkt의 e2e path 모두 같다? (X)
- Best effort model: no guarantee delivery, in-order X
- No call setup at network layer
- Routers: no state about e2e connections
- Packet forward independently using destination host address(IP) in datagram header and forwarding table (FIB) at each router.
Router
- host에서는 routing protocol이 동작하지 않는다.
Data plane (forwarding)
- local, per-router function
- forwarding table (FIB) determine local forwarding:
- how datagram arriving on router input port is forwarded to router output port
- pkt's header 내의 destination IP address 이용
- HW 👉 fast
Control plane (routing)
- network-wide logic
- routing algorithm determine e2e path through NW
- from source host to destination host
- traditional routing algorithms (per-router) / software-defined networking (SDN)
- SW 👉 slow
Per-router vs Logically centralized
Per-router Control Plane
- traditional routing algorithms implemented in routers
- destination IP address basesd forwarding
- individual routing algorithm in each and every router interact in the control plane
- control plane and data plane are in the same device
Logically Centralized Control Plane
- software defined networking (SDN)
- distinct (typically remote) controller interacts with local control agents (CAs)
- generalized forwarding
- control plane and data plane are in different devices
Switching Fabrics
Switching Fabrics
- transfer pkt from input buffer to appropriate output buffer
- Switching rate: N * R (number of inputs N * link rate R) - measured as multiple of input/output link rate
- Interconnection network(= Crossbar network)
- forwarding(switching) multiple pkts in paralle, which have different input ports and different output ports
- if two pkts from different input ports are destined to the same output port, then one will have to wait at the input buffer (HOL blocking) since only one pkt can be send at a time.
라우터의 switching board의 처리 속도인 switching rate는 link rate (R)의 N 배로 구현되며 그 속도가 빨라 input buffer에서는 congestion이 거의 발생하지 않으나, output port 에서는 해당 포트로 포워딩되는 packet 수가 증가함에 따라 queueing delay & loss 발생할 수 있다.
Input port
- decentralized switching
- match plus action: using header field's dest. IP address -> lookup output port using FIB in input port memory
- Head-of-the-Line (HOL) blocking
- A queued pkt must wait for transfer at input buffer if the switch fabric is not fast enough
Output port
- when datagrams arrive from fabric faster than output line speed (transmission rate) -> queueing delay & loss due to output port buffer overflow
- Packet scheduler provides quality-of-service guarantees
- Internet: FCFS (first come first serve)
- priority scheduling -> violate network neutrality in the Internet -> 기술적으로 구현 가능하지만 사용 안함
Buffering(output buffer size) at router
- average buffering = RTT * link capacity R
- recent recommendation: with a large number of TCP flows N,
- $$ \frac{RTT * C}{\sqrt{N}} $$
인터넷 라우터의 평균 버퍼 크기는 RTT, link capacity R, TCP 연결 수에 영향을 받는다.
Internet Network Layer
- routing protocols only at router
- ICMP protocol: at router or host
- Data plane: at router & host
'CS > 컴퓨터네트워크' 카테고리의 다른 글
[Ch4] IPv6, SDN (0) | 2023.12.19 |
---|---|
[Ch4] IPv4, Network Address Translation(NAT) (1) | 2023.12.03 |
[Ch3] TCP congestion control (2) | 2023.11.27 |
[Ch3] UDP, TCP (1) | 2023.11.21 |
[Ch2 & Ch3] CDN, UDP & TCP, Mux & Demux (1) | 2023.11.14 |