introduction to computer networks – a selective overview 國立政治大學 資訊科學系...
Post on 19-Dec-2015
270 views
TRANSCRIPT
Introduction to Computer Networks
– A Selective Overview
國立政治大學資訊科學系
劉吉軒 副教授
Computer Communication
Transfer a file of data Access information from a database Exchange of electronic mail Financial transaction Share the use of peripheral devices Access a remote supercomputer Industrial control/Business activity
Basic Communication Functions
Data Communication Networks
Simple computer-to-computer Involved only two computers Two alternatives
Point-to-point wire link Public carrier facilities
Public switched telephone network (PSTN) Modem link
Two Computers Only
More Than Two Computers
LAN – local area networks All computers are located in a single office
or building or site Enable all computers to communicate with
one another at different times Involve different techniques and
equipments or devices
LAN-based Systems
Wider Area
Computers are located in different sites Use public carrier facilities Wide Area Network (WAN) Enterprise-wide private network
Lease dedicated transmission lines (circuits) from the public carriers
Enterprise-wide Private Network
More General Solutions
Public switched data network (PSDN) most public carriers now provide this, in addi
tion to providing PSTN such networks, like PSTN, are now intercon
nected internationally transmit data rather than voice
Alternatively, convert existing PSTNs to enable data to be transmitted without modems ISDNs (Integrated Services Digital Networks)
Public Carrier Data Networks
Internet Embrace multiple networks, LAN-WAN-
LAN
Broadband Multiple-service Networks
Traditional networks primarily support data-only services
New applications Desktop video telephony Videoconferencing, etc.
Require high transmission bit rates ATM (Asynchronous Transfer Mode)
Broadband Multiple-service Networks
Categories of Networks
Local Area Networks (LANs) Metropolitan Area Networks (MANs) Wide Area Networks (WANs) Size, ownership, the distance it covers, ph
ysical architecture
LAN
Usually privately owned and links the devices in a single office, building, or campus
Size is limited to a few kilometers Designed to allow resources to be
shared between PCs or workstations Hardware – printer, hard disk, Software – application programs Data
LAN
LAN
A given LAN will use only one type of transmission medium
The most common LAN topologies are bus, ring, and star
Traditionally, LAN data rates – 4 to 16 Mbps
Today – can reach 100 Mbps
MAN
Designed to extend over an entire city May be a single network such as a cable television
network May be a means of connecting a number of LANs
into a larger network May be wholly owned and operated by a private
company May be a service provided by a public company Many telephone companies provide a popular
MAN service called Switched Multi-megabit Data Services (SMDS)
MAN
WAN
Provides long-distance transmission over large geographical areas that may comprise a country, a continent, or even the whole world
May utilize public, leased, or private communication devices, usually in combination
Enterprise network – wholly owned and used by a single company
WAN
Internetworks
Connecting two or more networks devices – routers, gateways
Internet – a specific worldwide network
TCP/IP
A set of protocols, or a protocol suite, that defines how all transmissions are exchanged across the Internet
Named after its two most popular protocols TCP - Transmission control protocol IP - Internetworking protocol
In active use for almost 20 years Demonstrated its effectiveness on a
worldwide scale
History
APARNET (1969) A packet-switching network of computers
linked by point-to-point leased lines Research result of a project funded by ARPA
The conventions developed to specify how individual computers could communicate across that network became TCP/IP
TCP/IP and the Internet Developed together, each shaping the
growth of the other An internet under TCP/IP operates like
a single network connecting many computers of any size and type
TCP/IP and OSI TCP was developed before OSI
Encapsulation
Message – user datagram – datagram – frame – bits (signals)
The movement of datagram across the Internet is the responsibility of the TCP/IP protocol
Transmitted as signals along the transmission media
Network Layer
More accurately, the internetwork layer IP + ARP, RARP, ICMP, IGMP (supporting pro
tocols) Internetwork Protocol (IP)
Transmission mechanism across networks Datagrams are transported independently Unreliable, connectionless datagram protocol Best-effort delivery service (no error checking
or tracking)
IP
Possible reasons of transmission failures Noise (bit errors), congestion, routing loop,
disable links Example of best effort – postal delivery IP provides bare-bones transmission
functions that free the user to add only those facilities necessary for a given application and thereby allows for maximum efficiency
Datagram Packets in the IP layer
Addressing
IP address – an address that identifies the connection of a host to its network An addressing convention at the Internet le
vel Physical address (contained on NICs) ident
ifies individual devices within a local network
Four bytes (32 bits) – class type, netid, hostid
IP Address Classes cover the needs of different types of
organizations
IP addresses Notation
IP address = Internet address
Class Ranges of IP Addresses
Nodes with More Than One Address
An Internet address defines the node’s connection to its network
More than one internet address Any device connected to more than one
network (any router) Any device with more than one connection to
the network
A Sample Internet
Client-Server Paradigm
One of the benefits of networks is the ability to distribute processing responsibilities
Domain Name System (DNS) Identification systems
Designed for machines and software – bit patterns and numbers
People are the actual users – prefer names DNS identifies each host on the Internet
with a unique name Given the domain name, a program can
obtain the IP address associated with it by engaging the services of a name server in a client-server session
DNS
A hierarchical system made up of a number of labels separated by dots Unique name Decentralized and easy to change From left to right – from lower to higher
Three different domains – generic (organization), country, reverse
DNS
Telnet A client-server process for remote login
Allow a user at one site to gain access to a computer at another site
Telnet Security – login and password identifiers
File Transfer Protocols Trivial File Transfer Protocol (TFTP)
Allows a local host to obtain files from a remote host but does not provide security or reliability
Simpler to use and smaller to store
FTP
Standard mechanism for copying a file from one host to another Use TCP – reliable and secure Use Telnet – require login id and password
Electronic Mail: SMTP
Simple Mail Transfer Protocol A system for sending messages or files to other
computer users based on mailbox addresses rather than a direct host-to-host exchange
Echo the postal system Addresses are used to identify both the recipient and
sender of a message Messages that cannot be delivered within a specified
amount of time are returned to the sender Received mail is stored in the mailbox until the
recipient removes or discards it
Electronic Mail
Spooling mechanism Allows a user to send mail even if a
network is currently disconnected or the receiving machine is not operational
When a message is sent, a copy of is placed in a storage facility called a spool
The background client (MTA) process looks for new messages and not-yet-sent old messages and attempt delivery
Electronic Mail Addresses Mailbox identifying name + domain name
Protocols other than TCP/IP – xxx%yyy@zzzz
Aliases Forward messages to more than one
recipient at a time by including several mailing addresses
Electronic mailing list Frequent messages are sent to the same
group of people Mail alias expansion – allows one name
(called an alias) to refer to an entirely different name or even to multiple recipients
Electronic Mail Mechanism
HyperText Transfer Protocol (HTTP)
A file-retrieving application program that can access distributed and linked documents on the World Wide Web
Hypertext – linked textual documents Hypermedia – linked documents
containing images, graphics, and sounds
HTTP Commands
World Wide Web A repository of information linked together
WWW Information is stored in a set of documents Use the concept of hypertext
WWW
A hypertext available on the Web is called a page The main page for an organization or an
individual is known as homepage Undistributed
Information about one specific subject consists of one or more Web pages on the same server
Distributed On different servers
Uniform Resource Locator When a client needs to access a Web
page, it needs an address URL is a standard for specifying any
kind of information on the Internet
URL Method – the protocol used to retrieve the
document Gopher, FTP, HTTP, news, TELNET
Host – the computer at which the information is located The name of the computer can be an alias Web pages are usually stored in computers
given alias names that usually begin with www Path – pathname of the file
Browser Architecture Access, interpret, and display Web
documents Controller, client programs, interpreters
Types of Web Documents
Based on the time when the contents of the documents are determined
Static documents fixed after creation, stored in a server The same content, independent of user ac
cess (identity, location, time) HTML (HyperText Markup Language)
A markup language for writing Web pages Let the browser format the Web pages (dis
play)
HTML
Dynamic Documents
Created by a Web server whenever a browser requests the document An application program is called upon to
create the dynamic document The server returns the output of the program
as a response to the browser that requested the document
The content of the document may depend on time, identity and location of requested host
Accessing a Dynamic Documents
CGI
Common gateway interface A standard for building dynamic Web
documents Defines the type of language to be used
in preparing the documents Most of the CGI programs have been
created using shell scripts in UNIX The script is run at the server side
Active Documents Created at the
client site by a program retrieved from the server site and run at the client site
Animated graphics
Active Documents
The interpreter at the client site is responsible for running the program
Java – a technology and a language Programming language, runtime
environment, class library Use the term applet to define an active
document program – distinguish active programs from regular program
固網 固定通信網路 電信服務
市內電話、長途電話、國際電話等 電腦網路、 資料傳輸服務
ADSL 上網 企業數據專線、企業 Intranet 廣域網路
固網公司服務
固網骨幹網 地底下的電訊高速公路
都會區骨幹網路
光纖 訊號傳輸媒介
光纖 頻寬大,資料傳輸量
大、速度快
光纖連結
海底電纜 對外傳輸線路
海纜舖設