1 / 42

LSVE: A Network Primer

LSVE: A Network Primer. Manuel Oliveira Computer Science Department University College London. Audience Assessment. Know about networks? Know what TCP, UDP, multicast is? Know how a router works inside? Know about multicast routing algorithms?. Contents. Motivation

rumer
Download Presentation

LSVE: A Network Primer

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. LSVE: A Network Primer Manuel Oliveira Computer Science Department University College London

  2. Audience Assessment • Know about networks? • Know what TCP, UDP, multicast is? • Know how a router works inside? • Know about multicast routing algorithms?

  3. Contents • Motivation • How to Talk to Network People? • Network Elements • Network Properties • Protocols • Multicast • How to Access the Network • Discussion

  4. Motivation: Applications • Remote Training • Combat Simulation • Games • Education • Visualization • Collaboration • Socialization

  5. Motivation: Evolution MATRIX VE Presence Online Games Graphical MUDs MUDs Evolution

  6. Motivation: Games?

  7. Motivation: Games Perspective • Humans are Social Beings • Collaboration • Share Experiences • UO most popular activity? • Competition • Online categories: achievers, explorers, socializers and killers • A Human is better than AI/AL

  8. Motivation: Games Better than VE? Games VE* Big budgets 2-3 years cycle Content driven Entertainment Robust Cool graphics Network is not cool Budget? PhD, masters or undergraduate Functionality driven Test research ideas Hacks Cool slow graphics Network less bad * DIS systems are an exception

  9. How to Talk to Network People: OSI Model Host A Host B protocol Layer n+1 Layer n+1 API Layer n Layer n Network

  10. How to Talk to Network People: OSI Model Data Host A Layer n+1 PDU n+1 Data Layer n PDU n PDU n+1 Data

  11. How to Talk to Network People: OSI How to Talk to Network People: OSI Model Application Presentation Session Transport Network Data Link Physical

  12. How to Talk to Network People: OSI How to Talk to Network People: OSI Model Application Application Presentation Presentation Session Session Transport Transport Network Network Data Link Data Link Physical Physical

  13. How to Talk to Network People: OSI vs IP Application Application Presentation Session Transport Transport OS Network Internet Protocol Data Link Data Link Physical

  14. How to Talk to Network People: IP Application FTP SMTP DNS SNMP TCP UDP Transport ICMP Internet Protocol IP IGMP Data Link ARP/RARP SNAP Ethernet, FDDI

  15. Network Elements: Overview • Address • Host • User’s computer has unique IP address • Router • Routes the data packets across the network • Queues per link for incoming packets • Lookup table • Gateway • Router that does protocol conversion

  16. Network Elements: Address + Port • Class A (network ID = 7 bits) • Class B (network ID = 14 bits) • Class C (network ID = 21 bits) • Class D (multicast) • Class E (reserved for future use) 0 Network ID Host ID 1 0 Network ID Host ID 1 1 0 Network ID Host ID 1 1 1 0 Multicast group 1 1 1 1 0 reserved

  17. Network Elements: IP Packet Version Hdr len Type Of Service Packet Len Identification Flags Fragment Offset 20 bytes TTL Protocol ID Hdr Cheksum Source address Destination address Options (if any) Data

  18. Network Elements: IP Routing Admin commands UDP TCP Other y n Local? ICMP redirects routing Options Next Hop? Routing Table src routing Queue Network Interface

  19. Network Properties • Latency (Round Trip Time) • Jitter • Bandwidth (Capacity) • Loss (Congestion, Reliability)

  20. Protocols Transport Level: • User Datagram Protocol (UDP) • Transport Control Protocol (TCP) • Application • Real Time Protocol (RTP) • Network Time Protocol (NTP) • File Transfer Protocol (FTP) • Domain Name Service (DNS)

  21. Protocols: UDP • Connectionless • No state is maintained • No setup time • Light-weight • No Quality of Service • No guarantee delivery • No order delivery Postal Service

  22. Protocols: UDP packet Source Port Destination Port 8 bytes Length Hdr Cheksum Data

  23. Protocols: TCP • Connection Oriented • State is maintained at routers • Setup Handshake • Heavy-weight • Quality of Service • FIFO delivery • Flow Control • Error Recovery • Mechanisms • Sliding Window, Timers, Acknowledgements Telephone Service

  24. Timer Packet N Ack N Protocols: TCP Peek under the Hood Host A Host B

  25. Timer Timer Packet N Packet N Ack N Protocols: TCP Peek under the Hood Host A Host B

  26. Protocols: TCP packet Source port Destination port Sequence number 20 bytes Ack number Hdr len Options Flags Window size Checksum Urgent Pointer Options (if any) Data

  27. Broadcast WAN WAN Multicast WAN Unicast Multicast: Overview

  28. Multicast: Model • UDP class D address – No physical meaning • Multicast is free on LANs • An address defines a logical group • A sender is oblivious to receivers • Join/Leave operations • Tree Based Routing

  29. Multicast: Routing Overview Multicast Routing Protocol Internet Group Management Protocol (IGMP)

  30. Multicast: Routing • Three types: • Flood/Prune (or Reverse Path Multicast) – basis for MBone • Steiner - never implemented, just simulated • Centred Based – begins to be deployed • Some Protocols: • Distance Vector Router Multicast Protocol (DVRMP) • Multicast Open Shortest Path First (MOSPF) – based on link info • Core Based Trees (CBT) • Protocol Independent Multicast (PIM) • Sparse Mode (SM), Dense Mode (DM)

  31. join join join Multicast: Core Based Trees CBT IGMP

  32. join-ack join-ack join join Multicast: Core Based Trees CBT IGMP

  33. join-ack Multicast: Core Based Trees CBT IGMP

  34. Multicast: Core Based Trees CBT IGMP

  35. Multicast: Problems • Deployment problems • mainly interdomain routing • No pricing model • Membership Authorisation • Security • Address Allocation: • Scope • Clashes • Announce/Listen (sdr) • TCP-Friendliness (congestion) • Error Recovery is a nightmare

  36. Multicast: Temporary Solution • Single Source Multicast (SSM) • IGMPv3 – who to listen to • Multicast Source Discovery Protocol (MSDP) – RP exchange • Multicast Address Dynamic Client Allocation Protocol (MADCAP) – Multicast DHCP

  37. Protocol 0 = default Protocol Family Socket Type How to Access Network: C • Creating a Socket int sock; if ((sock = socket (PF_INET, SOCK_STREAM, 0))<0) { do error handling return }

  38. How to Access Network: C • TCP - Server struct sockaddr_in auxAddr; bzero((char *)&auxAddr, sizeof(auxAddr)); auxAddr.sin_family = PF_INET; auxAddr.sin_addr.s_addr = htonl(INADDR_ANY); auxAddr.sin_port = htons(800); If (bind(sock, (struct sockaddr *)&auxAddr, sizeof(auxAddr)) == -1) { do error handling return; }

  39. How to Access Network: C • TCP - Server struct sockaddr_in clientAddr; int clientSock; listen(sock, 20); while (clientSock = accept(sock, (struct sockaddr *)& clientAddr, sizeof(clientAddr)) != -1) { process the clientSock, use threads! } do error handling

  40. How to Access Network: C • TCP – Client struct sockaddr_in auxAddr; bzero((char *)&auxAddr, sizeof(auxAddr)); auxAddr.sin_family = PF_INET; auxAddr.sin_addr.s_addr = inet_addr(“137.158.128.5”); auxAddr.sin_port = htons(800); if (connect(sock, (struct sockaddr *)&auxAddr, sizeof(auxAddr)) == -1) { do error handling }

  41. How to Access Network: C • TCP – Client • int write(int /*socket*/, byte * /*data*/, int /*data len*/) • int read(int /*socket*/, byte * /*buffer*/, int /*max to read*/)

  42. Discussion

More Related