CMPUT101 Introduction to Computing(c) Yngvi Bjornsson1 Computer Networks Chapter 12 Topics: ...

25
CMPUT101 Introduction to Comput ing (c) Yngvi Bjornsson 1 Computer Networks Computer Networks Chapter 12 Chapter 12 Topics: Topics: Communication links Communication links LAN / WAN LAN / WAN Internet / WWW Internet / WWW
  • date post

    21-Dec-2015
  • Category

    Documents

  • view

    216
  • download

    0

Transcript of CMPUT101 Introduction to Computing(c) Yngvi Bjornsson1 Computer Networks Chapter 12 Topics: ...

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 1

Computer NetworksComputer Networks

Chapter 12Chapter 12Topics:Topics:

Communication linksCommunication linksLAN / WANLAN / WAN

Internet / WWWInternet / WWW

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 2

Computer NetworksComputer Networks

• A A computer networkcomputer network is a set of independent is a set of independent computer systems interconnected by computer systems interconnected by telecommunication links.telecommunication links.

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 3

Telecommunication LinksTelecommunication Links• The connection links:The connection links:

– Are used to transmit data between the computers on Are used to transmit data between the computers on the network. the network.

– The links could be: The links could be: • wires (cables, telephone-lines), or even wires (cables, telephone-lines), or even • wireless (radio transmitters, satellites).wireless (radio transmitters, satellites).

• The The transmission ratetransmission rate or or bandwidthbandwidth of a link: of a link:– Is the amount of data that can be transmitted over a Is the amount of data that can be transmitted over a

connection in a given period of time.connection in a given period of time.– Is typically measure in Is typically measure in bpsbps (bits-per-second). (bits-per-second).

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 4

ConnectingConnecting

• In a local network (office, building, campus), In a local network (office, building, campus), computers a usually connected via dedicated links, computers a usually connected via dedicated links, such as:such as:– Twisted pair wire Twisted pair wire – Coaxial cableCoaxial cable– Fiber-optic cableFiber-optic cable

• But what if we want to connect from home?But what if we want to connect from home?– Telephone-linesTelephone-lines– Cable TVCable TV

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 5

Connecting via Telephone Connecting via Telephone LinesLines

• Problem:Problem:– Telephone systems were build to carry voice as Telephone systems were build to carry voice as

analoganalog data, but computers use data, but computers use digitaldigital (binary) data. (binary) data.• Solution:Solution:

– At the sending end the data is converted to analog At the sending end the data is converted to analog signal (signal (momodulate).dulate).

– At the receiving end: the analog signal is converted At the receiving end: the analog signal is converted back to digital data (back to digital data (demdemodulate).odulate).

• The device that does this is called a The device that does this is called a modemmodem..• Bandwidth: up to 56 KbpsBandwidth: up to 56 Kbps

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 6

ISDNISDN

• Telephone companies are now also offering ISDN Telephone companies are now also offering ISDN connections (Integrated Services Digital Network)connections (Integrated Services Digital Network)– Communications links capable of handling digital signals.Communications links capable of handling digital signals.– Can also be used for normal telephone calls, a device Can also be used for normal telephone calls, a device

called Terminal Adaptor (TA) converts the analog called Terminal Adaptor (TA) converts the analog telephone signal to/from a digital signal.telephone signal to/from a digital signal.

• Need: Need: – ISDN adapter in your computer ISDN adapter in your computer

• Bandwidth: 128KbpsBandwidth: 128Kbps

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 7

Cable ModemCable Modem• A device called a A device called a cable modemcable modem allows to transmit data allows to transmit data

via a cable TV connection:via a cable TV connection:– Does modulate the digital signals so can be transmitted (but Does modulate the digital signals so can be transmitted (but

without interfering with the TV picture).without interfering with the TV picture).• NeedsNeeds

– Cable TV outletCable TV outlet– A cable modem (rental included in monthly fee)A cable modem (rental included in monthly fee)– A network card in your computer.A network card in your computer.

• Advantages:Advantages:– Dedicated connection (don't have to dial in). Dedicated connection (don't have to dial in). – Bandwidth: up to 45 Mbps (but shared by all users on cable)Bandwidth: up to 45 Mbps (but shared by all users on cable)

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 8

Cable Modem SetupCable Modem Setup

Taken from "The Emergence of Cable Modem Access"

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 9

Computer NetworksComputer Networks

• We distinguish between two different type of networks:We distinguish between two different type of networks:• LAN (Local Area Networks)LAN (Local Area Networks)

– Used to connect computers in close physical proximity (office, Used to connect computers in close physical proximity (office, building, campus)building, campus)

• WAN (Wide Area Networks)WAN (Wide Area Networks)– Used to connect computers across cities, countries, Used to connect computers across cities, countries,

continents.continents.• The two type of networks use totally different: The two type of networks use totally different:

– Network topology Network topology – Communication protocolsCommunication protocols

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 10

Local Area Networks Local Area Networks (LANs)(LANs)

• Many different types of LANs, but (by far) the Many different types of LANs, but (by far) the most widely used are most widely used are EthernetsEthernets..– Bandwidth: 10mbps-100mbps Bandwidth: 10mbps-100mbps – Each computer on the network has installed an Each computer on the network has installed an

Ethernet adapter.Ethernet adapter.• Ethernet LAN's can be constructed in two Ethernet LAN's can be constructed in two

different ways, either usingdifferent ways, either using– a shared cablea shared cable– a HUBa HUB

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 11

Ethernet LAN using a Ethernet LAN using a Shared CableShared Cable

• A shared (coaxial) cable is stretched around the A shared (coaxial) cable is stretched around the area (a home, office, building, campus, ...).area (a home, office, building, campus, ...).

• The computers connect to the cable via sockets The computers connect to the cable via sockets called transceivers.called transceivers.

Transceiver

Shared cable

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 12

Ethernet LAN using a HUBEthernet LAN using a HUB

• No shared cable. No shared cable. • All computers connect directly to a central device All computers connect directly to a central device

called a HUB (or a device called a Switch).called a HUB (or a device called a Switch).

HUB: sends message to all the otherSwitch: sends message only to callee

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 13

Ethernet Communication Ethernet Communication ProtocolProtocol

• The rules of how data is transferred over the network is called:The rules of how data is transferred over the network is called:– a a communication protocolcommunication protocol (same protocol used regardless of how the (same protocol used regardless of how the

network is constructed.network is constructed.• Communication technique (no central control):Communication technique (no central control):

– Each computer on the network has an unique address. Each computer on the network has an unique address. – A message to address is broadcasted over the network. Every A message to address is broadcasted over the network. Every

computer receives the message, but only the computer with a computer receives the message, but only the computer with a matching address stores the message.matching address stores the message.

– Contention-based transmission:Contention-based transmission:• Listens to line and wait until free, then send.Listens to line and wait until free, then send.• If collision (two or more computers send at same time), wait a random amount If collision (two or more computers send at same time), wait a random amount

of time, then retry.of time, then retry.

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 14

Wide Area Networks Wide Area Networks (WANs)(WANs)

• Used to connect computer systems that are far Used to connect computer systems that are far apart, e.g. across a city, country, continent.apart, e.g. across a city, country, continent.

• Network topology different from LAN's:Network topology different from LAN's:– Point-to-Point communications links (one computer Point-to-Point communications links (one computer

connects directly to another computer)connects directly to another computer)• Communication protocols different from LAN's:Communication protocols different from LAN's:

– Send a fixed maximum size packages instead of Send a fixed maximum size packages instead of whole messages.whole messages.

– Use store-and-forward, package-switching protocolUse store-and-forward, package-switching protocol

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 15

Network Topology WANNetwork Topology WAN• Point-to-Point communication lines, that is, a link directly Point-to-Point communication lines, that is, a link directly

connects two computers.connects two computers.• Not all computers directly connected (but there exists a Not all computers directly connected (but there exists a

path between any two).path between any two).

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 16

Communication Protocols Communication Protocols WANWAN

• Messages transmitted via store-and-forward Messages transmitted via store-and-forward packet switching:packet switching:– A message is split into packages (1000-1500 bytes).A message is split into packages (1000-1500 bytes).– A router determines best path to send the packages.A router determines best path to send the packages.– Packages are forwarded from a node-to-nodePackages are forwarded from a node-to-node

• When receiving a package a node (computer) sends an When receiving a package a node (computer) sends an acknowledge to sending node, which can then delete local acknowledge to sending node, which can then delete local copy of package.copy of package.

– At receiving end the message is reconstructedAt receiving end the message is reconstructed

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 17

Mixing LAN/WANMixing LAN/WAN• LAN's connect to WAN's via LAN's connect to WAN's via routersrouters..• Routers:Routers:

– Determine the path to take in the WANDetermine the path to take in the WAN– Reconfigure messages between LAN/WAN communication Reconfigure messages between LAN/WAN communication

protocolsprotocols

Router

Router

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 18

The InternetThe Internet

• The first computer-to-computer message was The first computer-to-computer message was sent in 1969.sent in 1969.

• Today the Internet consists of estimatedToday the Internet consists of estimated– 30 million interconnected computers30 million interconnected computers– hundred of millions of usershundred of millions of users– in over 150 countries.in over 150 countries.

• The World Wide Web is the most popular The World Wide Web is the most popular component of the internet.component of the internet.

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 19

Internet - A network of Internet - A network of networksnetworks

WAN/LANsWAN/LANs

WAN/LANs

WAN/LANs

Gateways

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 20

Internet InfrastructureInternet Infrastructure

• The Internet is a network of networks.The Internet is a network of networks.• Is based on an Is based on an internetworkinginternetworking concept: concept:

– each network can do whatever it wants internally, buteach network can do whatever it wants internally, but– much speak a much speak a standard protocolstandard protocol externally, and externally, and – use a use a standard addressingstandard addressing scheme scheme

• A device called a gateway interconnects the A device called a gateway interconnects the networksnetworks– basically same as a routerbasically same as a router

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 21

Standard Standard Addressing/ProtocolsAddressing/Protocols

• Addressing:Addressing:– Each computer has a unique addressEach computer has a unique address

• IP addressIP address• 128.129.4.29128.129.4.29

– Domain Name System Domain Name System • easier to remember names than numberseasier to remember names than numbers• Can refer to address as: www.cs.ualberta.caCan refer to address as: www.cs.ualberta.ca

• Protocols:Protocols:– TCP/IP (Transmission Control Protocol/Internet Protocol)TCP/IP (Transmission Control Protocol/Internet Protocol)– More or less the “common language” spoken by networksMore or less the “common language” spoken by networks

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 22

Usage of internetUsage of internet

• Web-browsing (World Wide Web)Web-browsing (World Wide Web)• E-mailE-mail• Telnet (log onto and work on another computer)Telnet (log onto and work on another computer)• FTP (transfer files from one computer to FTP (transfer files from one computer to

another)another)• Newsgroups / Chat roomsNewsgroups / Chat rooms• E-CommerceE-Commerce• ......

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 23

World Wide WebWorld Wide Web

• The World Wide Web (WWW) is an information The World Wide Web (WWW) is an information sharing system based onsharing system based on– inter-linked documents (web-pages) inter-linked documents (web-pages) – that can be accessed over the internet andthat can be accessed over the internet and– viewed graphically (using a web-browser)viewed graphically (using a web-browser)

• Located via a URL (Uniform Resource Locator):Located via a URL (Uniform Resource Locator):– <protocol>://<internet address>/page<protocol>://<internet address>/page

• http://www.cs.ualberta.ca/~yngvi/cmput101http://www.cs.ualberta.ca/~yngvi/cmput101• ftp://www.cs.ualberta.caftp://www.cs.ualberta.ca

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 24

Web pagesWeb pages• A web-page is a hypertext documentA web-page is a hypertext document

– can have links to another web-pagescan have links to another web-pages– written in a language called HTMLwritten in a language called HTML

• The web-pagesThe web-pages– are stored on a computer running a are stored on a computer running a web-serverweb-server– can be accessed from any computer on the internet can be accessed from any computer on the internet

via a web-browser (Netscape, Internet Explorer).via a web-browser (Netscape, Internet Explorer).• The HTTP protocol specifies The HTTP protocol specifies

– how the Web-browser (client) gets the page from the how the Web-browser (client) gets the page from the web-server. web-server.

CMPUT101 Introduction to Computing (c) Yngvi Bjornsson 25

SummarySummary

• Computer networksComputer networks– computers connected using telecommunication linkscomputers connected using telecommunication links– Local Area Networks (LAN)Local Area Networks (LAN)– Wide Area Networks (WAN)Wide Area Networks (WAN)

• InternetInternet– Network of networksNetwork of networks– Standard addressing scheme/inter network protocolsStandard addressing scheme/inter network protocols

• WWWWWW