CSC 110 - Intro. to Computing

Download Report

Transcript CSC 110 - Intro. to Computing

CSC 110 Intro. to Computing
Lecture 23:
Networks
Announcements
Quiz #5 on Thursday
 Homework #6 (on networks) due Friday

 Quiz
#6 (also on networks) will be next week
OSI Reference Model

Open Systems Interconnect Reference Model
 Established
by International Organization for
Standardization (ISO)
 Models how computers connect in networks


Allows different systems (e.g., Windows and
Macs) to connect on a single network
Proprietary networks may not use OSI
Reference Model
 But
then may be unable to connect to other networks!
Using OSI Reference Model
Each layer is independent of others
 New technologies created at
appropriate layer

 New
IM client need
not consider how
computers are
connected
 New wireless
technologies does not consider applications
Physical Layer
You are here
Physical Layer
0

1
Transmits 0s & 1s
 Only
deals with transmissions of 0s and 1s
Physical Layer Examples

Examples of the physical layer
connection: modem’s phone-line
 DSL/Cable: cable from computer to modem;
cable from model to wall
 Ethernet: cable from wall to computer
 Dial-up
Physical Layer Examples
0

1
“Physical” name can be misleading
 May
not involve physical items such as
 wireless using radio signals to/from computer
Data Link Layer
You are here
Data Link Layer
0

Physical layer transmits 0s and 1s
 Does
not know or care if other machine is on
Data Link Layer
0

Physical Layer
0
Ensures data received by other machine
 Has
no clue how data is transmitted, however
Physical & Data Link Example
Network Layer
You are here
Network Layer

Assumes connections between machines
work
 No

problem; handled by model’s lower levels
Network layer handles local-area network
 Typically
referred to using its acronym: LAN
 LAN is connects relatively small number of
“physically” interconnected machines
LAN Topologies
Defines how machines in LAN connected
 3 dominant topologies exist

 Each
has advantages and disadvantages
 No single solution works in all situations
Ring topology – like a traffic rotary/circle
 Star topology – like flying on an airline
 Bus topology – similar to computer buses

Ring Topology
1
Target0
Source1
1 Target1
1
1
Source0
Each machine connected to 2 others
 All data flows in one fixed direction

Ring Topology
1
1
1
1 Target
1
1
Source
Hard to add new nodes (computers)
 Can be very slow

Star Topology
Target 1
1
1 Source
Machines connected to center node
 All data flows must through this machine

Star Topology
Target1
1
0
Target0
1
0
Oops!!
Source0 0
1 Source1
Fairly quick & easy to add new machines
 Need to be careful to handle collisions

Bus Topology
Target
1
1
1
1
1
1
Source
Machines connect to central bus
 Data flows to every machine on the bus

Bus Topology
Target1
Source0
1
1
1
1
Big
Oops!!!
1
1
Target0
Source1
Easiest network to build, can be fastest
 But needs sophisticated collision handler

Transport Layer
You are here
Transport Layer

Transport layer deals with internetworking
 Internetworking
– Communication between
networks
 When we combine LANs we call the resulting
structure a WAN (wide-area network)
Wide-Area Network
Canisius.Buf
Canisius.Amh

Gateway – computer in a LAN that
connects to a different LAN
Sidebar: internet vs. Internet

an internet –network which joins multiple
LANs together
 Rarely

used synonym for WAN
the Internet – global network created by
joining many networks together using IP
for transport layer
 IP
(Internet Protocol) defines how each
computer can be uniquely identified and how
to pass information across networks
Internet

Internet relies on backbone of high-speed
connections to carry traffic between
networks
 Backbone

supported by AT&T, IBM, & others
Routing data between networks relies
upon knowing computer’s IP address
 IP
software breaks up data and routes it
across networks
 Each portion of data may be routed differently
Two Forms of IP Address

Numerical
 Usually
written as four 8-bit numbers
 Typically something like 192.28.12.1
 Easiest for computers to use

Hostname
 Usually
written as three or four words
separated by a “.”
 Often something such as aries.canisius.edu
 Easiest for humans to use
IP Address

Consider aries.canisius.edu
 Each
of these words helps identify the
computer in question

Similar setup exists for numerical
addresses
Top-Level Domains

The last word of the hostname (edu) is its
top-level domain (TLD) name
Country Codes
Most TLDs controlled by a US-regulated
corporation
 Other countries maintain own TLD

Domain Name

Last two words of hostname are the
domain name
 Example
domain names: canisius.edu,
cnn.com, whitehouse.gov, wendys.ca,
google.com, google.co.uk

Each domain name is unique to the
organization
 Must
be registered yearly through central
registrar for the TLD
Computer Name

First word of hostname is the computer
name
 Computer

Only one computer named www at Canisius
 Names

names unique within a domain
may not be unique between domains
Lots of computers on Internet named www
Domain Name System

The domain name system (DNS)
translates hostnames into numeric IP
addresses
 DNS
is an example of a distributed database
 If a can server resolves the hostname, done
 If not, server asks another DNS server
 Every TLD has 1 – 6 root DNS servers which
contain all records

If necessary, can eventually ask one of these
OSI Reference Model so far

Only discussed moving data between
computers
 Using/interpreting
data occurs at higher levels
Back to the Network Layer
Common question is to find how long
network would take to process requests
 For ring topologies, this is simple

 Remember
to move all data at the same time
Ring Topology
1
Target0
Source1
1 Target1
1
1
Source0
All data flows in one fixed direction
 All machines can send data at once

Star Topology
Target 1
1
1 Source


Central node can receive from only one machine
at a time
Can send & receive data at same time, however
Star Topology Timing




Nodes in star network begin by sending data
Collision occurs when multiple nodes send data
to center node at same time
Bad news: central node cannot differentiate all
the different data
Good news: central node serves as traffic cop
 Orders
nodes by their ID number
 Requests data from first node at first time unit after
collision
 Reads new data and sends out results in following
units
Star Topology
Node #2 1
0
Node #2000
1
0
Node #3 0
1 Node #4
Since 3 < 4, handle data from Node #3, then Node
#4 (then Nodes #5 - 2000, as needed)
Bus Topology Timing


No central node to determine the order node
should send data after a collision
Nodes use simple heuristic to avoid further
collisions
 Lots
of different heuristics exist, but class uses simple
one
 After collision, each node waits number of time units
equal to its node ID number before send data
 Note: this may result in some wasted time units
(unless more traffic is generated)
For Next Lecture
Read chapter 16
 Do homework #5
 Get your service learning finished ASAP!

 Start
polishing your essay before its due