1 / 48

CS 620 Advanced Operating Systems

CS 620 Advanced Operating Systems. Lecture 2 – Networking Overview Professor Timothy Arndt BU 331. Networking. A computer network is a high-speed communications medium connecting many, possibly dissimilar, computers or hosts .

cianna
Download Presentation

CS 620 Advanced Operating Systems

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. CS 620 Advanced Operating Systems Lecture 2 – Networking Overview Professor Timothy Arndt BU 331

  2. Networking • A computer network is a high-speed communications medium connecting many, possibly dissimilar, computers or hosts. • A network is a combination of computer and telecommunication hardware and software. • In addition to host computers, the network may involve many dedicated computers that perform message switching (switches), relaying between LANs (bridges), joining several networks (hubs and routers) and joining dissimilar networks (gateways).

  3. Hosts and Dedicated Computers

  4. Types of Networks • Networks are usually classified as either Wide Area Networks (WAN) or Local Area Networks (LAN) • WANs span large distances and typically connect networks rather than hosts. • Speeds range from T1 (1.5 Mbps) to T3 (45 Mbps) to T5 (400 Mbps). • LANs connect hosts that are physically close and operate at 10-100 Mbps or higher. • The most widely used LAN is Ethernet running at 10 Mbps – 1 Gbps.

  5. Networking Protocols • Networking protocols are a set of rules and conventions that hosts follow in order to communicate on a network. They decide such things as: • Address formats • Data formats • Manner of data transmission • Sequencing and addressing of messages • Initiating and terminating logical connections • Establishing remote services • Accessing remote services

  6. Networking Protocols • The Internet Protocol (IP) is the most widely used networking protocol. IP is the basic protocol for the Internet and is widely supported by all major systems. • As shown in the following slides, networks are typically designed as a number of layers. • The higher layers use the services provided by the lower level layers.

  7. Networking Protocols

  8. The OSI Reference Model

  9. TCP/IP Reference Model

  10. TCP/IP Model

  11. Internet Basics • The Internet is a global network that connects IP networks. • A network of networks is called an internetwork. • The Internet evolved from the ARPANET a DARPA sponsored network that developed IP, TCP and UDP. The concept was supposed to make the military’s networks less vulnerable to attacks. • The ARPANET became the Internet when the government gave control of the network to its component members.

  12. Internet

  13. Cisco CRS-1 Backbone Core Router

  14. Internet Backbone • The Internet Backbone is operated by large telecomm companies (upstream ISPs) • AT&T, MCI, Sprint, Verizon, etc. • The backbones operated by different orgs are connected at Internet Exchange Points (IXPs)

  15. Network Addresses • An addressing scheme is an important part of a network and its protocol. • For the Internet, each host has a unique IP address represented by 4 bytes in a 32-bit quantity. • The IP address can be represented in dot notation giving the decimal value of each byte: 137.148.216.15 is the IP address of grail. • Each host may also have a domain-based name composed of words: grail.cba.csuohio.edu

  16. Network Addresses

  17. IPv6 • The information on the previous slides applies to IPv4 • A newer version, IPv6 is now coming into use • 128 bit addresses (so no NAT needed) • Classless Internet Domain Routing (CIDR) had been introduced in IPv4 to more effectively use 32 bit address space • Also different header format • Support for multicast

  18. Packet Switching • The Internet is an example of a packet switched network. A packet is routed from one host on the Internet to another. Data is sent as a sequence of packets. Individual packets may take different routes to the destination host. • Use the command traceroute to see the route that a packet takes to a particular host.

  19. Packet Switching penguin:/users/faculty/arndt> /usr/local/etc/traceroute speedy.cs.pitt.edu traceroute to speedy.cs.pitt.edu (136.142.79.2), 30 hops max, 40 byte packets 1 137.148.216.1 (137.148.216.1) 3 ms 2 ms 6 ms 2 137.148.254.16 (137.148.254.16) 5 ms 16 ms 3 ms 3 137.148.13.100 (137.148.13.100) 4 ms 25 ms 4 ms 4 clv1-sl9-1.cleveland.oar.net (199.18.113.5) 31 ms 47 ms 23 ms 5 oeb4-atm1-0.columbus.oar.net (199.18.202.14) 55 ms 79 ms 80 ms 6 Serial-0-0-1.GW1.CLE1.ALTER.NET (157.130.102.157) 75 ms 74 ms 80 ms 7 143.ATM2-0.XR1.CHI4.ALTER.NET (146.188.209.66) 104 ms 75 ms 97 ms 8 195.ATM8-0-0.GW1.CHI1.ALTER.NET (146.188.208.145) 53 ms 50 ms 34 ms 9 att-chicago-gw.customer.ALTER.NET (157.130.96.10) 45 ms 69 ms 76 ms 10 br1-a350s1.cgcil.ip.att.net (192.205.31.126) 77 ms 66 ms 58 ms 11 br2-p320.n54ny.ip.att.net (12.127.9.174) 74 ms 93 ms 59 ms 12 ar1-a3120s1.n54ny.ip.att.net (12.127.0.9) 95 ms 106 ms 73 ms 13 12.127.244.62 (12.127.244.62) 112 ms 75 ms 82 ms 14 pitt-gp.psc.net (198.32.224.8) 100 ms 95 ms 79 ms 15 fq.gw.pitt.edu (136.142.12.4) 98 ms 93 ms 76 ms 16 speedy.cs.pitt.edu (136.142.79.2) 134 ms 120 ms penguin:/users/faculty/arndt>

  20. TCP/IP • The Transmission Control Protocol/Internet Protocol (TCP/IP) suite is a standard set of networking protocols. • TCP/IP is the primary protocol of the Internet and the World Wide Web. • Almost all operating systems offer TCP/IP support, and most large networks rely on TCP/IP for much of their network traffic.

  21. Media and Topologies • TCP/IP networks can run over a variety of physical media. Most current wired networks use some sort of coaxial cable, twisted-pair cable, or fiber-optic cable. • Network adapters (also known as Network Interface Cards or NICs) provide the interface between a computer and the physical medium comprising the network connection. • They are usually built into the motherboard. May also be part of a SoC or USB device. • Network interfaces support one or more communications protocols.

  22. Media and Topologies • All network adapters have a Media Access Control (MAC) address, which is a unique identifier for that individual unit (board). • For Ethernet, wireless, and some other devices, MAC addresses are 48-bit values expressed as twelve hexadecimal digits: e.g. 00-00-F8-23-31-91. • A 64-bit scheme is also used • Hosts within a LAN can be connected into a variety of arrangements called topologies such as a bus, ring, or star.

  23. TCP/IP • Core TCP/IP protocols include: • Transmission Control Protocol (TCP) • User Datagram Protocol (UDP) • Address Resolution Protocol (ARP) • Internet Control Message Protocol (ICMP) • Internet Group Management Protocol (IGMP)

  24. Internet Protocol • Internet Protocol (IP) provides packet delivery for all other protocols in the suite. • It is a best-effort, connectionless delivery system for computer data. • The protocol’s checksum confirms only the IP header’s integrity. Responsibility for the data within the IP packet (and the sequencing) is assured only by using higher-level protocols.

  25. Transmission Control Protocol • Transmission Control Protocol provides a reliable, connection-oriented packet delivery service on top of IP. • TCP guarantees the delivery of packets, proper sequencing of packets, and provides a checksum that validates the packet header and data for accuracy. • If the network corrupts or loses a TCP packet during transmission, TCP is responsible for retransmitting the faulty packet.

  26. Transmission Control Protocol • TCP is used for session-based data transmission, client-server applications, and critical services. • TCP headers require extra bits to provide proper sequencing of information. • To guarantee successful data delivery, the protocol also requires that the recipient acknowledge successful receipt of data. • These ACKs generate additional network traffic, diminishing data speed for accuracy.

  27. User Datagram Protocol • When reliability is not essential, User Datagram Protocol (UDP), a TCP complement, offers a connectionless datagram service that guarantees neither delivery nor correct sequencing of delivered packets. • UDP checksums are optional, providing a way to exchange data over highly reliable networks without unnecessarily consuming network resources or processing time. ACKS are not enforced. • UDP also supports sending data from a single user to multiple receivers.

  28. Address Resolution Protocol • Not directly related to data transport, the Address Resolution Protocol (ARP) is one of the maintenance protocols that supports the TCP/IP suite. • To communicate across a TCP/IP network, the system sending the packet must map the IP address of the target to the physical address of the target. • IP acquires this physical address by broadcasting a special inquiry packet (an ARP request packet) containing the IP address of the target.

  29. Address Resolution Protocol • All ARP-enabled systems on the local IP network detect these messages, and the system that owns the IP address in question replies by sending its physical address to the requester. • The physical/IP address is then stored in the ARP cache of the requesting system for subsequent use. • Because the ARP reply can also be broadcast to the network, other systems on the network can update their own ARP caches.

  30. Internet Control Message Protocol • Internet Control Message Protocol (ICMP) is another maintenance protocol. It allows two systems on an IP network to share status and error information. • This information can be used by higher-level protocols to recover from transmission problems. • The ping program uses the ICMP echo request and reply packets to determine whether a particular IP system on a network is functional. The ping program can be used to diagnose IP network or router failures.

  31. Network Services • Network operations are accomplished by a number of networkservices, consisting of the software needed to perform a specific type of network task. • Network services are defined by the combination of transport protocol, IP address and port number: a logical network connection identified by a number. • Network services are provided by server services or daemon processes which listen for client requests.

  32. Daemon Processes UID PID PPID C STIME TTY TIME COMMAND root 88 1 0 03:03:20 ? 0:07 /etc/syncer root 9439 165 0 09:30:40 ttyq1 0:00 telnetd root 165 1 0 03:03:37 ? 0:17 /etc/inetd -l root 129 1 0 03:03:26 ? 0:52 /usr/etc/ypserv root 131 1 0 03:03:26 ? 0:01 /etc/ypbind root 145 1 0 03:03:35 ? 0:00 /usr/etc/rpc.mountd root 147 1 0 03:03:35 ? 0:13 /etc/nfsd 4 root 5626 165 0 07:58:31 ttyp5 0:00 rlogind root 9063 1 0 09:25:00 ? 0:00 talkd • Daemon processes generally have names which finish with a ‘d’. The inetd daemon is a server process which listens for TCP/IP requests and forks off the appropriate daemon process to service the request. This approach avoids multiple waiting daemon processes.

  33. TCP/IP Diagnostic Tools • arp: display or modify the IP-to-MAC address tables. • nslookup: interactively query a name server. • lpq: examine/manipulate jobs in a printer queue. • ping: perform a simple network connectivity test. • route: display or modify the static routing tables. • traceroute: view the route to a host. • netstat: display various network statistics • ipconfig: display information about the system’s TCP/IP configuration.

  34. Name Resolution Facilities • For convenience, high-level user commands generally use hostnames (rather than IP addresses) to specify remote locations on the network. • TCP/IP provides two methods for performing hostname-to-IP address translation (also called name resolution). • The IP address can be determined by looking up the hostname in the /etc/hosts file.

  35. The /etc/hosts File grail:/users/faculty/arndt> more /etc/hosts ## Configured using SAM by root on Mon Jul 11 15:30:33 1994 127.0.0.1 localhost # # Host Database # #----- # HP server 137.148.216.15 grail.cba.csuohio.edu cba.csuohio.edu grail # DELL PowerEdge server running Linux 137.148.216.45 arthur.cba.csuohio.edu arthur # Sun SPARC5 file server 137.148.216.17 shamu.cba.csuohio.edu shamu # Sun SPARC20 with 4 CPUs; should be quadru-pus 137.148.216.18 octopus.cba.csuohio.edu octopus # 11 Sun SPARC4 10 baseT 137.148.216.19 dolphin.cba.csuohio.edu dolphin 137.148.216.20 shark.cba.csuohio.edu shark . . . Loopback address Our name IP address alias hostname

  36. The Domain Name Service • The Domain Name Service (DNS) facility relies upon server processes running on various network-accessible systems to provide hostname-to-IP translation. • DNS organizes groups of systems into units known as domains. • DNS domains are organized into a hierarchical structure on an Internet-wide basis with the defined suffixes constituting the top-level of the tree (.com, .edu, .org, the two-character country codes, etc.).

  37. The Domain Name Service “ “ org com edu uk widgets cisco csuohio co mfg research mrp2

  38. The Domain Name Service • The administrative unit for DNS is the zone. A zone is a subtree of the DNS database that is administered as a single separate entity. • It can consist of a single domain or a domain with subdomains. • With the exception of the root, each node in the DNS database has a name of up to 63 characters. Each subdomain must have a unique name within its parent domain. Node names are concatenated and separated with a period to form a fully qualified domain name (FQDN).

  39. Name Resolution • Name resolution is provided by name servers which interpret the information in a FQDN to find its specific address. • A resolver passes a query to its local name server. If the name server does not have the data requested in the query, it queries other name servers on behalf of the resolver. • In the worst-case scenario, the local name server starts at the top of the DNS tree with one of the root name servers and works its way down until the address is found.

  40. Name Resolution • DNS name resolution consists of three key concepts: • Recursion: a resolver typically passes a recursive resolution request to its local name server. This puts the burden on the name server. • Iteration: If the local name server cannot fully resolve the query, it enlists the aid of other DNS name servers, passing an iterative resolution request (the result may only be a pointer to another server). • Caching: As local name servers process recursive requests, they discover a lot of information about the DNS name space. This information is cached.

  41. Name Resolution grail:/etc> cat resolv.conf search cba.csuohio.edu csuohio.edu nameserver 137.148.49.10 nameserver 137.148.5.26 grail:/etc> nslookup Default Name Server: csu-a.csuohio.edu Address: 137.148.49.10 > 137.148.5.26 Name Server: csu-a.csuohio.edu Address: 137.148.49.10 Name: csu-b.csuohio.edu Address: 137.148.5.26 >

  42. IP Routing • The Internet and other TCP/IP networks are connected by routers, which are devices that pass IP packets from one network to another. • It is impractical to maintain addresses for all computers on an IP network with which the local computer communicates. • Instead, a default gateway (route) which is a computer connected to the local subnet and to other networks is used. • It has knowledge of the network IDs of the other networks in the internetwork and how to reach them.

  43. IP Routing • When IP prepares to send a packet, it inserts the source IP address and the destination address of the packet in the IP header. It then examines a locally maintained route table and does one of the following: • Pass the packet up to a protocol layer above IP on the local host. • Forward the packet through one of the locally attached network adapters. • Discard the packet.

  44. IP Routing • The search for a match for the destination address in the route table proceeds from the specific to the general as follows: • Examine table for exact match. • Strip the host portion and examine table for a match (subnet route). • Strip subnet portion and examine table for a match (network route). • Use default gateway. • If no default gateway specified, discard packet.

  45. IP Routing • The default gateway contains info about the network Ids of the other networks in the internetwork, so it can forward the packet to other routers until the packet is eventually delivered to a router connected to the specified destination. • This process is known as routing.

  46. Dynamic Host Configuration Protocol • The Dynamic Host Configuration Protocol (DHCP) facility assigns IP addresses to network hosts dynamically. • This decreases the individual workstation configuration necessary for a system to be successfully connected to the network. • It is especially suited for computers that change network locations frequently (e.g. laptops). • A system is identified as a DHCP client via the General tab of its TCP/IP Properties.

  47. Dynamic Host Configuration Protocol • DHCP works as follows • When a DHCP-prepared PC starts, it sends a DHCPDISCOVER broadcast message on the LAN. • If the client doesn’t receive an answer, it keeps sending messages four times a minute for the next five minutes, or until it receives an answer. • Each DHCP server that receives a DHCPDISCOVER message searches its tables for an allocation for this PC. • If it finds one, it answers with a DHCPOFFER message, which contains the IP address the lease period, and other info.

  48. Dynamic Host Configuration Protocol • If no previous allocation exists, one or more DHCP servers answer with IP addresses belonging to the subnet on which the PC is placed. • When the PC wants to accept an IP address, it returns a DHCPREQUEST message with an identification of the chosen DHCP server. • Clients equipped with hard disks keep the allocated TCP/IP address with each subsequent start. • The client will try to renew the lease when half of the lease period is over. • If the lease period expires without a resubscription, the PC must stop using the IP address and start a new negotiation using the process described above.

More Related