Week 2: Fundamental networking concepts - IDATA2304, IELEA2001 Computer communication and network programming - Computer networks course
←
→
Page content transcription
If your browser does not render page correctly, please read the page content below
Week 2: Fundamental Check-In: Brosundet networking concepts IDATA2304, IELEA2001 Computer communication and network programming Girts Strazdins, gist@ntnu.no, NTNU i Ålesund, 2021
Topics for week 2 1. Nuts and bolts description (devices) 2. Service description 3. Protocols 4. Encoding data as packets for transmission 5. Queues, delays and packet loss 6. Internet service providers 7. Core network and access networks
How do we connect the end- devices? If we have n end-devices. How many links to connect any to any? n * (n-1) / 2
Postal service hierarchy Universal Postal Union Norwegian Swedish authorities authorities Nasjonal Posten kommunikasjons- … myndighet Posten Oslo Posten Ålesund Rema 1000 Amfi Spar Larsgården Moa … …
Computer communication hierarchy (imaginary, but realistic) Scandinavia Norway Sweden University NTNU … of Oslo NTNU NTNU Trondheim Gjøvik NTNU Ålesund Brosundet Fytrårnet
Three building blocks of computer networks 1. End devices 2. Wired and wireless links 3. Routers Users of the network Infrastructure for end devices
What are routers?
Home router != router
Routers = routing + forwarding
What router manufacturers do you know?
Manufacturers are not important All routers are alike. Why?
Router interface implements Cisco router Mikrotik router … Noname router
How do we describe Router interface? What is a router? How do we describe tasks for a router?
Protocols For Any device on the network: "device A has a role X in the network" == "device A provides a set of services S(X), implemented according to protocols P(X)"
What is a protocol?
Communication protocols A protocol is an agreement on actions and reactions for a service. A protocol is a common language. Two objects* can communicate if and only if they share a common protocol. * Objects can be anything: humans, animals, computer software, computer hardware, quantum entangled particles, aliens, …. In the context of computer networks, the objects are computer software.
Example human protocols • Buying lunch at the canteen • Sending a mail message to a friend • Sorting and forwarding mail at a post office • Oral exam at a university
Exercise: example protocol Describe a protocol for distribution of information sheets to all students in a class. All students and all sheets are equal (i.e, doesn’t matter which students gets which sheet as long as everyone gets one).
Exercise: Example protocol Describe a protocol for distribution of information flyers to all students in a class. All students and all flyers are equal (it doesn’t matter which students gets which flyer as long as everyone gets one). The remaining flyers should be returned to the teacher. Students are organized (sitting) in rows.
A possible solution Protocol for the teacher: Protocol for students: 1. Show the flyers to 1. Wait for a pile of students flyers to arrive 2. Explain that they 2. Take a flyer from the should take one and pile pass along 3. If I’m not the last 3. Give a bunch of flyers (rightmost) student in to the leftmost the row, pass it to the student in each row right 4. Wait for remaining 4. If I’m the last flyers, collect them student, return the when students return remaining flyers to them the teacher
Network protocol A network protocol is an agreement on: 1. What and when to send 2. How to react on received data
Computer network protocols at different levels • WhatsApp – how to send messages to and from Facebook servers • SSL – data encryption • TCP protocol – chunking a stream of data into packets, retransmission in case of a lost packet • IP protocol – addressing of devices, packet format, network hierarchy • WiFi – connection to wireless access points, transmitting data to/from the access points
End-users Delivery network infrastructure (routers) Custom protocols at each level You don’t care about the protocols They don’t read your books
Apps and services communicating Magic
Connecting the end devices We have end devices. We can get routers. How to connect each end-device to any other? If two students want to communicate – do they buy routers?
Internet Service Providers (ISPs)
ISPs in Ålesund …
How to connect ISPs? access access net net access net access access net net access access net net connecting each ISP to each access other directly doesn’t scale: access net O(N2) connections. net access net access net access net access net access access net access net net
Multiple tiers
Can Google be fast in Russia?
Google’s data centers https://www.google.com/about/datacenters/locations/
Core network and access networks
Core network = routers AKA network backbone
Access networks Access network is a network connecting end-users to the first ISP router
Some popular access network types
DSL: reusing phone lines
Fiber optics cables
Home network DSL or Fiber optics
Enterprise network
Wireless LAN and cellular nets For example, ISP network in hotels
Let's talk about routers…
Store-and-forward devices C A D B E
What if the outgoing link is slow? 100Mbps C A 1Mbps D B queue of packets E waiting for output link
Four sources of packet delays transmission A propagation B nodal processing queueing drouter = dproc + dqueue + dtrans + dprop
Which delays depend on the amount of traffic? transmission A propagation B nodal processing queueing drouter = dproc + dqueue + dtrans + dprop
Which delays depend on the amount of traffic? transmission A propagation B nodal processing queueing drouter = dproc + dqueue + dtrans + dprop Queueing delay is variable, the rest is constant. Processing varies, but just a little.
How about propagation speed?
The light is not that fast! • Speed of light: 200’000’000m/s • Earth radius: 40’000’000m 8’000’000m -> 0.04 seconds!
What if the queue is full?
Packet loss buffer (waiting area) packet being transmitted A B packet arriving to full buffer is lost
OK, now to data transmission…
How to transmit data? Magic
Links can transmit bits 10011010…
Ones and zeros • Computers work with bits (1s and 0s): • store bits • transmit bits • How to get from bits to texts and multimedia?
Converting numbers to binary An excellent 3min video on converting numbers to binary: https://www.youtube.com/watch?v=XdZqk8BXPwg In short: divide by two, write 1 under odd numbers, 0 under even numbers
From multimedia to bits (step 1) Integer numbers Bits (1s and 0s)
Audio -> numbers?
Audio to numbers (sampling)
Picture -> numbers?
Image to bits • Divide the image into pixels • Each pixel has a color • Number all possible colors • Each pixel becomes a number
Text -> numbers
Each character gets a number
From multimedia to bits Video Audio Image Image Image Text Integer numbers Bits (1s and 0s)
Size limitations • Each packet has a maximum size • How to transmit the gigabytes of cat videos?
Long bit streams to packets 10011010101011101001000111010111 10011010 10101110 10010001 11010111 #1 #2 #3 #4
Have I convinced you? 1. Any data => numbers => bits (binary numbers) 2. Split bit streams into packets, number them
Packet analysis with Wireshark • See video tutorial • We work with that in the Labs
You can also read