Notes on software, systems, and the science of making machines learn

Computer Networking

Himanish

Computer Networks and the Internet #

What is the Internet? #

‘Nuts and Bolts’ view #

  • Network of networks (interconnected ISPs)
  • Protocols everywhere e.g. HTTP, Skype

Services view #

  • Infrastructure that provides services to applications (email, social media, ecommerce)
  • Provides programming interface (hooks)

What’s a protocol #

  • Defines format, order of messages sent and received, actions taken on former

Four Layer Model #

Network Layer #

Application Layer #

  • Most common communication model of applications: a reliable, bidirectional byte stream, which allows two programs on diff computers to exchange data.
    • Abstracts away the entire network to a simple read/write relationship

Transport Layer #

TCP #

Transmission Control Protocol

  • Most applications want to communicate over a reliable, bi-directional byte-stream

Three Way Handshake #

  • Host A sends SYN (synchronise) message to Host B, indicating that A wants to establish a TCP connection with B
  • B responds with a SYN + ACK (acknowledge), ACK indicate correct delivery (reliable delivery)
  • A responds with an ACK
  • Stream of Bytes: Emulated using TCP segments

Connection Teardown #

  • A sends FIN to B, B responds with (Data +) Ack, and B stops receiving data from A
  • But B keeps sending data to A till B’s FIN message