Networking and Data communications.pdf is key to know the communication and the osi models

Rossy719186 185 views 108 slides Sep 08, 2025
Slide 1
Slide 1 of 108
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34
Slide 35
35
Slide 36
36
Slide 37
37
Slide 38
38
Slide 39
39
Slide 40
40
Slide 41
41
Slide 42
42
Slide 43
43
Slide 44
44
Slide 45
45
Slide 46
46
Slide 47
47
Slide 48
48
Slide 49
49
Slide 50
50
Slide 51
51
Slide 52
52
Slide 53
53
Slide 54
54
Slide 55
55
Slide 56
56
Slide 57
57
Slide 58
58
Slide 59
59
Slide 60
60
Slide 61
61
Slide 62
62
Slide 63
63
Slide 64
64
Slide 65
65
Slide 66
66
Slide 67
67
Slide 68
68
Slide 69
69
Slide 70
70
Slide 71
71
Slide 72
72
Slide 73
73
Slide 74
74
Slide 75
75
Slide 76
76
Slide 77
77
Slide 78
78
Slide 79
79
Slide 80
80
Slide 81
81
Slide 82
82
Slide 83
83
Slide 84
84
Slide 85
85
Slide 86
86
Slide 87
87
Slide 88
88
Slide 89
89
Slide 90
90
Slide 91
91
Slide 92
92
Slide 93
93
Slide 94
94
Slide 95
95
Slide 96
96
Slide 97
97
Slide 98
98
Slide 99
99
Slide 100
100
Slide 101
101
Slide 102
102
Slide 103
103
Slide 104
104
Slide 105
105
Slide 106
106
Slide 107
107
Slide 108
108

About This Presentation

data comunication and networking is the data to know how to communicate in this errer


Slide Content

1
Chapter Five
PUTTING DATA ON CABLES
(Multiple Access)
Chapter Objectives
In this chapter you will learn:

 Types of multiple Access( random and controlled access)
 Define the term Media Access Control
 Define and explain the four major access methods
 The difference between Multiple Access with Collision Avoidance (CSMA/CA and
Collision Detection (CSMA/CD)
 Describe the operation of Token ring
 Explain the difference between Polling and Token Passing

Media Access Control
Communicates directly with the network adapter card and is responsible for delivering
error-free data between two computers.
 Media Access Control
o communicates directly with the network adapter card and
o Is responsible for delivering error-free data between two computers.
o Random access: Carrier Sense Multiple Access (CSMA), Carrier Sense
Multiple Access with Collision Detection (CSMA/CD) and Carrier Sense
Multiple Access with Collision Avoidance (CSMA/CA)
o Controlled access: Reservation, Polling and Token Passing
Access Methods

The 4 major methods
a. Carrier Sense Multiple Access Methods
1. With collision detection (CSMA/CD)
2. With collision avoidance (CSMA/CA)
b. Token passing that allows only a singe opportunity to send data
c. A Demand Priority method
Introduction
 CSMA/CD : Carrier Sense Multiple Access with Collision Detection
 Packet Collisions: When multiple stations attempt to send a frame
simultaneously. Three mechanisms to address this.

2
 Carrier Sensing: Listen for the presence of signal (carrier) in the cable.
Wait until there is no signal before transmitting.
 Collisions may still occur. A sends a signal and B sends it right after that
but before it has sensed A's signal.
 Collision Detection: Send the signal (output port) and listen (input port)
and compare the two signals. If they are different then there is a
collision. Stop sending the message but send a special signal to intimate
all stations that collision has occurred.
 Retransmit after waiting for a random time (nT): T: time taken by a
signal to reach all stations, n < MAX: random number. If there is another
collision, double MAX and so on. CSMA/CD
 Efficiency: Fraction of frames transmitted successfully. Possible to get 80
- 95 %. However, noticeable delay after 50%.
Carrier Sense Multiple Access with Collision Detection. (CSMA/CD)
1. Computer senses that the cable is free.
2. Data is sent.
3. If data is on the cable, no other computer can transmit until the cable is
free again.
4. If a collision occurs, the computers wait a random period of time and
retransmit.
5. Known as a contention method because computers compete for the
opportunity to send data. (Database apps cause more traffic than other
apps)
6. This can be a slow method
7. More computers cause the network traffic to increase and performance to
degrade.
8. The ability to "listen" extends to a 2,500 meter cable length => segments
can't sense signals beyond that distance.
Carrier Sense Multiple Access with Collision Avoidance (CSMA/CA)
1. In CSMA/CA, the computer actually broadcasts a warning packet before it
begins transmitting on the wire. This packet eliminates almost all
collisions on the network because each computer on the network does not
attempt to broadcast when another computer sends the warning packet.
2. All other computers wait until the data is sent.
3. The major drawback of trying to avoid network collisions is that the
network traffic is high due to the broadcasting of the intent to send a
message.
Token Passing
1. Special packet is passed from computer to computer.
2. A computer that wants to transmit must wait for a free token.
3. Computer takes control of the token and transmits data. Only this
computer is allowed to transmit; others must wait for control of the token.

3
4. Receiving computer strips the data from the token and sends an
acknowledgment.
5. Original sending computer receives the acknowledgment and sends the
token on.
6. the token comes from the Nearest Active Upstream Neighbor and when
the computer is finished, it goes to the Nearest Active Downstream
Neighbor
7. uses "beaconing" to detect faults => this method is fault tolerant
8. NO contention => equal access to all computers on the network
9. NO collisions
Definition: The token is a special packet that is circulated around the ring. It is read from
one node than passed to the next node until it arrives at a node that needs to access the
ring (transfer information/data). When a node receives the token, the node is allowed to
send out its information packet.


Example: The token is circulating the ring; node B needs to send some data to Node G.
Node B waits for the token to come by. There is only one token allowed on the ring.
When it receives the token, it can then send out its information packet. Node G is the
destination address.

Node C receives the packet, reads the destination address and passes it on to the next
node. Node D, E & F do likewise.

4




When the packet arrives at node G, node G reads the destination address and reads the
information. Node G marks the information packet as read and passes it on.

Note: the Source and Destination addresses remain unchanged after passing through
Node G. Node B is still the Source address and Node G is still the Destination address.
The packet continues around the ring, until it reaches the source address Node B. Node B
checks to make sure that the packet has been read - this indicates that Node G is actually
present. The information packet is erased. Node B then releases the token onto the ring.

Information marked READ is passed through the ring back to the Source - Node B

5
The information packet is called the Token Frame. The token is called the Token
(sometimes referred to as the free token). This can be confusing. Remember, when we
talk about a frame, we are talking about data/information. When talking about a token,
we are talking about bus arbitration and permission to use the bus.
Demand Priority
1. Repeaters manage network access by performing cyclical searches for
requests to send from all nodes on the network. The repeater or HUB is
responsible for noting all addresses, links and end nodes and verifying if
they are all functioning. An "end node" can be a computer, bridge, router
or switch.
2. Certain types of data are given priority if data reaches the repeater
simultaneously. If two have the same priority, BOTH are serviced by
alternating between the two.
Advantages over CSMA/CD
1. Computers Uses four pairs of wires, which can send and receive
simultaneously.
2. Transmissions are through the HUB and are not broadcast to all
other computers on the network.
3. There is only communication between the sending computer, the
hub and the destination computer.
Summary Chart

Feature or
Function
CSMA/CD CSMA/CA
Token
Passing
Demand
Priority
Type of
Communication
Broadcast-
based
Broadcast-
based
Token-based Hub-based
Type of Access
Method
Contention Contention
Non-
contention
Contention
Type of
Network
Ethernet

Calculations

Question 1

Two stations on standard 10Mbps Ethernet are 200m apart. Both transmit 64 bytes,
station A starting at time 0s, and station B starting at time 0.5 microseconds. Assume
the signal propagates at 2 * 10
8
m/s.

(a) When and where do the packets collide?
(b) How many bits has station A sent before it detects the collision.
(c) How many bits has station B sent before it detects the collision.

6
(d) Which station is likely to begin retransmitting first?

Solution



Questions

3 Compare the access methods that use CSMA/CD to those that use token passing.
What are the advantages and disadvantages of each?
4 What are the advantages and disadvantages of token-ring networking?

Solutions

3. Compare the access methods that use CSMA/CD to those that use token passing.
What are the advantages and disadvantages of each? Collision detection is non-
deterministic, making it difficult to predict and achieve total bandwidth utilization. Token
passing can make use of all available bandwidth. CSMA/CD is used in Ethernet, which is
better established and used than token ring.

4. What are the advantages and disadvantages of token-ring networking?
It was developed as an IBM technology. Although Token Ring technology is now offered
by great many vendors, many in the user community perceive it as proprietary. Ethernet
is simple, reliable, and effective for the majority of networks, and at the same time, cost
significantly less than Token Ring. TCP/IP has traditionally been wed to Ethernet.
Growing industry demand for TCP/IP has accompanied a recent surge in the
Ethernet popularity. Nevertheless, Token Ring is an effective physical layer technology
with features that make it preferable under some circumstances.

7
CHAPTER 6
MODES OF DATA TRANSMISSION
Chapter Objectives
In this chapter you will learn:

 Define different modes of data flow
 Distinguish between Parallel and Serial Communication
 Distinguish between Asynchronous, Synchronous and Isochronous
Communication
 Describe Point to point and Broadcast communication

Data Flow

Data flow is the flow of data between 2 points. The direction of the data flow can be
described as:
Simplex: data flows in only one direction on the data communication line (medium).
Examples are Radio and Television broadcasts. They go from the TV station to your
home television.


Half-Duplex: data flows in both directions but only one direction at a time on the data
communication line. Ex. Conversation on walkie-talkies is a half-duplex data flow. Each
person takes turns talking. If both talk at once - nothing occurs!

Bi-directional but only 1 direction @ a time!

8

HALF-DUPLEX
Full-Duplex: data flows in both directions simultaneously. Modems are configured to
flow data in both directions.

Bi-directional both directions simultaneously!
FULL-DUPLEX
Timing

Timing refers to how the receiving system knows that it received the start of a group of
bits and the end of a group of bits. Two major timing schemes are used: Asynchronous
and Synchronous Transmission.
i. Asynchronous Transmission sends only 1 character at a time. A character being a
letter of the alphabet or number or control character. Preceding each character is a
Start bit and ending each character is 1 or more Stop bits.

ii. Synchronous Transmission sends packets of characters at a time. Each packet is
preceded by a Start Frame which is used to tell the receiving station that a new
packet of characters is arriving and to synchronize the receiving station's internal
clock. The packets also have End Frames to indicate the end of the packet. The
packet can contain up to 64,000 bits. Both Start and End Frames have a special bit

9
sequence that the receiving station recognizes to indicate the start and end of a
packet. The Start and End frames may be only 2 bytes each.

Packet
Conventional representation has asynchronous data flowing left to right and synchronous
data flowing right to left.
Asynchronous vs. Synchronous Transmission
Asynchronous transmission is simple and inexpensive to implement. It is used mainly
with Serial Ports and dialup connections. Requires start and stop bits for each character -
this adds a high overhead to transmission. For example: for every byte of data, add 1 Start
Bit and 2 Stop Bits. 11 bits are required to send 8 bits! Asynchronous is used in slow
transfer rates typically up to 56 kbps.
Synchronous transmission is more efficient as little as only 4 bytes (3 Start Framing bytes
and 1 Stop Framing byte) are required to transmit up to 64 kbits. Synchronous
transmission is more difficult and expensive to implement. It is used with all higher
communication transfer rates: Ethernet, Token Ring etc... Synchronous is used in fast
transfer rates typically 56 kbps to 100 Mbps.

Example: Compare a 10K Byte data transmission using Asynchronous transmission &
Synchronous Transmission. Determine the efficiency (10 kBytes = 80 kbits).
Asynchronous: Add 3 bits (1 Start and 2 Stop bits) for every byte transmitted.
80 kbits + 30 kbits = total of 110 kbits transmitted
Synchronous: Add 4 bytes (32 bits) for the complete 10K byte data packet.
80 kbits + 32 bits = total of 80.032 kbits transmitted
efficiency = data transmitted x 100 = 80 kbits x 100 = 99.9%
Transmission Advantages Disadvantages
Asynchronous Simple & Inexpensive High Overhead
Synchronous Efficient Complex and Expensive

10

Asynchronous Communications

Asynchronous communications or transmission sends individual characters one at a time
framed by a start bit and 1 or 2 stop bits.
Start/Stop bits
The purpose of the Start bit is to notify the receiving station of a new character arriving.
Typically data is shown moving left to right. This is how it would appear on a Storage
Oscilloscope or Network Analyzer. The MSB (Most Significant Bit) is sent first and the
LSB (Least Significant Bit) is sent last.

The purpose of the Stop bits is to indicate the end of data. There could be 1 or 2 stop bits
with 1 being the typical number of stop bits used today. In Asynchronous transmission,
the characters are sent individually with a quiet period in between (quiet meaning 0 bit
level). Asynchronous communications requires the transmitting station and the receiving
station to have individual internal free-running clocks operating at the same frequency.
Free-running means that the clocks are not locked together.
Both clocks operating at same frequency:
The receive station starts checking for data after the Start bit is received (Start bit is a
wake up call!).

The receive station samples the transmitted data in the middle of each data bit. The
samples are evenly spaced and match the transmitted data because both transmit and
receive clocks are operating at the same frequency.

11
Receive clock frequency higher than transmitted frequency:


If the receive station's clock is higher in frequency, the samples will be spaced closer
together (higher frequency - shorter period). In the above example, we transmitted the
following data: 0100 1010 but we received the data: 0100 0101. The samples are out of
synchronization with the transmitting data. We would have an error in receiving data.
Clocks are controlled by crystals (abbreviated: Xtal). Crystals are metal cans that hold a
piezo-electric element that resonates at a certain frequency when a voltage is applied to it.
If you drop a crystal or a printed circuit board (PCB) that has a crystal on it, the crystal
can fracture inside the metal can. Either it will stop working or change its frequency, both
result in a malfunctioning circuit! Crystals are also temperature sensitive and change
frequency with temperature!


Receive clock frequency lower than transmitted frequency:
If the receiving station's clock is lower in frequency than the transmitted frequency, then
the samples become farther apart (lower frequency - wider period). Again the samples
become out of sync with the transmitted data!

The transmitted data is 0100 1010 but the receive data is 0101 0101! Again we would
have received data errors.
This is a basic problem with asynchronous communications; both transmitter and receiver
require a very stable clock to work properly. At high frequencies (which result in high
transfer rates), clock stability is critical and asynchronous transmission is very difficult to
accomplish. Because of this inherent problem with asynchronous transmission, it is used
at low frequency/slow transfer rates.

12
Broadcast: A method of sending a signal where multiple parties may hear a single
sender.

Broadcast Networks

• have a single communication line shared by all computers on the network
• packets sent by a host are received by all computers
• some topologies: bus, satellite, radio
For example;
1. Radio stations are a good example of everyday life "Broadcast Network".
In this case the radio station is a type of communications called Simplex.
(In a simplex type of communication, data is only expected to flow in one
direction. In this case, away from the radio broadcast tower.)
2. Board-room meetings are another everyday example of a broadcast
network. In this example, everyone may speak to everyone else, but when
more than one person speaks, interference from multiple conversations
may make it impossible to listen to more than one conversation even
though you can hear both conversations. In this board-room example, we
can see parties are able to share access to a common media (human voice
as sound through the air.) They compete for access to speak, but for the
most part, only one person speaks at a time for everyone to hear. This is an
example of a type of communications called Half-Duplex.
Point-to-point: A method of communication where one "point" (person or entity)
speaks to another entity.
Point-to-Point Networks

• each communication line connects a pair of nodes
• a packet (or message) is transmitted from one node to another
• intermediate nodes, in general, receive and store entire packet and then
forward to the next node
• also called ―store-and-forward‖ or ―pack-switched‖
• some topologies: star, ring, tree

13

CHAPTER 7
USING TELEPHONE FOR DATA TRANSMISSION ( WAYS
OF ACCESSING THE INTERNET)

Chapter Objectives
In this chapter you will learn:

 Define telephone networks
 Describe the Telephone Line Characteristics
 Define the Modem
 describe different types of modems
 explain the standards of modems
TELEPHONE NETWORK AND DIAL -UP MODEMS
Telephone Networks

The telephone network consists of your phone at home that is connected by the Local
Loop to the Central Office which is connected to a Hierarchical Phone Network.
Worldwide there are over 300 million (300,000,000) telephones - 98% of them
interconnected.
Telephone Line Characteristics

Telephone lines are not perfect devices due to their analog nature. The quality of the
telephone line determines the rate that modulated data can be transferred. Good noise free
lines allow faster transfer rates such as 14.4 kbps, poor quality lines require the data
transfer rate to be stepped down to 9600 bps or less. Phone lines have several measurable
characteristics that determine the quality of the line:
 Attenuation Distortion
 Propagation Delay
 Envelope Delay Distortion
Attenuation Distortion
Attenuation Distortion is the change in amplitude of the transmitted signal over the Voice
Band. It is the frequency response curve of the Voice Band.

14

Attenuation versus Frequency
To measure Attenuation Distortion, the phone line has a test frequency transmitted from 0
- 4 kHz into the line at a standard amplitude of 0 db. The loss of signal or attenuation is
measured at the receiving end and compared to a standard reference frequency: 1004 Hz.
db is short for decibel which is a relative unit of measure (similar to a unit like a dozen).
It is a log unit and a +3 db gain will indicate amplitude of 2x the reference. It is a
logarithmic ratio between input voltage and output voltage. It is calculated by the
following formula:
db =10 x log (Vout/Vin)
The resulting information is graphed on Attenuation vs. Frequency chart. Attenuation is a
loss of signal amplitude - the receive signal is a smaller amplitude than the transmitted
signal. It is indicated by a positive db. It is also possible to have a signal appear at the
receiving end with a larger amplitude than when it started - this is indicated by negative
db.
The attenuation is due to the many pieces of electronic equipment and transmission
media that the signal has to pass through, some can amplify the signal (make it a larger
amplitude) and some may attenuate the signal (make it smaller).
There are maximum and minimum acceptable limits for Attenuation Distortion for phone
lines. The Basic channel conditioning is:
Frequency Range Loss (db)
500 - 2500 -2 to +8
300 - 3000 -3 to +12
The above Loss is a range of acceptable values for the frequency range. In the Basic
Channeling Conditioning, it is acceptable to have a loss in signal in the frequency range
of 500-2500 Hz of "8 db loss to -2 db loss" referenced to the amplitude at 1 kHz. Note
that on the graph on the previous page that this is shown as -8db and +2 db.

15
+3 db attenuation is equal to -3 db in signal amplitude and +8 db attenuation equates to -8
db in signal amplitude.
Propagation Delay
Signals transmitted down a phone line will take a finite time to reach the end of the line.
The delay from the time the signal was transmitted to the time it was received is called
Propagation Delay. If the propagation delay was the exact same across the frequency
range, there would be no problem. This would imply that all frequencies from 300 to
3000 Hz have the same amount of delay in reaching their destination over the phone line.
They would arrive at the destination at the same time but delayed by a small amount
called the propagation delay.
This is heard as the delay when talking on long distance telephones. We have to wait a
little longer before we speak to ensure that the other person hasn't already started to talk.
All phone lines have propagation delay.

If the Propagation Delay is long enough, the modem or communications package may
time-out and close the connection. It may think that the receive end has shut off!
Envelope Delay Distortion
If the Propagation Delay changes with frequency than we would have the condition
where the lower frequencies such as 300 Hz may arrive earlier or later than the higher
frequencies such as 3000 Hz. For voice communication, this would probably not be
noticeable but for data communication using modems, this could affect the phase of the
carrier or the modulation technique used to encode the data.
When the Propagation Delay varies across the frequency range, we call this Envelope
Delay Distortion. We measure propagation delay in microseconds (us) and the reference
is from the worst case to the best case.

16





Line Impairments

Line Impairments are faults in the line due to improper line terminations or equipment
out of specifications. These cannot be conditioned out but can be measured to determine
the amount of the impairment.
Crosstalk
Crosstalk is when one line induces a signal into another line. In voice communications,
we often hear this as another conversation going on in the background. In digital
communication, this can cause severe disruption of the data transfer. Cross talk can be
caused by overlapping of bands in a multiplexed system or by poor shielding of cables
running close to one another. There are no specific communications standards applied to
the measurement of crosstalk.

17
Modems
A modem is a Modulator/Demodulator; it connects a terminal/computer (DTE) to the
Voice Channel (dial-up line).

Basic Definition
Voice Channels
First thing that comes to mind is telephone systems and the phone at home. Talking to
someone on the phone uses Voice Channels. This doesn't seem to have much to do with
Networks!
We do use voice channels for modem communications to connect to BBSs (Bulletin
Board Services) or to connect to the Internet. We also use voice channels to connect
LANs using remote access. Due to the bandwidth limits on the Voice Channel, the data
transfer rate is relatively slow.
Voice Channel: Dial-up connection through a modem using standard telephone lines.
Typical Voice Channel communication rates are: 300, 1200, 2400, 9600, 14.4k, 19.2k,
28.8k, 33.6k and 56 kbps (bits per second).
Data Channels
Data channels are dedicated lines for communicating digitized voice and data. At the end
of 1996, there was a major milestone where more data was communicated in North
America's telecommunications system than voice.

Data Channels are special communications channels provided by the "common carriers"
such as Telus, Sprint, Bell Canada, AT&T, etc. for transferring digital data. Data
Channels are also called "Leased Lines". They are "directly" connected and you don't
have to dial a connection number. The connections are up and running 24 hours per day.
They appear as if there were a wire running directly between the source and destination.
Typical transfer rates for data communication are: 56 k, 128k, 1.544 M, 2.08 M, 45M and
155 Mbps.

18
Common carriers charge for data connections by
1. the amount of data transferred (megabytes per month)
2. the transfer rate (bits per second)
3. the amount of use (time per month)
The modem (DCE - Data Communication Equipment) is connected between the
terminal/computer (DTE - Data Terminal Equipment) and the phone line (Voice
Channel). A modem converts the DTE (Data Terminal Equipment) digital signal to an
analog signal that the Voice Channel can use.
A modem is connected to the terminal/computer's RS232 serial port (25 pin male D
connector) and the outgoing phone line with an RJ11 cable connector (same as on a
phone extension cord). Male connectors have pins, female connectors have sockets.

Digital Connection
The connection between the modem and terminal/computer is a digital connection. A
basic connection consists of a Transmit Data (TXD) line, a Receive Data (RXD) line and
many hardware hand-shaking control lines.

The control lines determine: whose turn it is to talk (modem or terminal), if the
terminal/computer is turned on, if the modem is turned on, if there is a connection to
another modem, etc.
Analog Connection
The connection between the modem and outside world (phone line) is an analog
connection. The Voice Channel has a bandwidth of 0-4 kHz but only 300 - 3400 Hz is
usable for data communications.

19
The modem converts the digital information into tones (frequencies) for transmitting
through the phone lines. The tones are in the 300-3400 Hz Voice Band.
External/Internal Modems
There are 2 basic physical types of modems: Internal & External modems. External
modems sit next to the computer and connect to the serial port using a straight through
serial cable.

Internal modems are a plug-in circuit board that sits inside the computer. It incorporates
the serial port on-board. They are less expensive than external modems because they do
not require a case, power supply and serial cable. They appear to the communication
programs as if they were an external modem for all intensive purposes.

Modem Types
There are many types of modems, the most common are:
i. Optical Modems
Uses optical fibre cable instead of wire. The modem converts the digital signal to
pulses of light to be transmitted over optical lines. (more commonly called a
media adapter or transceiver)
ii. Short Haul Modems
Modems used to transmit over 20 miles or less. Modems we use at home or to
connect computers together between different offices in the same building.
iii. Acoustic Modem
a modem that coupled to the telephone handset with what looked like suction cups

20
that contained a speaker and microphone. Used for connecting to hotel phones for
traveling salespeople.
iv. Smart Modem
Modem with a CPU (microprocessor) on board that uses the Hayes AT command
set. This allows auto-answer & dial capability rather than manually dialing &
answering.
v. Digital Modems
Converts the RS-232 digital signals to digital signals more suitable for
transmission. (also called a media adapter or transceiver)
vi. V.32 Modem
Milestone modem that used a 2400 Baud modem with 4 bit encoding. This results
in a 9600 bps (bits per second) transfer rate. It brought the price of high speed
modems below $5,000.

Baud is the speed at which the Analog data is changing on the Voice Channel and bps is
the speed that the decoded digital data is being transferred.
Features of Modems
1. Speed
the speed at which the modem can send data in bps (bits per second). Typically
modem speeds are: 300, 600, 1200, 2400, 4800, 9600, 14.4K, 19.2K, 28.8K bps
2. Auto Dial /Redial
Smart Modems can dial the phone number and & auto redial if a busy signal is
received.
3. Auto Answer
Most modems can automatically answer the phone when an incoming call comes
in. They have Ring Detect capability.
4. Self-Testing
New modems have self-testing features. They can test the digital connection to
the terminal /computer and the analog connection to a remote modem. They can
also check the modem's internal electronics.
5. Voice over Data
Voice over Data modems allow a voice conversation to take place while data is
being transmitted. This requires both the source and destination modems to have
this feature.
6. Synchronous or Asynchronous Transmission
Newer modems allow a choice of synchronous or asynchronous transmission of

21
data. Normally, modem transmission is asynchronous. We send individual
characters with just start and stop bits. Synchronous transmission or packet
transmission is used in specific applications.
Transfer Rate versus PC Bus Speed
The lowliest XT PC can out-perform the fastest modem transfer rate. For example: an XT
has an 8 bit parallel expansion bus operating at 4.77 MHz. This equates to a data transfer
rate of:
8 bits x 4.77 MHz = 38.16 Mbps
Compare this to the fastest modem transfer rates of 57.6 kbps!

CHAPTER 7
PROTOCOL ARCHITECTURE AND THE OSI MODEL

Chapter Objectives
In this chapter you will learn:

 Define the term Network protocols. Explain the protocol architecture
 Define OSI model
 Describe the importance OSI Model
 Explain the term Network standards
 Explain the advantages and disadvantages of Network standards
 Describe the importance of TCP/IP protocol architecture/suite
 Describe the functions of Network devices

Definition: Protocol
On the Internet protocol usually refers to a set of rules that define an exact format for
communication between systems. For example the HTTP protocol defines the format for
communication between web browsers and web servers, the IMAP protocol defines the
format for communication between IMAP email servers and clients, and the SSL protocol
defines a format for encrypted communications over the Internet

TYPES OF PROTOCALS

1. ROUTABLE
2. NON ROUTABLE

22
ROUTING PROTOCOLS
Definitions
1. ROUTING PROTOCOLS are the software that allows routers to dynamically
advertise and learn routes, determine which routes are available and which are the most
efficient routes to a destination. Routing protocols used by the Internet Protocol suite
include:
Routing is the process of moving data across two or more networks. Within a network, all
hosts are directly accessible because they are on the same
2. A communications protocol that contains a network address as well as a device
address. ROUTED PROTOCOLS are nothing more than data being transported across
the networks. Routed protocols include: Internet Protocol
Outside a network, specialized devices called ROUTERS are used to perform the routing
process of forwarding packets between networks. Routers are connected to the edges of
two or more networks to provide connectivity between them. These devices are usually
dedicated machines with specialized hardware and software to speed up the routing
process. These devices send and receive routing information to each other about networks
that they can and cannot reach. Routers examine all routes to a destination, determine
which routes have the best metric, and insert one or more routes into the IP routing table
on the router. By maintaining a current list of known routes, routers can quickly and
efficiently send your information on its way when received.
There are many companies that produce routers: Cisco, Juniper, Bay, Nortel, 3Com,
Cabletron, etc. Each company's product is different in how it is configured, but most will
interoperate so long as they share common physical and data link layer protocols (Cisco
HDLC or PPP over serial, Ethernet etc.). Before purchasing a router for your business,
always check with your Internet provider to see what equipment they use, and choose a
router which will interoperate with your Internet provider's equipment.
NON-ROUTABLE PROT OCOLS
Definition: A communications protocol that contains only a device address and not a
network address. NON-ROUTABLE PROTOCOLS cannot survive being routed. Non-
routable protocols presume that all computers they will ever communicate with are on the
same network (to get them working in a routed environment, you must bridge the networks).
Today’s modern networks are not very tolerant of protocols that do not understand the concept of
a multi-segment network and most of these protocols are dying or falling out of use; NetBEUI

Introduction to the ISO - OSI Model
The ISO (International Standards Organization) has created a layered model called the
OSI (Open Systems Interconnect) model to describe defined layers in a network
operating system. The purpose of the layers is to provide clearly defined functions to

23
improve internet work connectivity between "computer" manufacturing companies. Each
layer has a standard defined input and a standard defined output.
Understanding the function of each layer is instrumental in understanding data
communication within networks whether Local, Metropolitan or Wide.
ISO

• International Standards Organization (ISO) – Open Systems
Interconnection (OSI) Reference model is a framework for connecting
computers on a network

• Motivation?
– to reduce the complexity of networking software
– as a step towards international standardization of the various
protocols

• The main principles applied to the OSI layered architecture are
– each layer represents a layer of abstraction,
– each performs a set of well-defined functions,
– implementation of a layer should not affect adjacent layers, and
inter-layer communication should be minimized

WHAT "STANDARD" MEANS?

Agreements must be at many levels ...
1. How many volts pulse is a 0 and 1?
2. How to determine the end of a message?
3. How to handle lost messages?
4. How many bits for different data types? Integers/Strings, etc.
5. Are characters coded in ASCII ?
6. How machines are identified in a network? Names, numbers ?
7. How to find the way to reach a machine ? How if there are more choices ?
8. How different applications (and OSs) speaks together through the network ?
OSI Model Explained
This is a top-down explanation of the OSI Model, starting with the user's PC and what
happens to the user's file as it passes though the different OSI Model layers. The top-
down approach was selected specifically (as opposed to starting at the Physical Layer and
working up to the Application Layer) for ease of understanding of how the user's files are
transformed through the layers into a bit stream for transmission on the network.
There are 7 Layers of the OSI model:
 7. Application Layer (Top Layer)
 6. Presentation Layer

24
 5. Session Layer
 4. Transport Layer
 3. Network Layer
 2. Data Link Layer
 1. Physical Layer (Bottom Layer)


Application Layer
 Serves as a window for applications to access network services.
 Handles general network access, flow control and error recovery.
Presentation Layer
 Determines the format used to exchange data among the networked computers.
 Translates data from a format from the Application layer into an intermediate
format.
 Responsible for protocol conversion, data translation, data encryption, data
compression, character conversion, and graphics expansion.
 Redirector operates at this level.

25
Session Layer
 Allows two applications running on different computers to establish use and end a
connection called a Session.
 Performs name recognition and security.
 Provides synchronization by placing checkpoints in the data stream.
 Implements dialog control between communicating processes.
Transport Layer
 Responsible for packet creation.
 Provides an additional connection level beneath the Session layer.
 Ensures that packets are delivered error free, in sequence with no losses or
duplications.
 Unpacks, reassembles and sends receipt of messages at the receiving end.
 Provides flow control, error handling, and solves transmission problems.
Network Layer
 Responsible for addressing messages and translating logical addresses and names
into physical addresses.
 Determines the route from the source to the destination computer.
 Manages traffic such as packet switching, routing and controlling the congestion
of data.
Data Link Layer
 Sends data frames from the Network layer to the Physical layer.
 Packages raw bits into frames for the Network layer at the receiving end.
 Responsible for providing error free transmission of frames through the Physical
layer.
OSI Model Detailed Explanation
Layer 7 - Application Layer

Fig. 1 Basic PC Logical Flowchart

26
A basic PC logical flowchart is shown in Fig. 1. The Keyboard & Application are shown
as inputs to the CPU that would request access to the hard-drive. The Keyboard requests
accesses to the hard-drive through user enquiries such as "DIR" commands and the
Application through "File Openings" and "Saves". The CPU, through the Disk Operating
System, sends/receives data from the local hard-drive ("C:" in this example).
A PC setup as a network workstation has a software "Network Redirector" (actual name
depends on the network - we will use a generic term) placed between the CPU and DOS
as in Fig 2. The Network Redirector is a TSR (Terminate and Stay Resident) program
which presents the network hard-drive as another local hard-drive ("G:" in this example)
to the CPU. Any CPU requests are intercepted by the "Network Redirector". The
Network Redirector checks to see if a local drive is requested or a network drive. If a
local drive is requested, the request is passed on to DOS. If a network drive is requested,
the request is passed on to the network operating system (NOS).
Electronic mail (E-Mail), client-server databases, games played over the network, print
and file servers, remote logons and network management programs or any "network
aware" application are aware of the network redirector and can communicate directly
with other "network applications" on the network. The "Network Aware Applications"
and the "Network Redirector" make up Layer 7 - the Application layer of the OSI Model
as shown in Fig 3.


Fig. 2 Simple Network Redirection

27

Fig. 3 PC Workstation with Network Aware Software
Layer 6 - Presentation Layer
The Network Redirector directs CPU operating system native code to the network
operating system. The coding and format of the data is not recognizable by the network
operating system. The data consists of file transfers and network calls by network aware
programs.
As an example: when a dumb terminal is used as a workstation in a mainframe or
minicomputer network, the network data is translated into and from the format that the
terminal can use. The Presentation layer presents data to and from the terminal using
special control characters to control the screen display (LF-linefeed, CR-carriage return,
cursor movement, etc..). The presentation of data on the screen would depend on the type
of terminal VT100, VT52, VT420, etc.

Similarly, the Presentation layer strips the pertinent file from the workstation operating
system's file envelope. The control characters, screen formatting and workstation
operating system envelope are stripped or added to the file, depending on if the

28
workstation is receiving or transmitting data to the network. This could also include
translating ASCII files characters from a PC world to EBCDIC in an IBM Mainframe
world.
The Presentation Layer also controls security at the file level. This provides file locking
and user security. The DOS Share program is often used for file locking. When a file is in
use, it is locked from other users to prevent 2 copies of the same file to be generated. If 2
users both modified the same file and User A saved it then User B saved it - User A's
changes would be erased!
At this point, the data is contiguous and complete at this point (one large data file). See
Fig. 4.
Layer 5 - Session Layer
The Session layer manages the communications between the workstation and network.
The Session layer directs the information to the correct destination and identifies the
source to the destination. The Session layer identifies the type of information as data or
control. The Session layer manages the initial start-up of a session and the orderly closing
of a session. The Session layer also manages Logon procedures and Password
recognition. See Fig. 5.

Fig. 5 Session Layer
Layer 4 - Transport Layer
In order for the data to be sent across the network, the file must be broken up into usable
small data segments (typically 512 - 18K bytes). The Transport layer breaks up the file
into segments for transport to the network and combines incoming segments into a
contiguous file. The Transport layer does this logically not physically; it is done in
software as opposed to hardware.

29

The Transport layer provides error checking at the segment level (frame control
sequence). This checks that the datagram are in the correct order and the Transport layer
will correct out of order datagram. The Transport layer guarantees an error-free host to
host connection; it is not concerned with the path between machines.
Layer 3 - Network Layer
The Network layer is concerned about the path through the network. It is responsible for
routing, switching and controlling the flow of information between hosts. The Network
layer converts the segments into smaller datagrams that the network can handle. The
Network layer does not guarantee that the datagram will reach its destination. The
network hardware source and destination addresses are added.

Fig. 7 Network Layer
Layer 2 - Data Link Layer
The Data Link layer is a firmware layer of the network interface card. The Data Link
layer puts the datagrams into packets (frames of bits: 1s & 0s) for transmission and
assembles received packets into datagrams. The Data Link layer works at the bit level
and adds start/stop flags and bit error checking (CRC or parity) to the packet frame. Error
checking is at the bit level only, packets with errors are discarded and a request for re-
transmission is sent out. The Data Link layer is concerned about bit sequence.

30

Fig. 8 Data Link Layer
Layer 1 - Physical Layer
The Physical layer concerns itself with the transmission of bits and the network card's
hardware interface to the network. The hardware interface involves the type of cabling
(coax, twisted pair, etc..), frequency of operation (1 Mbps, 10Mbps, etc..), voltage levels,
cable terminations, topography (star, bus, ring, etc..), etc.. Examples of Physical layer
protocols are 10Base5 - Thicknet, 10Base2 - Thinnet, 10BaseT - twisted pair, ArcNet,
FDDI, etc.. See Fig. 9.

Fig. 9 Physical Layer
Layer Specific Communication
Each layer may add a Header and a Trailer to its Data which consists of the next higher
layer's Header, Trailer and Data as it moves through the layers. The Headers contain
information that addresses layer to layer communication specifically. For example: The
Transport Header (TH) contains information that only the Transport layer sees and all
other layers below the Transport layer pass the Transport Header as part of their Data.

31

PDU - Protocol Data Unit (fancy name for Layer Frame): OSI Model Functional Drawing

TCP/IP Architecture and the TCP/IP Model


The physical layer, the network Access Layer, internet layer, the transport layer
(Host to Host layer), the application layer.
The table shows the TCP/IP protocol layers and the OSI model equivalents. Also shown
are examples of the protocols that are available at each level of the TCP/IP protocol
stack. Each system that is involved in a communication transaction runs a unique
implementation of the protocol stack.
Table 1–2 TCP/IP Protocol Stack

OSI Ref.
Layer
No.
OSI Layer
Equivalent
TCP/IP
Layer
TCP/IP Protocol Examples
5,6,7 Application,
session,
presentation
Application NFS, NIS, DNS, LDAP,
telnet, ftp, rlogin, rsh, rcp,
RIP, RDISC, SNMP, and
others
4 Transport Transport TCP, UDP, SCTP

32
OSI Ref.
Layer
No.
OSI Layer
Equivalent
TCP/IP
Layer
TCP/IP Protocol Examples
3 Network Internet IPv4, IPv6, ARP, ICMP
2 Data link Data link PPP, IEEE 802.2
1 Physical Physical
network
Ethernet (IEEE 802.3), Token
Ring, RS-232, FDDI, and
others




Physical Network Layer/ Network Interface Layer
Has two layers of OSI model: data link and physical layers
The physical network layer specifies the characteristics of the hardware to be used for
the network. For example, physical network layer specifies the physical characteristics of
the communications media. The physical layer of TCP/IP describes hardware standards
such as IEEE 802.3, the specification for Ethernet network media, and RS-232, the
specification for standard pin connectors.
Data-Link Layer
The data-link layer identifies the network protocol type of the packet, in this instance
TCP/IP. The data-link layer also provides error control and ―framing.‖ Examples of data-

33
link layer protocols are Ethernet IEEE 802.2 framing and Point-to-Point Protocol (PPP)
framing.
Internet Layer
The Internet layer, also known as the network layer or IP layer, accepts and delivers
packets for the network. This layer includes the powerful Internet Protocol (IP), the
Address Resolution Protocol (ARP), and the Internet Control Message Protocol (ICMP).
IP Protocol
The IP protocol and its associated routing protocols are possibly the most significant of
the entire TCP/IP suite. IP is responsible for the following:
 IP addressing – The IP addressing conventions are part of the IP protocol.
 Host-to-host communications – IP determines the path a packet must take, based
on the receiving system's IP address.
 Packet formatting – IP assembles packets into units that are known as
datagrams.
 Fragmentation – If a packet is too large for transmission over the network media,
IP on the sending system breaks the packet into smaller fragments. IP on the
receiving system then reconstructs the fragments into the original packet.
(Host-to-Host) Transport Layer
The TCP/IP transport layer ensures that packets arrive in sequence and without error, by
swapping acknowledgments of data reception, and retransmitting lost packets. This type
of communication is known as end-to-end. Transport layer protocols at this level are
Transmission Control Protocol (TCP), User Datagram Protocol (UDP), and Stream
Control Transmission Protocol (SCTP). TCP and SCTP provide reliable, end-to-end
service. UDP provides unreliable datagram service.
TCP Protocol
TCP enables applications to communicate with each other as though they were connected
by a physical circuit. TCP sends data in a form that appears to be transmitted in a
character-by-character fashion, rather than as discrete packets. This transmission consists
of the following:
 Starting point, which opens the connection
 Entire transmission in byte order
 Ending point, which closes the connection.
TCP attaches a header onto the transmitted data. This header contains many parameters
that help processes on the sending system connect to peer processes on the receiving
system.

34
TCP confirms that a packet has reached its destination by establishing an end-to-end
connection between sending and receiving hosts. TCP is therefore considered a ―reliable,
connection-oriented‖ protocol.
UDP Protocol
UDP provides datagram delivery service. UDP does not verify connections between
receiving and sending hosts. Because UDP eliminates the processes of establishing and
verifying connections, applications that send small amounts of data use UDP.
Application Layer
The application layer defines standard Internet services and network applications that
anyone can use. These services work with the transport layer to send and receive data.
Many application layer protocols exist. The following list shows examples of application
layer protocols:
 Standard TCP/IP services such as the ftp, tftp, and telnet commands
 Name services, such as NIS and the domain name system (DNS)
 File services, such as the NFS service
 Simple Network Management Protocol (SNMP), which enables network
management
NETWORK DEVICES

Network devices include: repeaters, routers, hubs, bridges and gateways, Network
Interface card (functions and installation procedures)

Network adapter cards: expansion cards that provide the physical connection between
each computer and the network. The card installs into a slot on your computer, just like a
sound card or modem card. Some newer computers have a network adapter already built
into the system. Laptop computers often use a card that slides into a PC card slot.


An illustration of a Network adapter cards
Repeaters

35
Repeaters are physical hardware devices that have a primary function to regenerate the
electrical signal by:
 Reshaping the waveform
 Amplifying the waveform
 Retiming the signal
Purpose of a Repeater
The purpose of a repeater is to extend the LAN Segment beyond its physical limits as
defined by the Physical Layer's Standards (e.g. Ethernet is 500m for 10Base5). A LAN
Segment is a logical path such as the logical bus used by all 802.3 Ethernet types. A LAN
Segment is given an identification number called a Segment Number or Network Number
to differentiate it from other segments.


Typically, repeaters are used to connect 2 physically close buildings together that are too
far apart to just extend the segment. Can be used to connect floors of a building together
that would surpass the maximum allowable segment length. Note: for large extensions as
in the above example, 2 Repeaters are required. For shorter extensions, only 1 Repeater
may be required.
Repeater's OSI Operating Layer
Repeaters operate at the OSI Model Physical Layer.

36
Hubs

Hubs are also called Multiport Repeaters or Concentrators. They are physical hardware
devices.
Some Hubs are basic hubs with minimum intelligence - no microprocessors. Intelligent
Hubs can perform basic diagnostics and test the nodes to see if they are operating
correctly. If they are not, the Smart Hubs or Intelligent Hubs will remove the node from
the network. Some Smart Hubs can be polled and managed remotely.
Purpose of Hubs
Hubs are used to provide a Physical Star Topology. The Logical Topology is dependant
on the Medium Access Control Protocol. At the center of the star is the Hub with the
network nodes on the tips of the star.

Star Topology
The Hub is installed in a central wiring closet with all the cables extending to the network
nodes. The advantage of having a central wiring location is that it is easier to maintain
and troubleshoot large networks. All of the network cables come to the central hub, it is
especially easy to detect and fix cable problems. You can easily move a workstation in a
star topology by changing the connection to the hub at the central wiring closet.

The disadvantages to a star topology are:

37
 failure of the Hub can disable a major section of the network
 The Star Topology requires more cabling than does the ring or the bus topology
because all stations must be connected to the hub, not to the next station.
Hub's OSI Operating Layer
Hubs are multiport repeaters and as such obey the same rules as repeaters (See previous
section OSI Operating Layer). They operate at the OSI Model Physical Layer.

Bridges

Bridges are both hardware and software devices. They can be standalone devices -
separate boxes specifically designed for bridging applications, or they can be dedicated
PCs with 2 NICs and bridging software. Most servers software will automatically act as a
bridge when a second NIC card is installed.
Bridge OSI Operating Layer
Bridges operate on the OSI Model Data Link Layer. They look at the MAC addresses for
Ethernet and Token Ring to determine whether or not to forward or ignore a packet.


Purpose of a Bridge
The purposes of a Bridge are:
 Isolates networks by MAC addresses
 Manages network traffic by filtering packets
 Translate from one protocol to another
Isolates networks by MAC addresses
For example, you have 1 segment called Segment 100 with 50 users in several
departments using this network segment. The Engineering Dept. is CAD (Computer
Aided Design) oriented and the Accounting Dept. is into heavy number crunching: year
end reports, month end statements etc..

38


On this network, any traffic between Clients A, B or C and the Accounting File Server in
the Accounting Dept. will be heard across the Segment 100. Likewise any traffic between
the Engineering Dept.'s Clients G, H or I to the CAD File Server will be heard throughout
the Network Segment. The result is that the "Other" Departments access to the Generic
File Server is incredibly slow because of the unnecessary traffic occurring due to other
departments: Engineering & Accounting.
Note: The designations A, B, and C are used instead of MAC addresses for brevity. The
actual MAC addresses would be hexadecimal numbers such as 08-00-EF-45-DC-01.
The solution is to use a Bridge to isolate the Accounting Dept. and another bridge to
isolate the Engineering Department. The Bridges will only allow packets to pass through
that are not on the local segment. The bridge will first check its "routing" table to see if
the packet is on the local segment, if it is, it will ignore the packet and not forward it to
the remote segment. If Client A sent a packet to the Accounting File Server, Bridge #1
will check its routing table, to see if the Accounting File Server is on the local port. If it is
on the local port, Bridge #1 will not forward the packet to the other segments.

If Client A sent a packet to the Generic File Server, again Bridge #1 will check its routing
table to see if the Generic File Server is on the local port. If it is not, then Bridge #1 will
forward the packet to the remote port.
Note: The terms local and remote ports are arbitrarily chosen to distinguish between the
two network ports available on a bridge.

39
In this manner the network is segmented and the local department traffic is isolated from
the rest of the network. Overall network bandwidth increases because the Accounting
Dept. does not have to fight with the Engineering Dept. for access to the segment. Each
segment has reduced the amount of traffic on it and the result is faster access. Each
department still has complete access to the other segments but only when required.
Manages network traffic by filtering packets
Bridges listen to the network traffic and build an image of the network on each side of the
bridge. This image of the network indicates the location of each node and the bridge's
port that accesses it. With this information, a bridge can make a decision whether to
forward the packet across the bridge if the destination address is not on the same port or it
can decide to not forward the packet if the destination is on the same port.
This process of deciding whether or not to forward a packet is termed filtering packets.
Network traffic is managed by deciding which packets can pass through the bridge. The
bridge filters packets.
Translate from one protocol to another
The MAC layer also contains the bus arbitration method used by the network. This can be
CSMA/CD as used in Ethernet or Token Passing as used in Token Ring. Bridges are
aware of the Bus Arbitration and special translation bridges can be used to translate
between Ethernet and Token Ring.
Reasons to use a Bridge
There are four basic reasons to use a bridge:
1. Security: Stops networks from forwarding sensitive data
2. Bandwidth: Reduce traffic by segmentation
3. Reliability: If 1 segment goes down, it does not take down the complete LAN
4. Translation: Translate different Data Link protocols such as Token Ring to
Ethernet
Sample Question:

You want to connect an Ethernet network in one part of an office building to a Token-
ring network down the hall. Both networks use NWLink IPX but must eliminate the IPX
addressing and use only NetBEUI on both segments when they are joined. Which
connectivity device do you choose which will allow the two networks to communicate,
but at the same time reduce network levels. Device should you use?
1. repeater
2. bridge
3. router
4. gateway

40
B - They are testing here to see if you know what a translation bridge can do.
Some bridges can't connect different segments that use different media schemes, but a
translation bridge can. A translation bridge will also reduce network traffic because it can
analyze packets based on MAC address and if it finds them to be from the same segment
as the originating they are simply discarded instead of being passed on to a non-local
segment. The bridge can do this using address information stored in its bridging table.
Routers

Routers are hardware and software devices. They can be cards that plug into a collapsed
backbone, stand-alone devices (rack mount or desktop) or software that would run on a
file server with 2 NICs.
Purpose of Routers
The purpose of a router is to connect nodes across an internet work regardless of the
Physical Layer and Data Link Layer protocol used. Routers are hardware and topology
independent. Routers are not aware of the type of medium or frame used (Ethernet,
Token Ring, FDDI, X.25, etc...). Routers are aware of the Network Layer protocol used:
Novell's IPX, Unix's IP, XNS, Apples DDP, etc..

Router OSI Operating Layer
Routers operate on the OSI Model's Network Layer. The internet work must use the same
Network Layer protocol. Routers allow the transportation of the Network Layer PDU
through the internet work even though the Physical and Data Link Frame size and
addressing scheme may change.

41


Routers use up to 5 metrics (conditions) to determine the best route:
 Bandwidth
 Hop Count (Delay) - maximum of 255
 Maximum Packet size
 Reliability
 Traffic (Load)
These routing metrics are much more realistic indicators of the best routes compared to
simple hop counts.
Brouters (Bridge/Routers)

Brouters are protocol dependant devices. When a brouter receives a frame to be
forwarded to the remote segment, it checks to see if it recognizes the Network layer
protocol. If the Brouter does, it acts like a router and finds the shortest path. If it doesn't
recognize the Network layer protocol, it acts like a bridge and forwards the frame to the
next segment.


The key advantage to Brouters is the ability to act as both a bridge and a router. It can
replace separate bridges and routers, saving money. This is, of course, provided that the
Brouter can accomplish both functions satisfactorily.

42
Gateways

One definition of a Gateway is the Hardware/Software device that is used to interconnect
LANs & WANs with mainframe computers such as DECnet and IBM's SNA.
Often the router that is used to connect a LAN to the Internet will be called a gateway. It
will have added capability to direct and filter higher layer protocols (layer 4 and up) to
specific devices such as web servers, ftp servers and e-mail servers.
Gateway's OSI Operating Layer
A Gateway operates at the Transport Layer and above. Typically translating each source
layer protocol into the appropriate destination layer protocol. A mainframe gateway may
translate all OSI Model layers. For example, IBM's SNA (System Network Architecture)
does not readily conform to the OSI Model and requires a gateway to translate between
the two architectures.

OSI Model Layers, Protocols and Network Devices


Layer Function Protocols Network
Components
Application
User Interface
 used for applications specifically
written to run over the network
 allows access to network
services that support
applications;
 directly represents the services
that directly support user
applications
 handles network access, flow
control and error recovery
 Example apps are file transfer-
mail, NetBIOS-
based applications
DNS; FTP;
TFTP; BOOTP;
SNMP;RLOGIN
; SMTP; MIME;
NFS; FINGER;
TELNET; NCP;
APPC; AFP;
SMB
Gateway
Presentation
Translation
 Translates from application to
network format and vice-versa
 all different formats from all
sources are made into a common
uniform format that the rest of
the OSI model can understand
 responsible for protocol
conversion, character
Gateway
Redirector

43
conversion, data encryption /
decryption, expanding graphics
commands, data compression
 sets standards for different
systems to provide seamless
communication from multiple
protocol stacks
 not always implemented in a
network protocol
Session
"syncs and
sessions"
 establishes, maintains and ends
sessions across the network
 responsible for name recognition
(identification) so only the
designated parties can participate
in the session
 provides synchronization
services by planning check
points in the data stream => if
session fails, only data after the
most recent checkpoint need be
transmitted
 manages who can transmit data
at a certain time and for how
long
 Examples are interactive login
and file transfer connections, the
session would connect and re-
connect if there was an
interruption; recognize names in
sessions and register names in
history
NetBIOS
Names Pipes
Mail Slots
RPC
Gateway
Transport
packets; flow
control and
error-handling
 additional connection below the
session layer
 manages the flow control of data
between parties across the
network
 divides streams of data into
chunks or packets; the transport
layer of the receiving computer
reassembles the message from
packets
 "train" is a good analogy => the
data is divided into identical
units
 provides error-checking to
guarantee error-free data
delivery, with on losses or
TCP, ARP,
RARP;
SPX
NWLink
NetBIOS /
NetBEUI
ATP
Gateway
Advanced
Cable Tester
Brouter

44
duplications
 provides acknowledgment of
successful transmissions;
requests retransmission if some
packets don’t arrive error-free
 provides flow control and error-
handling
Network
addressing;
routing
 translates logical network
address and names to their
physical address (e.g. computer
name ==> MAC address)
 responsible for
o addressing
o determining routes for
sending
o managing network
problems such as packet
switching, data
congestion and routing
 if router can’t send data frame as
large as the source computer
sends, the network layer
compensates by breaking the
data into smaller units. At the
receiving end, the network layer
reassembles the data
 think of this layer stamping the
addresses on each train car
IP; ARP; RARP,
ICMP; RIP;
OSFP;
IGMP;
IPX
NWLink
NetBEUI
OSI
DDP
DECnet
Brouter
Router
Frame Relay
Device
ATM Switch
Advanced
Cable Tester
Data Link
data frames to
bits
 Turns packets into raw bits
100101 and at the receiving end
turns bits into packets.
 handles data frames between the
Network and Physical layers
 the receiving end packages raw
data from the Physical layer into
data frames for delivery to the
Network layer
 responsible for error-free
transfer of frames to other
computer via the Physical Layer
-this layer defines the methods used
Logical Link
Control
-error correction
and flow control
-manages link
control and
defines SAPs
802.1 OSI Model
802.2 Logical
Link Control
Bridge
Switch
ISDN Router
Intelligent
Hub
NIC
Advanced
Cable Tester

45
to transmit and receive data on the
network. It consists of the wiring,
the devices use to connect the NIC
to the wiring, the signaling involved
to transmit / receive data and the
ability to detect signaling errors on
the network media
Media Access
Control
communicates
with the adapter
card
-is responsible
for delivering
error-free data
between two
computers:
802.3 CSMA/CD
(Ethernet)
802.4 Token Bus
(ARCnet)
802.5 Token
Ring
802.12 Demand
Priority
Physical
Hardware; raw
bit stream
 transmits raw bit stream over
physical cable
 defines cables, cards, and
physical aspects
 defines NIC attachments to
hardware, how cable is attached
to NIC
 defines techniques to transfer bit
stream to cable
IEEE 802
IEEE 802.2
ISO 2110
ISDN
Repeater
Multiplexer
Hubs
 Passive
 Active
TDR
Oscilloscope
Amplifier





CHAPTER 7

46
DATA LINK LAYER
Chapter Objectives
In this chapter you will learn:

 Define the roles of data link layer and data link control.
 Define OSI model.
 Define the term digital error
 Explain the different types of errors
 Explain the causes of network errors
 Describe the different techniques of error detection
 Explain the advantages and disadvantages each error detection method


Role of the data link layer and types of DLL
 Divides the Data-link layer in to the Logical Link Control and Media
Access Control sub layers.
 Logical Link Control
o manages error and flow control and
o Defines logical interface points called Service Access Points
(SAP's). These SAP's are used to transfer information to upper
layers
 Media Access Control
o communicates directly with the network adapter card and
o Is responsible for delivering error-free data between two
computers.
LLC - Logical Link Control Layer

The Logical Link Control Layer resides in the upper portion of the Data Link Layer. The
LLC layer performs these functions:
a. Managing the data-link communication
b. Link Addressing
c. Defining Service Access Points (SAPs)
d. Sequencing
The LLC provides a way for the upper layers to deal with any type of MAC layer (ex.
Ethernet - IEEE 802.3 CSMA/CD or Token Ring IEEE 802.5 Token Passing).

47


The Data field of the MAC layer Frame transmits the LLC Protocol Data Unit.

LLC PDU Format

Data link layer: Flow and Error Control

• Flow control specifies how much data the Sender can transmit before receiving
permission to continue from the Receiver
• Error control allows the Receiver to tell the Sender about frames damaged or lost
during transmission, and coordinates the re-transmission of those frames by the Sender
• Since flow control provides the Receiver’s acknowledgement (ACK) of correctly-
received frames, it is closely linked to error control
• Basic idea of flow control: even if frames are received error-free, the Receiver will be
forced to drop some of them if the Sender transmits faster than the Receiver can process
them signal the Sender to slow down to a rate acceptable to the Receiver

• This signal can be explicit or implicit (e.g. delay sending ACK to Sender)
• Basic idea of error control: ACK every correctly-received frame and
Negatively acknowledge (NAK) each incorrectly-received frame
• Sender keeps copies of un-ACKed Frames to re-transmit if required
• Want: packets (inside frames) passed to Receiver’s Network layer in order



ERRORS AND ERROR DETECTION

48
Types of Errors

i. single-bit error
ii. burst error

Whenever bits flow from one point to another, they are subject to unpredictable changes
because of interference. This interference can change the shape of the signal.

Single-bit error: In a single-bit error, a 0 is changed to a 1 or a 1 to a 0. The term single-
bit error means that only 1 bit of a given data unit (such as a byte, character, or packet) is
changed from 1 to 0 or from 0 to 1.
Burst error: The term burst error means that 2 or more bits in the data unit have
changed from 1 to 0 or from 0 to 1.

Redundancy

The central concept in detecting or correcting errors is redundancy. To be able to detect
or correct errors, we need to send some extra bits with our data. These redundant bits are
added by the sender and removed by the receiver. Their presence allows the receiver to
detect or correct corrupted bits. The concept of including extra information in the
transmission for error detection is a good one. But instead of repeating the entire data
stream, a shorter group of bits may be appended to the end of each unit. This technique is
called redundancy because the extra bits are redundant to the information: they are
discarded as soon as the accuracy of the transmission has been determined.

Two types of redundancy checks are common in data communications: parity check,
cyclic redundancy check (CRC. and checksum.
Parity Bits
In asynchronous communications, a simple error checking method is used: Parity
Checking. There are 3 types of Parity Bits: Even, Odd and None. None means that there
is no Parity Checking and the Parity Checking is disabled!
Even Parity Generation
Even Parity counts the number of 1s in the data to see if the total is an even number. If
the number of 1s is an even number then the Parity bit is set to 0. If the number of 1s is
an odd number, then the Parity bit is set to 1 to make the total number of 1s an even
number. The Even Parity Bit is used to make the total number of 1s equal to an even
number.
Data Even Parity Bit
0100 1010 1 3 x 1s in Data: 3 is an odd number, Parity Bit = 1
0111 1110 0 6x 1s in Data: 6 is an even number, Parity Bit = 0
1010 1010 ? What should the parity bit be?

49
Even Parity Checking
When a data with even parity is received. The number of 1s in both the data and the
parity bit are counted. If the number of 1s is an even number than the data is good data, if
it is an odd number than the data is corrupted.
Data Even Parity Bit
0100 1010 1 4 x 1s in data and parity bit = Good data
0111 1110 1 7 x 1s in data and parity bit = Bad data
1010 1010 0 Is this good or bad data?

Odd Parity Generation
Odd Parity is the opposite of Even Parity. Odd Parity counts the number of 1s in the data
to see if the total is an odd number. If the number of 1s is an odd number then the Parity
bit is set to 0. If the number of 1s is an even number, then the Parity bit is set to 1 to make
the total number of 1s an odd number. The Odd Parity Bit is used to make the total
number of 1s equal to an odd number.
Data Odd Parity Bit
0100 1010 1 3 x 1s in Data: 3 is an odd number, Parity Bit = 0
0111 1110 0 6x 1s in Data: 6 is an even number, Parity Bit = 1
1010 1011 ? What should the parity bit be?

Odd Parity Checking
When a data with odd parity is received. The number of 1s in both the data and the parity
bit are counted. If the number of 1s is an odd number than the data is good data, if it is an
even number than the data is corrupted.
Data Odd Parity Bit
0100 1010 0 3 x 1s in data and parity bit = Good data
0111 1110 0 6 x 1s in data and parity bit = Bad data
1010 1010 0 Is this good or bad data?
Problems with Parity Checking
There is a problem with parity checking. It only works reliably if there is only 1 bit error
in the transmitted character stream. If there are 2 bit errors, the parity checking may not
detect that there is an error. For example:
Data Odd Parity Bit
Transmitted 0100 1010 0 3 x 1s in data and parity bit = Good data
Received 0110 1110 0 5 x 1s in data and parity bit = Good data?

50
Parity checking would pass the received data as good data even though 2 bits are
corrupted. Practice the following examples

51
Performance

Simple parity check can detect all single-bit errors. It can also detect burst errors as long
as the total number of bits changed is odd. This method cannot detect errors where the
total number of hits changed is even. If any two bits change
in transmission, the changes cancel each other and the data unit will pass a parity check
even though the data unit is damaged. The same holds true fur any even lumber of errors.
CRC/ Frame Check Sequence
Cyclic Redundancy Check

The cyclic redundancy check, or CRC, is a technique for detecting errors in digital data,
but not for making corrections when errors are detected. It is used primarily in data
transmission. In the CRC method, a certain number of check bits, often called a
checksum, are appended to the message being transmitted. The receiver can determine
whether or not the check bits agree with the data, to ascertain with a certain degree of
probability whether or not an error occurred in transmission.

If an error occurred, the receiver sends a ―negative acknowledgement‖ (NAK) back to
the sender, requesting that the message be retransmitted.
The technique is also sometimes applied to data storage devices, such as a
disk drive. In this situation each block on the disk would have check bits, and the
hardware might automatically initiate a reread of the block when an error is
detected, or it might report the error to software. The material that follows speaks in
terms of a ―sender‖ and a ―receiver‖ of a ―message,‖ but it should be understood that it
applies to storage writing and reading as well.

The CRC / Frame Check Sequence (FCS) contains an error checking number that the
Destination can use to verify that the packet is okay and error-free. CRC is an
abbreviation for Cyclic Redundancy Checking. The Frame Check Sequence typically
incorporates a 32 Bit CRC check. Checksums work similarly but use a different
algorithm.
As each packet is sent, the Source calculates a check number from the data using a
predetermined algorithm (formula). The result of this calculation is appended to the
packet in the Frame Check Sequence (FCS) field. At the Destination, the same
calculation is performed and the result is compared to the transmitted Frame Check
Sequence. If the result generated at the Destination is identical to the FCS, then it is
assumed that the packet is error free at the bit level.
The CRC most powerful of the redundancy checking techniques. Unlike the parity check
which is based on addition. CRC is based on binary division. In CRC, instead of adding
bits to achieve a desired parity, a sequence of redundant bits, called the CRC or the CRC
remainder, is appended to the end of a data unit so that the resulting data unit becomes
exactly divisible by a second, predetermined binary number. At its destination, the
incoming data unit is divided by the same number. If at this step there is no remainder the
data unit is assumed to be intact and is therefore accepted. A remainder indicates that the
data unit has been damaged in transit and therefore must be rejected. The redundancy bits

52
used by CRC are derived by dividing the data unit by a predetermined divisor; the
remainder is the CRC.

To be valid, a CRC must have two qualities: It must have exactly one less bit than the
divisor, and appending it to the end of the data string must make the resulting bit
sequence exactly divisible by the divisor. Both the theory and the application of CRC
error detection are straightforward. The only complexity is in deriving the CRC.


Translating from polynomial to digital form

Polynomial of degree 7






To clarify this process, we will start with an overview and add complexity as we go.
Figure 12 provides an outline of the basic steps.



Example 1: using 1’s and 0’s

53
Figure 13 shows how we generate CRC.







Example 2: using 1’s and 0’s

A CRC checker functions exactly as the generator does. After receiving the data
appended with the CRC, it does the same modulo-2 division. If the remainder is all 0’s,
the CRC is dropped and the data are accepted: otherwise, the received stream of bits is
discarded and data are resent. Figure 14 shows the same process of division in the
receiver. We assume that there is no error the remainder is therefore all 0’s, and the data
are accepted.

54
Example 3: using polynomials




The divisor in the CRC generator is most often represented not as a siring of 1’s and 0’s,
but as an algebraic polynomial (see Fig. 15). The polynomial format is useful for two
reasons: It is short, and it can be used to prove the concept mathematically. The
relationship of a polynomial to its corresponding binary representation is shown in Figure
16.

Theory

The CRC is based on polynomial arithmetic, in particular, on computing the
remainder of dividing one polynomial in GF(2) (Galois field with two elements)
by another. It is a little like treating the message as a very large binary number, and
computing the remainder on dividing it by a fairly large prime such as
Intuitively, one would expect this to give a reliable checksum.

A polynomial in GF(2) is a polynomial in a single variable x whose coefficients
are 0 or 1. Addition and subtraction are done modulo 2 that is, they are
both the same as the exclusive or operator. For example, the sum of the polynomials

55








Assignment




Performance of CRC

CRC is a very effective error detection method. If the divisor is chosen according to the
previously mentioned rules,

1. CRC can detect all burst errors that affect an odd number of bits.
2. CRC can detect all burst errors of length less than or equal to the degree of the
polynomial
3. CRC can detect, with a very high probability, burst errors of length greater than
the degree of the polynomial.

Error Detection versus Correction

The correction of errors is more difficult than the detection. In error detection, we are
looking only to see if any error has occurred. The answer is a simple yes or no. We are
not even interested in the number of errors. A single-bit error is the same for us as a burst
error. In error correction, we need to know the exact number of bits that are corrupted and
more importantly, their location in the message. The number of the errors and the size of
the message are important factors. If we need to correct one single error in an 8-bit data

56
unit, we need to consider eight possible error locations; if we need to correct two errors in
a data unit of the same size, we need to consider 28 possibilities. You can imagine the
receiver's difficulty in finding 10 errors in a data unit of 1000 bits.


CHAPTER 9
THE NETWORK LAYER

Chapter Objectives
In this chapter you will learn:

 Define the terms Internet Protocol and IP addressing
 Explain the Multicasting (Unicast, Multicast and Broadcast)
 Determine the subnet prefix of an IPv4 address when expressed in prefix length or
subnet mask notation.
 Subnet an IPv4 address prefix within an octet and across octet boundaries
 Define variable length subnetting and how you can use it to create subnetted
address prefixes that match the number of hosts on a particular subnet.
Introduction
Primary roles of Network layer
i. Delivery messages/packets
ii. Forwarding messages/packets
iii. Routing messages/packets
Internet Protocol

The Network Layer protocol for TCP/IP is the Internet Protocol (IP). It uses IP addresses
and the subnet mask to determine whether the datagram is on the local or a remote
network. If it is on the remote network, the datagram is forwarded to the default gateway
which is a router that links to another network.
IP keeps track of the number of transverses through each router that the datagram goes
through to reach its destination. Each transverse is called a hop. If the hop count exceeds
255 hops, the datagram is removed and the destination considered unreachable. IP's name
for the hop count is called Time to Live (TTL).
IP Addresses
Definition:

57
IP addresses consist of a 32 bit number and is represented by the dot-decimal format. For
example: 142.110.237.1 is an IP address. There are 4 decimal digits separated by three
dots. Each digit is allowed the range of 0 to 255 which corresponds to 8 bits (one byte) of
information.
A portion of an IP address represents the network address and the remaining portion the
host address. For example: 142.110.237.1 is the IP address of a firewall. The network
that the firewall resided on is 142.110.237.0 (Note: IP addresses that end in a 0 represent
network addresses). The host address of the firewall is 0.0.0.1 (Note: the network portion
of the IP address is represented by 0s). Each host on the network and Internet must have a
unique IP address. There are ways around having each host a unique IP address and they
are discussed under firewalls.
The Network Information Center (NIC) assigns network addresses to the Internet. You
must apply to receive an IP network address. Depending on the class (more on this later)
of the IP address, you can then assign as many hosts IP addresses as allowed.
An alternative is to "rent" IP addresses from your local Internet Service Provider (ISP).
They usually own the rights to a block of IP addresses and will rent them out for a fee.
A Physical address is a 48-bit flat address burned into the ROM of the NIC card which
is a Layer1 device of the OSI model. This is divided into 24-bit vendor code and 24-bit
serial address. This is unique for each system and cannot be changed. Physical Addres: It
is a physical address that we can't change It is present in NIC Card Given by INTERNIC
Organization.
A Logical address is a 32- bit address assigned to each system in a network. This works
in Layer-3 of OSI Model. This would be generally the IP address. Logical Address: It can
be changed as you like used for assigning a ip address to clients.
IPv6 Addressing
The most obvious difference between IPv6 and IPv4 is address size. An IPv6 address is
128 bits long, which is four times larger than an IPv4 address. A 32-bit address space
allows for 232 or 4,294,967,296 possible addresses. A 128-bit address space allows for
2128 or 340,282,366,920,938,463,463,374,607,431,768,211,456 (or 3.4x10
38
) possible
addresses.
IPv6 Address Syntax
IPv4 addresses are represented in dotted decimal notation. For IPv6, the 128-bit address
is divided along 16-bit boundaries, each 16-bit block is converted to a 4-digit
hexadecimal number (the Base16 numbering system), and adjacent 16-bit blocks are
separated by colons. The resulting representation is known as colon-hexadecimal.
The following is an IPv6 address in binary form:
0011111111111110001010010000000011010000000001010000000000000000

58
0000001010101010000000001111111111111110001010001001110001011010
The 128-bit address is divided along 16-bit boundaries:
0011111111111110 0010100100000000 1101000000000101 0000000000000000 00
00001010101010 0000000011111111 1111111000101000 1001110001011010
Each 16-bit block is converted to hexadecimal, and adjacent blocks are separated with
colons. The result is:
3FFE:2900:D005:0000:02AA:00FF:FE28:9C5A
IPv6 representation can be further simplified by removing the leading zeros within each
16-bit block. However, each block must have at least a single digit. With leading zero
suppression, the address becomes:
3FFE:2900:D005:0:2AA:FF:FE28:9C5A
Types of IPv4 Addresses
Internet standards define the following types of IPv4 addresses:
 Unicast: Assigned to a single network interface located on a specific subnet; used
for one-to-one communication.
 Multicast: Assigned to one or more network interfaces located on various subnets;
used for one-to-many communication.
 Broadcast: Assigned to all network interfaces located on a subnet; used for one-
to-everyone on a subnet communication.
Types of IPv6 Addresses
IPv6 has three types of addresses:
 Unicast
A Unicast address identifies a single interface within the scope of the type of
Unicast address. With the appropriate Unicast routing topology, packets
addressed to a Unicast address are delivered to a single interface. A Unicast
address is used for communication from one source to a single destination.
 Multicast
A multicast address identifies multiple interfaces. With the appropriate multicast
routing topology, packets addressed to a multicast address are delivered to all
interfaces that are identified by the address. A multicast address is used for
communication from one source to many destinations, with delivery to multiple
interfaces.
 Anycast

59
An anycast address identifies multiple interfaces. With the appropriate routing
topology, packets addressed to an anycast address are delivered to a single
interface, the nearest interface that the address identifies. The ―nearest‖ interface
is defined as being closest in terms of routing distance. An anycast address is
used for communication from one source to one of multiple destinations, with
delivery to a single interface.
IP Address Classifications
There is a formal structure to the assignment of IP addresses. IP addresses are assigned
by the Network Information Center (NIC) who is a central authority with the
responsibility of assigning network addresses.
There are several classifications of IP addresses. They include network addresses and
special purpose addresses.
Class A addresses
IP address range 1.0.0.0 to 127.0.0.0
Number of networks available: 125 (see special addresses below)
Number of hosts per network: 16,777,214
Net Mask: 255.0.0.0 (first 8 bits are ones)

Special Addresses

 10.0.0.0 is used for networks not connected to the Internet
 127.0.0.0 is the loop back address for testing

Class A addresses always have bit 0 set to 0, bits 1-7 are used as the network ID. Bits 8-
31 are used as the host ID.
Class A networks are used by very large companies such as IBM, US Dept of Defense
and AT&T. Appendix E: IP Protocol Address Space lists the IP addresses and the
organizations that use them.
Class B addresses
IP address range 128.0.0.0 to 191.0.0.0
Number of networks available: 16,382 (see special addresses below)
Number of hosts per network: 65,534
Net Mask: 255.255.0.0 (first 16 bits are ones)

60

Special Addresses:

 172.16.0.0 to 172.31.0.0 are used for networks not connected to
the Internet

Class B addresses always have bit 0 and 1 set to 10, bits 2-15 are used as the network ID.
Bits 16-31 are used as the host ID. Class B networks are assigned to large companies and
universities.
Class C addresses
IP address range 192.0.0.0 to 223.0.0.0
Number of networks available: 2,097,150 (see special addresses below)
Number of hosts per network: 254
Net Mask: 255.255.255.0 (first 24 bits are ones)

Special Addresses:

 192.168.1.0 to 192.168.255.0 are used for networks not connected
to the Internet

Class C addresses always have bits 0-2 set to 110, bits 3-24 are used as the network ID.
Bits 25-31 are used as the host ID. Class C network addresses are assigned to small
companies and local Internet providers.
Class D Addresses
IP address range 224.0.0.0 to 239.0.0.0
Use: Multicasting addresses

61
Class D addresses
Class D addresses always have bits 0-3 set to 1110, bits 4-31 are used as the Multicast
address.
Class D network addresses are used by multicasting. Multicasting is a method of
reducing network traffic. Rather than send a separate datagram to each host if multiple
host require the same information. A special multicast address can be used where one
datagram is read by many hosts. Appendix F: IP Multicast Addresses lists the assigned IP
multicast address space.
Class E Addresses
IP address range 240.0.0.0 to 255.0.0.0
Use: Reserved by the Internet for its own use.
If you try to ping a Class E address, you should get the error message that says that it is
an invalid IP address.
Reserved IP Addresses
The following IP addresses are reserved:
127.0.0.0 Network addresses used for local host mode (testing IP stack)
255.255.255.255 An IP address consisting of all 1s in binary (255). Broadcast address
x.x.x.0 An IP address with the host portion consisting of 0s. Used to indicate the network address. Newer routers have the option of allowing these addresses.

224.0.0.0 - 255.0.0.0 Class D addresses.
Table 3-2 summarizes the Internet address classes A, B, and C that can be used for IPv4
unicast addresses.
Class
Value for
w
Address Prefix
Portion
Host ID
Portion
Address
Prefixes
Host IDs per Address
Prefix
A 1-126 w x.y.z 126 16,277,214
B 128-191 w.x y.z 16,384 65,534
C 192-223 w.x.y z 2,097,152 254
Table 3-2 Internet Address Class Summary
Special IPv4 Addresses
The following are special IPv4 addresses:
 0.0.0.0

62
Known as the unspecified IPv4 address, it indicates the absence of an address.
The unspecified address is used only as a source address when the IPv4 node is
not configured with an IPv4 address configuration and is attempting to obtain an
address through a configuration protocol such as DHCP.
 127.0.0.1
Known as the IPv4 loopback address, it is assigned to an internal loopback
interface. This interface enables a node to send packets to itself.
The following are special IPv6 addresses:
 Unspecified address
The unspecified address (0:0:0:0:0:0:0:0 or ::) indicates the absence of an address
and is equivalent to the IPv4 unspecified address of 0.0.0.0. The unspecified
address is typically used as a source address for packets attempting to verify the
uniqueness of a tentative address. The unspecified address is never assigned to an
interface or used as a destination address.
 Loopback address
The loopback address (0:0:0:0:0:0:0:1 or ::1) identifies a loopback interface. This
address enables a node to send packets to itself and is equivalent to the IPv4
loopback address of 127.0.0.1. Packets addressed to the loopback address are
never sent on a link or forwarded by an IPv6 router.
Network Masking
The subnet mask is used to determine which portion of the IP address is the network
address and which is the host address. This means that the portions of network to host in
an IP address can change. The most common subnet mask is 255.255.255.0. The simple
explanation is that wherever there is a 255, this indicates that it is the network portion.
Wherever there is a 0, this indicates the host portion. Later on, subnet masking will be
explained more thoroughly, for now this explanation will suffice.
If we examine our IP address of 142.110.237.1, and use a subnet mask of 255.255.255.0.
It can be seen that the network portion of the IP address is 142.110.237 and the host
portion is 1. The network address is typically written 142.110.237.0 and the host is
sometimes written 0.0.0.1.
Now if host 142.110.237.1 wanted to send a datagram to 142.110.237.21. It would look
at the network portion of the IP address of the destination and determine that it is on the
local network. It would then send the datagram out.
If host 142.110.237.1 wanted to send a datagram to 142.110.150.108. It would look at the
network portion of the IP address of the destination and determine that it is not on the
same network. It is on 142.110.150.0 network and it would send it to the default gateway.
The default gateway is a router that knows how to reach the other networks.

63
Class Masking
Class A, B and C networks use masks and not subnet masks. Masks are similar to subnet
masks except that usually they are used in routers and not workstations.
A Class A network has a mask of 255.0.0.0 which allows approximately 16.7 million host
addresses. Also, a Class B network has a mask of 255.255.0.0 which allows
approximately 65 thousand host addresses. Both classes of networks have too many hosts
for one network to handle. Imagine 65,000 users trying to access a network service at the
same time. The network would be swamped with requests and slow down to a crawl.
The solution is to divide the network up into smaller workable networks called subnets.
This is most commonly done by fooling the host machine into believing it is on a Class C
network (only 254 hosts) by using a Class C mask: 255.255.255.0. This mask is called
the subnet mask.
Thus for a Class A network using a subnet mask of 255.255.255.0, you can have roughly
65 thousand subnets of 254 hosts. On a Class B network using a subnet mask of
255.255.255.0, you can have roughly 254 subnets of 254 hosts.
Subnetting a network

Definition: Subnetting is a set of techniques that you can be used to efficiently divide the
address space of a Unicast address prefix for allocation among the subnets of an
organization network.
Subnet masks can divide networks into smaller networks than the 254 hosts discussed
previously. In order to understand this process, a discussion on binary to decimal number
conversion is required.
The typical subnet mask 255.255.255.0 represents 4 bytes of data. Each number
represents 1 byte and is displayed as a decimal number. One byte of information can
represent a range of 0 - 255. One byte consists of 8 bits where 0000 0000 represents 0 in
decimal and 1111 1111 represents 255 in decimal.
Note: The convention for displaying bits is to group in nibbles (4 bits) to make it easier to
read.
Each bit position has a weighting, where the weighting is equal to 2 to the power of the
position starting at position 0 on the right. The easiest way to determine the decimal
weighting is to start on the right with the number 1 (which is 2^0) and double it at each
bit position. The weighting for each position is follows:

64
Each position has its weighting multiplied by the binary bit value (0 or 1). For example, if
bit position 23 had its bit set to 0, its decimal value would be 0 x 8 = 0. If bit position 25
had its bit set to 1, its decimal value would be 1 x 32 = 32.
To determine the decimal value of a binary number, add up all the decimal weighting
values where ever there is a 1 in the binary number. For the following binary number
1111 1111, the decimal value would equal 255:

For the binary number 0000 0000 the decimal value would equal 0:

For the binary number 1010 1001 the decimal value would equal 169:

The significance of the decimal weighting to network routing becomes more evident
when the method of rolling over the binary count is examined. For example, the decimal
number 63 compared to 64 in binary produces an interesting observation:
Decimal 63 = 0011 1111
Decimal 64 = 0100 0000
The decimal number 63 is represented by all 1s in the first 6 bit locations. The decimal
number 64 is represented by only bit 6 being a logical 1. If the count was further
increased, similar relationships would occur at
Decimal 127 = 0111 1111
Decimal 128 = 1000 0000

65
and
Decimal 191 = 1011 1111
Decimal 192 = 1100 0000
and
Decimal 255 = 1111 1111
Decimal 0 = 0000 0000
Notice that bit 7 and 6 are the only bits that are changing from the initial example of 63
and 64. What this means is that the network can be subdivided into 4 logical networks of
64 hosts each. In actual fact the number is 62 hosts due to address 0 not being allowed
(network address) and address 63 not being allowed (broadcast address).
In the introduction to subnetting, the portion of the IP address that corresponded to the
network portion was easily identified as being the portion of the subnet mask that
corresponded to the decimal number 255. This is really only for convenience for the dot
decimal format of the IP address. In actual fact, the IP address is a 32 bit address and
doesn't have byte "boundaries" as implied by the dot decimal notation. For example:
192.168.1.0 = 1100 0000 1010 1000 0000 0001 0000 0000
This means that the portion of the subnet mask that corresponds to the network address
can be further broken down on the host bit positions.
Example 1
A Class C network address of 192.168.1.0 has 254 hosts available to it. If your network
consisted of 4 different physical locations each with a maximum of 50 hosts, then
subnetting the network would be required. The locations could be different buildings or
cities.
Bit 7 and bit 6 of the host portion can be used to describe the network portion of the
subnet. The subnet masking would be:
1111 1111 1111 1111 1111 1111 1100 0000 = 255.255.255.192
The 4 subnets for Class C address 192.168.1.0 would be 192.168.1.0, 192.168.1.64,
192.168.1.128 and 192.168.1.192 with the following range of IP addresses:
Subnet Host Range Broadcast address
192.168.1.0 192.168.1.1 to 192.168.1.62 192.168.1.63
192.168.1.64 192.168.1.65 to 192.168.1.126 192.168.1.127
192.168.1.128 192.168.1.129 to 192.168.1.190 192.168.1.191
192.168.1.192 192.168.1.193 to 192.168.1.254 192.168.1.255
In this manner, a router with 4 interfaces could be configured with subnet masks of
255.255.255.192 to allow subdividing the Class C network into 4 smaller networks.

66
Theoretically, all of the host bits up to bit 1 and 0 can be used to make up to 64 subnets of
2 hosts each. In this case, 128 IP addresses would be lost to the network IP address and
the broadcast IP address. The following table lists the number of hosts and networks that
can implemented using subnet masking for a Class C network:
Subnet mask Number of subnets Number of hosts per subnet
255.255.255.128 2 126
255.255.255.192 4 62
255.255.255.224 8 30
255.255.255.240 16 14
255.255.255.248 32 6
255.255.255.252 64 2
The above example is based on subnetting a Class C network. Subnetting can get
extremely complicated if you are subnetting assigned IP addresses that are in the middle
of a Class C network such as when rented from an ISP. Fortunately, there are many
Subnet Mask Calculators available for download off the Internet that are designed to
determine the correct subnet mask for your network.
Example 2: Subnetting for IPv4
Before you begin IPv4 subnetting, you must determine your organization’s current
requirements and plan for future requirements. Follow these guidelines:
 Determine how many subnets your network requires. Subnets include physical or
logical subnets to which hosts connect and possibly private wide area network
(WAN) links between sites.
 Determine how many host IDs each subnet requires. Each host and router
interface running IPv4 requires at least one IPv4 address.
Based on those requirements, you will define a set of subnetted address prefixes with
a range of valid IPv4 addresses for each subnetted address prefix. Your subnets do
not all need to have the same number of hosts; most IPv4 networks include subnets of
various sizes.
Although the concept of subnetting by using host ID bits is straightforward, the actual
mechanics of subnetting are a bit more complicated. Subnetting requires a three-step
procedure:
1. Determine how many host bits to use for the subnetting.
2. Enumerate the new subnetted address prefixes.
3. Enumerate the range of IPv4 addresses for each new subnetted address prefix.
Determining the Subnet Prefix of an IPv4 Address Configuration
Before you begin the mechanics of IPv4 subnetting, you should be able to determine the
subnet prefix from an arbitrary IPv4 address configuration, which typically consists of an
IPv4 address and a prefix length or an IPv4 address and a subnet mask. The following
sections show you how to determine the subnet prefix for IPv4 address configurations

67
when the prefix length is expressed in prefix length and dotted decimal (subnet mask)
notation.
Prefix Length Notation
To determine the subnet prefix from an arbitrary IPv4 address using prefix length
notation (w.x.y.z/n), take the values of the high-order n bits of the address and combine
them with 32-n zero bits. Then convert the resulting 32-bit number to dotted decimal
notation.
For example, for the IPv4 address configuration of 192.168.207.47/22, the high-order 22
bits are 11000000 10101000 110011. To obtain the subnet prefix, combine this result
with the low-order 10 bits of 00 00000000. The result is 11000000 10101000 11001100
00000000, or 192.168.204.0/22.
To determine the subnet prefix of an IPv4 address configuration in prefix length notation
without having to work entirely with binary numbers, use the following method:
1. Express the number n (the prefix length) as the sum of 4 numbers by successively
subtracting 8 from n. For example, 20 is 8+8+4+0.
2. Create a table with four columns and three rows. In the first row, place the
decimal octets of the IPv4 address. In the second row, place the four digits of the
sum you determined in step 1.
3. For the columns that have 8 in the second row, copy the octet from the first row to
the third row. For the columns that have 0 in the second row, place a 0 in the third
row.
4. For the columns that have a number between 8 and 0 in the second row, convert
the decimal number in the first row to binary, take the high-order bits for the
number of bits indicated in the second row, fill the rest of the bits with zero, and
then convert to a decimal number.
For example, for the IPv4 address configuration of 192.168.207.47/22, 22 is 8+8+6+0.
From this, construct the following table:

192 168 207 47
8 8 6 0

For the first and second octets, copy the octets from the first row. For the last octet, place
a 0 in the third row. The table becomes:

192 168 207 47
8 8 6 0
192 168 0

68
For the third octet, convert the number 207 to binary for the first 6 binary digits using the
decimal to binary conversion method,
The decimal number 207 is 128+64+8+4+2+1, which is 11001111. Taking the first 6
digits 110011 and filling in the octet with 00 produces 11001100, or 204 in decimal. The
table becomes:

192 168 207 47
8 8 6 0
192 168 204 0
Therefore, the subnet prefix for the IPv4 address configuration 192.168.207.47/22 is
192.168.204.0/22.
Subnet Mask Notation
To determine the subnet prefix of an IPv4 address configuration in subnet mask notation
without having to work entirely with binary numbers, use the following method:
1. Create a table with four columns and three rows. In the first row, place the
decimal octets of the IPv4 address. In the second row, place the decimal octets of
the subnet mask.
2. For the columns that have 255 in the second row, copy the octet from the first row
to the third row. For the columns that have 0 in the second row, place a 0 in the
third row.
3. For the columns that have a number between 255 and 0 in the second row, AND
the decimal numbers in the first two rows. You can do this by converting both
numbers to binary, performing the AND comparison for all 8 bits in the octet, and
then converting the result back to decimal. Alternately, you can use a calculator,
such as the Windows Calculator, in scientific mode.
For example, for the IPv4 address configuration of 131.107.189.41, 255.255.240.0,
construct the following table:

131 107 189 41
255 255 240 0

For the first and second octets, copy the octets from the first row. For the last octet, place
a 0 in the third row. The table becomes:

131 107 189 41
255 255 240 0

69
131 107 0
For the third octet, compute 189 AND 240. In binary, this operation becomes:

10111101
AND 11110000
10110000
Converting 10110000 to decimal is 176. Alternately, use the Windows Calculator to
compute 189 AND 240, which yields 176.
The table becomes:

131 107 189 41
255 255 240 0
131 107 176 0
Therefore, the subnet prefix for the IPv4 address configuration 131.107.189.41,
255.255.240.0 is 131.107.176.0, 255.255.240.0.
Domain Names
IP addresses are difficult for humans to remember, they're great for PCs! Domain names
were invented to make it easier to navigate the Internet. A domain name is a vaguely
descriptive name separated by dots. For example: www.linuxhq.org
Every machine that runs TCP/IP has a text file called hosts. It is a simple lookup table
that the network stack (IP) checks to see if it has a match between a domain name and an
IP address. It is easily modified with a text editor and the contents look like the
following:
127.0.0.1 localhost
142.110.237.1 e237-firewall.tech.el.sait.ab.ca
142.110.237.2 e237-bridge.tech.el.sait.ab.ca
142.110.237.3 ashley.tech.el.sait.ab.ca
142.110.237.4 mariah mariah.tech.el.sait.ab.ca
The IP address is listed on the left and the domain name is listed on the right. The actual
registered domain name is sait.ab.ca (Southern Alberta Institute of Technology). The
domain name el.sait.ab.ca (electronics dept.) is a subnet of sait.ab.ca. The domain name
tech.el.sait.ab.ca (technical) is a subnet of el.sait.ab.ca.
The machine names are e237-firewall, e237-bridge, ashley and mariah. Mariah's entry is
unique in that both the domain name mariah and mariah.tech.el.sait.ab.ca would be
recognized by the IP stack as 142.110.237.4.

70
The problem with the hosts file is that each machine must have a current up to date copy
of the network. For a small network (25 or less) not connected to the Internet this is not a
problem to manage. If the network is larger, than problems can occur trying to keep
everyone updated.
Another solution is Unix's Network Information Service (NIS) (formerly called Yellow
Pages until there was a copyright conflict with the Telcos). A central NIS server shares a
master hosts file to all the clients. In this way, only one file exists and is updated. This
works well for a network not connected to the Internet.
If you are connected to the Internet then a Domain Name Server (DNS) is used. A DNS
is a special server that communicates with other servers and keeps an up-to-date look-up
table that matches IP addresses to domain names for the complete Internet. It is a
hierarchical system where each DNS is authorative for the domain underneath it. This
means that each server knows the domain name to IP address mapping of the network
underneath it.
Domain Name Structure
Domain names tend to follow a loose structure that gives a description of the network.
For example, sait.ab.ca uses the Canada extension ca, preceded by the province of
Alberta extension ab and then the abbreviation SAIT for the Southern Alberta Institute of
Technology. This is a geographical designed domain name that follows the ISO-3166
country code structure as listed in Appendix K: ISO 3166 Country Codes. Example of
country codes are:
br Brazil ca Canada
fi Finland gb United Kingdom
na Nambia nz New Zealand
tw Taiwan us United States
There are top level domain (TLD) names extensions that attempt to describe the purpose
of the domain. It is broken down into seven basic categories:
com - Commercial domains that are a business.
edu - Educational institutes
net - This is for computers of network providers such as Internet Service
Providers
org - Standard organizations or non profit organizations
int - Organizations that have been established by international treaties.
gov - Municipal, federal, provincial, state governments.
mil - United States military
All in all, it is often quite difficult to establish where a domain is physically located or
what it actually does from the domain name. But it makes remembering locations easier
than attempting to remember an IP address.
Domain Name Look-up Procedure

71
When a domain name is used, the IP stack doesn't understand domain names. It says
"what is this? Is not an IP address!". The only thing the IP stack understands is IP
addresses. The look-up order is as follows:
1. The IP stack checks the hosts file to see if there is a domain name match to IP
address. If there is, the IP address is used.
2. If there is no match, the IP stack will look for a NIS server with its host file
shared. If this service is not installed, the IP stack will jump to the next step.
3. If there is still no match, the IP stack will send out a request to the domain name
server configured during the network configuration to see if it knows whose IP
address belongs to the domain name.
4. If the domain name server doesn't know, it may make an enquiry to the next level
up domain name server to see if it knows whose IP address belongs to the domain
name and so on.
On the Internet, there are 13 top level root domain name servers. The current addresses
and domain names are found at ftp://internic.net/domain/named.cache (also called
named.ca and named. root)
Domain Name IP Address Description
A.ROOT-SERVERS.NET 198.41.0.4 formerly NS.INTERNIC.NET
B.ROOT-SERVERS.NET 128.9.0.107 formerly NS1.ISI.EDU
C.ROOT-SERVERS.NET 192.33.4.12 formerly C.PSI.NET
D.ROOT-SERVERS.NET 128.8.10.90 formerly TERP.UMD.EDU
E.ROOT-SERVERS.NET 192.203.230.10 formerly NS.NASA.GOV
F.ROOT-SERVERS.NET 192.5.5.241 formerly NS.ISC.ORG
G.ROOT-SERVERS.NET 192.112.36.4 formerly NS.NIC.DDN.MIL
H.ROOT-SERVERS.NET 128.63.2.53 formerly AOS.ARL.ARMY.MIL
I.ROOT-SERVERS.NET 192.36.148.17 formerly NIC.NORDU.NET
J.ROOT-SERVERS.NET 198.41.0.10 temporarily housed at NSI (InterNIC)
K.ROOT-SERVERS.NET 193.0.14.129 housed in LINX, operated by RIPE
NCC
L.ROOT-SERVERS.NET 198.32.64.12 temporarily housed at ISI (IANA)
M.ROOT-SERVERS.NET 202.12.27.33 housed in Japan, operated by WIDE
These are controlled by InterNIC which is the primary agency responsible for registering
domain names. At the time of this writing, there are several new agencies that are taking
over the domain registration process for different parts of the world.
Address Resolution Protocol

Address Resolution Protocol (ARP) resides in the bottom half of the Network layer. It
can be considered a mechanism for mapping addresses between the Network logical
addresses and MAC (Media Access Control) layer physical addresses. For example: the
Network layer protocol IP is not aware of 48 bit MAC addresses such as Ethernet.
Likewise the MAC layer protocol such as Ethernet is not aware of 32 bit IP addresses.
ARP provides the mechanism to map MAC addresses to IP addresses in a temporary
memory space called the ARP cache.
The ARP cache is a dynamic cache and the information is stored only for 120 seconds.
After which it is discarded. In this manner, the ARP cache remains small. The ARP cache

72
can be viewed by using the "ARP -a" command at a command prompt. This should
display the current ARP cache. If nothing is displayed, then most likely your computer
hasn't communicated on the network for the past 120 seconds. Ping another device on the
network and see if the ARP cache has changed.
The basic operation of ARP is as follows. When the IP layer wants to communicate with
another device on the network, it checks the ARP cache to see if there is a match with an
Ethernet address. If there is no matching entry in the ARP cache, an ARP broadcast
datagram is sent out that basically says "Does anybody know whose Ethernet address
belongs to this IP address?". The receiving station that has the IP address, responds with
an ARP datagram that says "This is my IP address and here is my Ethernet address". The
ARP cache is updated and the original IP layer information is then passed on to the MAC
layer for processing.
Reverse Address Resolution Protocol
Reverse Address Resolution Protocol (RARP) is the reverse of ARP. It is a mechanism to
map MAC addresses to IP addresses. It is used mainly by diskless workstations upon
boot-up to find out their IP addresses from a BOOTP server. The BOOTP server
contains all of the boot-up configuration files that the workstation needs to boot-up.
On NICs (network interface cards) there is an empty DIP socket that is used for holding a
Boot PROM. The Boot PROM holds a special software program that tells the
workstation that upon powering up, to go and find a BOOTP server. One of the first tasks
of the workstation is to find out its IP address. The MAC layer address is burnt into the
NIC and is already known.
A RARP broadcast datagram is sent out that asks "Does any BOOTP server know what
my IP address is?". The BOOTP server will reply with "Here's the IP address that belongs
to your MAC address".
Once the IP address is known, then the rest of the configuration files can be downloaded
and the diskless workstation booted up.
ICMP - Internet Control Message Protocol
The Internet Control Message Protocol's (ICMP) job is to report errors that may have
occurred in processing IP datagrams. ICMP is an integral part of IP and and its messages
are encapsulated within an IP datagram. Note: there are 6 messaging formats used by
ICMP which will be discussed later.
The most well-known uses of ICMP are the ping and traceroute (tracert in Window)
commands. The ping command sends out a special ICMP echo request message to a
destination. If the destination is alive, it will respond with the ICMP echo replay
message.
Traceroute uses the Timestamp services of ICMP to perform its task of tracing a route to
a destination. The Timestamp message and Timestamp Reply measure the roundtrip time

73
that is taken to go from the source to the destination. Traceroute lists the path and the
roundtrip time to each router taken from the source to the destination.



CHAPTER 10
THE TRANSPORT LAYER
Chapter Objectives
In this chapter you will learn:

 Understand principles behind transport layer services:
Multiplexing/demultiplexing, reliable data transfer, flow control and congestion
control.
 Distinguish between Connectionless and Connection-Oriented Services.
 Explain the services provided by Connection-Oriented
 Distinguish between UDP and TCP
 Explain the advantages and disadvantages TCP and UDP
 Explain the effects and control of congestion in computer networks
 Explain the types of network traffic

Transport Layer Functions
Let’s look at the specific functions often performed at the transport layer in more detail:
o Process-Level Addressing: Addressing at layer two deals with hardware devices
on a local network, and layer three addressing identifies devices on a logical
internetwork. Addressing is also performed at the transport layer, where it is used
to differentiate between software programs. This is part of what enables many
different software programs to use a network layer protocol simultaneously, as
mentioned above. The best example of transport-layer process-level addressing is
the TCP and UDP port mechanism used in TCP/IP, which allows applications to
be individually referenced on any TCP/IP device.
o Multiplexing and Demultiplexing: Using the addresses I just mentioned,
transport layer protocols on a sending device multiplex the data received from
many application programs for transport, combining them into a single stream of
data to be sent. The same protocols receive data and then demultiplex it from the
incoming stream of datagrams, and direct each package of data to the appropriate
recipient application processes.
o Segmentation, Packaging and Reassembly: The transport layer segments the
large amounts of data it sends over the network into smaller pieces on the source
machine, and then reassemble them on the destination machine. This function is
similar conceptually to the fragmentation function of the network layer; just as the

74
network layer fragments messages to fit the limits of the data link layer, the
transport layer segments messages to suit the requirements of the underlying
network layer.
o Connection Establishment, Management and Termination: Transport layer
connection-oriented protocols are responsible for the series of communications
required to establish a connection, maintain it as data is sent over it, and then
terminate the connection when it is no longer required.
o Acknowledgments and Retransmissions: As mentioned above, the transport
layer is where many protocols are implemented that guarantee reliable delivery of
data. This is done using a variety of techniques, most commonly the combination
of acknowledgments and retransmission timers. Each time data is sent a timer is
started; if it is received, the recipient sends back an acknowledgment to the
transmitter to indicate successful transmission. If no acknowledgment comes back
before the timer expires, the data is retransmitted. Other algorithms and
techniques are usually required to support this basic process.
o Flow Control: Transport layer protocols that offer reliable delivery also often
implement flow control features. These features allow one device in a
communication to specify to another that it must "throttle back" the rate at which
it is sending data, to avoid bogging down the receiver with data. These allow
mismatches in speed between sender and receiver to be detected and dealt with.
Relationship between the Transport Layer and Network Layer
In theory, the transport layer and network layer are distinct, but in practice, they are often
very closely related to each other. You can see this easily just by looking at the names of
common protocol stacks—they are often named after the layer three and four protocols in
the suite, implying their close relationship. For example, the name ―TCP/IP‖ comes from
the suite’s most commonly used transport layer protocol (TCP) and network layer
protocol (IP). Similarly, the Novell NetWare suite is often called ―IPX/SPX‖ for its layer
three (IPX) and layer four (SPX) protocols. Typically, specific transport layer protocols
use the network layers in the same family. You won't often find a network using the
transport layer protocol from one suite and the network layer protocol from another.
The most commonly used transport layer protocols are the Transmission Control Protocol
(TCP) and User Datagram Protocol (UDP) in the TCP/IP suite, the Sequenced Packet
Exchange (SPX) protocol in the NetWare protocol suite, and the NetBEUI protocol in the
NetBIOS/NetBEUI/NBF suite (though NetBEUI is more difficult to categorize.)
Connectionless and Connection-Oriented Services

Transport layer defines 2 types of operation for data communication:
 Type 1: Connectionless
 Type 2: Connection Oriented
Type 1: Connectionless

75
Connectionless service for data communications is very similar to sending mail with the
postal system (hand delivered mail). The data is sent and we hope it arrives at its
destination. There is no feedback from the destination to indicate whether it arrived or
not.

Type 1: Connectionless Service
Type 2: Connection Oriented
Connection Oriented service for data communications is very similar to having a phone
conversation. First a connection is made and established by dialing the number, waiting
for it to ring, someone picking up the line and saying hello. This establishes the
connection. During the conversation, confirmation that the other person is still there
(hasn't fallen asleep or died) and listening is given by hearing things like: yeah, oh really,
uh huh, etc.. This is the acknowledgement of receipt of data. If the destination party did
not hear something correctly, they ask to have it repeated which is called automatic
repeat request (ARQ).

Connection Oriented service
NOTE: These models for connectionless and connection-oriented can be used for any
protocol.
Type 2: Connection Oriented operation for the LLC layer provides 4 services:
1. Connection establishment
2. Confirmation and acknowledgement that data has been received.
3. Error recovery by requesting received bad data to be resent.
4. Sliding Windows

76
Sliding Windows are a method of increasing the rate of data transfer. Type 2
Connection Oriented operation calls for every Protocol Data Unit (LLC frame) sent to
be acknowledged. If we waited for every PDU to be acknowledged before we sent the
next PDU, we would have a very slow data transfer rate.


Delivery, Forwarding, and Routing

DELIVERY

The network layer supervises the handling of the packets by the underlying physical
networks. We define this handling as the delivery of a packet.

77

FORWARDING

Forwarding means to place the packet in its route to its destination. Forwarding requires a
host or a router to have a routing table. When a host has a packet to send or when a router
has received a packet to be forwarded, it looks at this table to find the route to the final
destination.

A routing table can be either static or dynamic. A static table is one with manual entries.
A dynamic table is one that is updated automatically when there is a change somewhere
in the Internet. A routing protocol is a combination of rules and procedures that lets
routers in the Internet inform each other of changes.


Make a routing table for router R1, using the configuration in Figure below







Routing table for router R1

78



NETWORK PRACTICALS

Practical one: Determining Data Storage Capacity


Practical Objectives
In this practical you will learn to:

• Determine the amount of RAM (in MB) installed in a PC.
• Determine the size of the hard disk drive (in GB) installed in a PC.
• Determine the used and available space on the hard disk drive (in GB).
• Check other types of storage devices (floppy, CD-ROM, DVD).

Background / Preparation

The storage capacity of many PC components is measured in megabytes (MB) and
gigabytes (GB). These Components include RAM, hard disk drives, and optical media,
such as CDs and DVDs. In this lab, you will
Determine the capacity and space available for various computer components.
The following resources are required:
• Computer with Windows XP installed

79
Step 1: Identify the RAM in a computer
a. With Windows XP, there are two ways to view control panels: Classic View and
Category View.
The options available depend on which one of these two views you are using. If you see
the Switch to Category View option on the left, you are currently in the classic view
mode. If Switch to Classic View is displayed, you are currently in Category View mode.
For this step, you want to use Classic View mode.
b. From the Start menu, select Control Panel. In the Control Panel, choose System to
open the System Properties dialog box. Alternatively, you can get this information by
clicking the Start button and right clicking the My Computer icon. Next, choose
Properties from the drop-down menu.
The computer operating system and service pack information are listed in the upper part
of the dialog box. The computer processor type, speed, and memory are listed in the
lower portion.
c. Check your computer and determine the amount of RAM available to the CPU. How
much RAM is in your computer?
Step 2: Determine the size of the hard disk drive
a. Double-click the My Computer icon on your computer desktop. If you do not have a
My Computer icon, click Start and choose My Computer.
b. Right-click the local disk drive under the Hard Disk Drives Section (which is usually
the C drive), and select Properties. This opens the Local Disk Properties dialog box.
The total capacity of the hard drive is shown above the Drive C icon.
c. Determine the size of the hard drive on your computer. What is the total size of the
hard drive in GB?
d. Keep the Local Disk Properties dialog box open for the next step.
Step 3: Determine the free space and used space on the hard drive
a. In the Local Disk Properties dialog box, the used and free space is shown in both
bytes and GB above the Capacity.
b. What is the used space of your hard drive in GB?
c. What is the free space of your hard drive in GB?
Step 4: Check for other storage devices
a. Right-click the Start button and select Explore. Select My Computer in the left pane.
b. How many drive letters are shown in the window that appears?

80
c. Right-click on a drive icon other than C: and select Properties. The Removable Disk
Properties window appears.
d. Select the Hardware tab, which provides information on each device and whether it is
working properly.
Step 5: Reflection
a. Why is it important to know the amount of RAM in your computer?
b. Why is the size of a hard drive as well as the space being used important?


PRACTICAL 2: Building Straight-Through UTP Cables

Practical Objectives
In this practical you will learn to:

• Build and test straight-through Unshielded Twisted Pair (UTP) Ethernet
network cables.

Background / Preparation

In this lab you will build and terminate Ethernet straight-through patch cables and
crossover cables. With a straight-through cable, the color of wire used by pin 1 on one
end is the same color used by pin 1 on the other cable end, and similarly for the
remaining seven pins. The cable will be constructed using either TIA/EIA T568A or
T568B standards for Ethernet, which determine which color wire is used on each pin.
Straight through patch cables are normally used to connect a host directly to a hub or
switch or to a wall plate in and office area.
The following resources will be required:

• Two 0.6 to 0.9m (2 to 3 ft.) lengths of cable, Category 5 or 5e
• A minimum of four RJ-45 connectors (more may be needed if mis-wiring
occurs)
• An RJ-45 crimping tool
• An Ethernet cable tester
• Wire cutters

T568A Standard

81

Pin No. Pair No. Wire Color Function
1 2 White/Green Transmit
2 2 Green Transmit
3 3 White/Orange Receive
4 1 Blue Not used
5 1 White/Blue Not used
6 3 Orange Receive
7 4 White/Brown Not used
8 4 Brown Not used


T568B Standard

Pin No. Pair No. Wire Color Function
1 2 White/Orange Transmit
2 2 Orange Transmit
3 3 White/Green Receive
4 1 Blue Not used
5 1 White/Blue Not used
6 3 Green Receive
7 4 White/Brown Not used
8 4 Brown Not used


Part A: Build and test an Ethernet straight-through patch cable

Step 1: Obtain and prepare the cable

a. Determine the length of cable required. This could be from a device such as a computer
to the device to which it connects (like a hub or switch) or between a device and an RJ-45
outlet jack. Add at least 30.48 cm (12 in.) to the distance. The TIA/EIA standard states
the maximum length is 5 m (16.4 ft.).Standard Ethernet cable lengths are usually .6 m (2
ft.), 1.83 m (6 ft.), or 3.05 m (10 ft.).
b. Which length of cable did you choose and why did you choose this length?
c. Cut a piece of cable to the desired length. Stranded UTP cable is commonly used for
patch cables (the cables between an end network device such as a PC and an RJ-45
connector) because it is more durable when bent repeatedly. It is called stranded because
each of the wires within the cable is made up of many strands of fine copper wire, rather
than a single solid wire. Solid wire is used for cable runs that are between the RJ-45 jack
and a punch-down block.
d. Using wire strippers, remove 5.08 cm (2 in.) of the cable jacket from both ends of the
cable.

82
Step 2: Prepare and insert the wires
a. Determine which wiring standard will be used. Circle the standard.
[T568A | T568B]
b. Locate the correct table based on the wiring standard used.
c. Spread the cable pairs and arrange them roughly in the desired order based on the
standard chosen.
d. Untwist a short length of the pairs and arrange them in the exact order needed by the
standard.
It is very important to untwist as little as possible. The twists are important because
they provide noise cancellation.
e. Straighten and flatten the wires between your thumb and forefinger.
f. Ensure the cable wires are still in the correct order as the standard.
g. Cut the cable in a straight line to within 1.25 to 1.9 cm (1/2 to 3/4 in.) from the edge of
the cable jacket. If it is longer than this, the cable will be susceptible to crosstalk (the
interference of bits from one wire with an adjacent wire).
h. The tang (the prong that sticks out from the RJ-45 connector) should be on the
underside pointing downward when inserting the wires. Insert the wires firmly into the
RJ-45 connector until all wires are pushed as far as possible into the connector.
Step 3: Inspect, crimp, and re-inspect
a. Visually inspect the cable and ensure the right color codes are connected to the correct
pin numbers.
b. Visually inspect the end of the connector. The eight wires should be pressed firmly
against the end of the RJ-45 connector. Some of the cable jacket should be inside the first
portion of the connector.
This provides strain relief for the cable. If the cable jacket is not far enough inside the
connector, it may eventually cause the cable to fail.
c. If everything is correctly aligned and inserted properly, place the RJ-45 connector and
cable into the crimper. The crimper will push two plungers down on the RJ-45 connector.
d. Visually re-inspect the connector. If improperly installed, cut the end off and repeat the
process.
Step 4: Terminate the other cable end
a. Use the previously described steps to attach an RJ-45 connector to the other end of the
cable.

83
b. Visually re-inspect the connector. If improperly installed, cut the end off and repeat the
process.
c. Which standard [T568A | T568B] is used for patch cables in your school?

Step 5: Test the cable
a. Using a cable tester, test the straight-through cable for functionality. If it fails, repeat
the lab.
b. (Optional) Use the cable to connect a PC to a network.
c. (Optional) Click the Start button and select the Run option.
d. (Optional) Type cmd and press Enter.
e. (Optional) from the command prompt, type ipconfig.
f. (Optional) Write down the default gateway IP address.
g. (Optional) from the command prompt, type ping followed by the default gateway IP
address. If the cable is functional, the ping should be successful (provided that no other
network problem exists and the default gateway router is connected and functional).

PRACTICAL 3: Building Crossover UTP Cables

Practical Objectives
In this practical you will learn to:

• Build and test crossover Unshielded Twisted Pair (UTP) Ethernet network
cables.

With a crossover cable the second and third pairs on the RJ-45 connector at one end of
the cable are reversed at the other end. The pin outs for the cable are the T568A standard
on one end and the T568B standard on the other end. Crossover cables are normally used
to connect hubs and switches or can be used to directly connect two hosts to create a
simple network. This is a two-part lab that can be done individually, in pairs, or in
groups.



Part B: Build and test an Ethernet crossover cable

84
Step 1: Obtain and prepare the cable
a. Determine the length of cable required. This could be from a hub to a hub, hub to
switch, switch to switch, computer to router, or from one computer to another computer.
Add at least 30.48 cm (12 in.) to the distance. Which length of cable did you choose and
why did you choose this length?
b. Cut a piece of cable to the desired length and, using wire strippers, remove 5.08 cm (2
in.) of the cable jacket from both ends of the cable.
Step 2: Prepare and insert the T568A wires
a. Locate the T568A table at the beginning of the lab.
b. Spread the cable pairs and arrange them roughly in the desired order based on the
T568A standard.
c. Untwist a short length of the pairs and arrange them in the exact order needed by the
standard. It is very important to untwist as little as possible. Twists are important because
they provide noise cancellation.
d. Straighten and flatten the wires between your thumb and forefinger.
e. Ensure the cable wires are in the correct order based on the standard.
f. Cut the cable in a straight line to within 1.25 to 1.9 cm (1/2 to 3/4 in.) from the edge of
the cable jacket. If it is longer than this, the cable will be susceptible to crosstalk (the
interference of bits from one wire with an adjacent wire).
g. The tang (the prong that sticks out from the RJ-45 connector) should be on the
underside pointing downward when inserting the wires. Insert the wires firmly into the
RJ-45 connector until all wires are pushed as far as possible into the connector.
Step 3: Inspect, crimp, and re-inspect
a. Visually inspect the cable and ensure the right color codes are connected to the correct
pin numbers.
b. Visually inspect the end of the connector. The eight wires should be pressed firmly
against the RJ-45 connector. Some of the cable jacket should be inside the first portion of
the connector. This provides for cable strain relief which can eventually cause the cable
to fail.
c. If everything is correctly aligned and inserted properly, place the RJ-45 connector and
cable into the crimper. The crimper will push two plungers down on the RJ-45 connector.
d. Visually re-inspect the connector. If improperly installed, cut the end off and repeat the
process.

85
Step 4: Terminate the T568B cable end
a. On the other end, use the previously described steps (but use the T568B table and
standard) to attach an RJ-45 connector to the cable.
b. Visually re-inspect the connector. If improperly installed, cut the end off and repeat the
process.
c. Which standard [T568A | T568B] would you rather use at home if you have or would
like to have a home network?
Step 5: Test the cable
a. Using a cable tester, test the crossover cable for functionality. If it fails, repeat the lab.
b. Use the cable to connect two PCs.
c. On both computers, click the Start button and select Run.
NOTE: If the Run command is unavailable on your PC, visually check the LED status
lights on the NIC card. If they are on (usually green or amber) the cable is functional.
d. On both computers, type cmd and press Enter.
e. On both computers from the command prompt, type ipconfig.
f. Write the IP address of both computers.
Computer 1: _________________________
Computer 2: _________________________
g. From the command prompt of one computer, type ping followed by the IP address of
the other computer. If the cable is functional, the ping should be successful. Do the ping
on the other computer as well.
NOTE: The Windows Firewall on the target computer must be temporarily disabled for
the ping to be successful. Refer to Lab 3.1.5 if you need help with this. If you disable the
firewall, be sure to re enable it.
Step 6: Reflection
a. Which part of making these cables did you find the most difficult? Compare your
views with a classmate.
b. Are all four pairs of cables twisted the same amount? Discuss the reasons why or why
not.
c. Ask a local business or check a site such as http://www.workopolis.com/ to see how
much a beginning cable installer earns and which criteria they look for in a cable
installer. Write the information you discover in the space provided.

86
d. Many technicians keep a crossover cable in their toolkit. When do you think that you
would use a crossover cable and when do you think a network technician would use this
cable?
Practical 4: NIC Card Installation

Practical Objectives
In this practical you will learn to:

 How to Install the network interface card

1. Step 1
Unplug the PC from its electrical source, and remove all cords.
2. Step 2
Open the case of the CPU with a screwdriver. Be careful of sharp metal edges. If
the case doesn't open easily, check your operator's manual. There may be a release
button that will open the case after the screws are undone.
3. Step 3
Lay the CPU on its side. Locate the NIC slot. Align the NIC with the RJ45 jack
facing the outside of the case. Firmly seat the card into the slot. You may have to
rock it gently to get it to fit. The gold contacts should not be visible, and the NIC
card should be level.
4. Step 4
Secure the mounting bracket with screws. They should come with the NIC card.
5. Step 5
Replace the cover. Securely reattach all cords.
6. Step 6
Connect the RJ45 connection to the Internet modem using the Ethernet wire. Not
all NIC cards come with an Ethernet wire. Sometimes you will need to purchase
the Ethernet wire separately.
7. Step 7

87
Reboot the computer, and install the software that comes with the NIC card. This
will install the necessary drivers. There will be prompts as the hardware installs.
Simply follow the directions.
Practical 5: Network Connection Installation

Practical Objectives
In this practical you will learn to:

 How to install and configure network connections(TCP/IP)
1 Step 1
Open the Control Panel. Go to Start, and then click Control Panel. Click Network
to open the Network Control Panel.
2 Step 2
Choose TCP/IP. It is probably loaded into your system as a protocol. If not, add it
by following the prompts. After verifying the computer has TCP/IP protocol,
click TCP/IP one time. Then click Properties.
3 Step 3
Pick both Obtain an IP Address Automatically and the Obtain DNS Server
Address Automatically. Then click the Advanced button.
4 Step 4
Select the DNS tab in the Advanced TCP/IP Settings window. Uncheck the box
for Register This Connection's Addresses in DNS. It is toward the bottom of the
screen.
5 Step 5
Click OK to close all the open windows. Restart your computer if you are asked
to do so.

Practical 6: Building a Peer-to-Peer Network

Practical Objectives
In this practical you will learn to:

• Design and build a simple peer-to-peer network using a crossover cable.

88
• Verify connectivity between the peers using the ping command.

Background / Preparation

In this hands-on lab, you will plan and build a simple peer-to-peer network using two PCs
and an Ethernet crossover cable.
The following resources are required:
• Two Window XP Professional PCs, each with an installed and functional Network
Interface Card (NIC)
• An Ethernet crossover cable
Step 1: Diagram the network
a. A network diagram is a map of the logical topology of the network. In the space below,
sketch a simple peer-to-peer network connecting two PCs. Label one PC with IP address
192.168.1.1 and the other PC with IP address 192.168.1.2. Use labels to indicate
connecting media and any necessary network devices.
b. A simple network like the one you designed can use a hub or switch as a central
connecting device, or the PCs may be directly connected. Which kind of cable is required
for a direct Ethernet connection between the two PCs?
Step 2: Document the PCs
a. Check the computer name settings for each PC and make adjustments as necessary. For
each PC, select Start and Control Panel. Double-click the System icon, then click the
Computer Name tab.
Write down the computer name that is displayed following Full computer name:
PC1 Name:
PC2 Name:
b. Check to see if the two PCs have the same name. If they do, change the name of one
PC by clicking the Change button, typing a new name in the Computer name field, then
clicking OK.
c. Click OK to close the System Properties window.
d. Why is it important that each PC on a network have a unique name?
Step 3: Connect the Ethernet cable
a. Use the Ethernet crossover cable. Plug one end of the cable into the Ethernet NIC of
PC1.

89
b. Plug the other end of the cable into the Ethernet NIC of PC2. As you insert the cable,
you should hear a click which indicates that the cable connector is properly inserted into
the port.
Step 4: Verify physical connectivity
a. After the Ethernet crossover cable is connected to both PCs, take a close look at each
Ethernet port. A light (usually green or amber) indicates that physical connectivity has
been established between the two NICs. Try unplugging the cable from one PC then
reconnecting it to verify that the light goes off then back on.
b. Go to the Control Panel, double click the Network Connections icon, and confirm
that the local area connection is established. The following figure shows an active local
area connection. If physical connectivity problems exist, you will see a red X over the
Local Area Connection icon with the words Network cable unplugged.
c. If the Local Area Connection does not indicate that it is connected, troubleshoot by
repeating Steps 3 and 4. You may also want to ask your instructor to confirm that you are
using an Ethernet crossover cable.
Step 5: Configure IP settings
a. Configure the logical addresses for the two PCs so that they are able to communicate
using TCP/IP. On one of the PCs, go to the Control Panel, double click the Network
Connections icon, and then right click the connected Local Area Connection icon.
Choose Properties from the pull-down menu.
b. Using the scroll bar in the Local Area Connection Properties window, scroll down to
highlight
Internet Protocol (TCP/IP). Click the Properties button.
c. Select the Use the following IP address radio button and enter the following
information:
IP Address 192.168.1.1
Subnet Mask 255.255.255.0
d. Click OK, which will close the Internet Protocol (TCP/IP) Properties window.
Click the Close button to exit the Local Area Connection Properties window.
e. Repeat steps 5a – 5d for the second PC using the following information:
IP Address 192.168.1.2
Subnet Mask 255.255.255.0
Step 6: Verify IP connectivity between the two PCs

90
NOTE: To test TCP/IP connectivity between the PCs, Windows Firewall must be
disabled temporarily on both PCs. Windows Firewall should be re-enabled after the tests
have been completed.
a. On PC1, on the Windows XP desktop, click Start. From the Start menu, select
Control Panel, and double-click Network Connections.
b. Right-click the Local Area Connection icon and select Properties. Click the
Advanced tab. Locate and click the Settings button.
c. Make a note of whether the firewall settings are ENABLED (ON) for the Ethernet port
or DISABLED (OFF) for the Ethernet port.
d. If the firewall settings are enabled, click the off (not recommended) radio button to
disable the firewall. The setting will be re-enabled in a later step. Click OK in this dialog
box and the following to apply this setting.
e. Now that the two PCs are physically connected and configured correctly with IP
addresses, we need to make sure they communicate with each other. The ping command
is a simple way to accomplish this task. The ping command is included with the
Windows XP operating system.
f. On PC1, go to Start, then Run. Type cmd, and then click OK. A Windows command
prompt window will appear as shown in the figure below.
g. At the > prompt, type ping 192.168.1.2 and press Enter. A successful ping will verify
the IP connectivity. It should produce results similar to those shown in here.
h. Repeat Steps 6a-6c on the second PC. The second PC will ping 192.168.1.1.
i. Close the Windows command prompt window on both PCs.
Step 7: Verify connectivity using My Network Places
a. A PC can share its resources with other PCs on the network. PCs with shared resources
should be visible through My Network Places. On PC1, go to Start, click My Network
Places, and then click View workgroup computers in the left panel.
b. Do you see an icon for the other PC in your peer-to-peer network?
_______________________
c. What is the name of the other PC?
________________________________________________
d. Is it the same name you recorded in Step 2?
_________________________________________
e. Perform Step 7a on the second PC.

91
f. Close any open windows.
Step 8: (Optional – Use only if the Firewall was originally ENABLED) Re-enable the
firewall
a. If you disabled the Windows Firewall in Step 6, click Start, select Control Panel, and
open the
Network Connections control panel.
b. Right-click the Ethernet network connection icon and select Properties. Click the
Advanced tab. Locate and click Settings.
c. If the firewall settings are disabled (and they were enabled before this lab began), click
the on radio button to enable the firewall. Click OK in this dialog box and the following
one to apply this setting.

Practical 7: Sharing Resources

Practical Objectives
In this practical you will learn to:

Use Windows XP to complete the following tasks:
• Share files and folders.
• Map network drives.

Background/Preparation

One of the key benefits of having PCs networked together is that it provides access to be
able to share information with other connected users. Whether it is a song, a proposal or
your holiday pictures, there are many situations where you need to share data with friends
or business colleagues. Mapping drives, goes hand-in-hand with sharing folders because
drive mappings provide quick access to commonly used folders. They also provide an
easier way for users to navigate and find the files and/or folders they are looking for.
Drive mappings redirect a local resource (drive letter) to a shared network resource (hard
drive or folder on the network).
The following resources are required:

92
• Two configured Windows XP Professional workstations connected via a local network.
Note: Use the previously configured network from lab activity 3.6.4.
Step 1: Share a folder
a. Click Start. From the Start Menu, select All Programs, Accessories, and then
Windows Explorer.
b. In the Folders pane, click the plus sign (+) beside My Computer. Click the C: drive.
From the File menu. Select New and from the sub-menu, select the Folder option. Type
Share as the name of the folder.
c. Right-click the new folder Share and choose Properties.
NOTE: The Sharing option is not available for the Documents and Settings, Program
Files, and Windows system folders.
d. Select the Sharing tab. In the Share Properties dialog box, click the Share this folder
radio button to share the folder with other users on your network. The default name for
the shared folder is the same name as the original folder name.
NOTE: To change the name of the folder on the network, type a new name for the folder
in the Share name text box. This will not change the name of the folder on your
computer.
e. Click Apply and then OK.
f. Create a text file using Notepad and save it to the Share folder. On the Windows XP
desktop, click Start, select All Programs, Accessories, and then Notepad.
In the Notepad application, type the message ―Hello World!‖.
From the File menu, select Save. In the File name field, type ―Test message‖. Click the
icon with the folder and up arrow as shown in the following figure.
g. Double-click My Computer, then double-click drive C:. Locate and double-click the
Share folder, then click Save.
h. Close the Notepad application.
i. Repeat Steps 1 – 5 for the second Windows XP Professional machine with the
following exceptions:
Share name: Share2
Text file contents: Hello planet!
Text file name: Test Message 2
Step 2: Map network drives to provide quick and easy access to shared folders

93
a. On the first Windows XP workstation, click Start, select All Programs, Accessories,
and then Windows Explorer.
b. In the Folders pane, click My Computer. From Tools Menu, select Map Network
Drive….
c. In the Drive textbox, select an unused drive letter using the pulldown menu.
d. Question: What drive letter did you choose?
________________________________________
e. In the Folder field, type the IP address of the remote PC and the name of the remote
share using the format: \\ip_address\sharename
f. Click Finish.
A window will appear with the message attempting to connect to
\\192.168.10.3\share2. A window will open to display the contents of the shared folder
called Share2 that has now been assigned a drive letter.
NOTE: The IP address can be replaced by the computer name.
g. Double-click the Test Message 2 text document. Add the words Techs rule to the
document. From the File menu and select Save.
Question: What message is displayed? Why do you think this happened?
_________________
h. The files within a shared folder are automatically protected in the Windows XP
Professional version.
Click OK in the message box. Click Cancel, and then click Close for the Test Message 2
document.
i. In the message box, click No to close the document without saving the changes.
j. Repeat procedures a-e under Step 2 to map a drive on the second Windows XP
workstation. This drive should be mapped to the share you configured in Step 1.
Step 3: Verify work
a. From the first Windows XP Professional machine, click Start, select All Programs,
then Accessories, and Windows Explorer.
b. Expand My Computer by clicking on the plus sign (+) beside the option.
c. The Windows Explorer list should display a drive with the drive letter label that you
chose for the remote share.
d. Repeat procedures a-c for the second Windows XP Professional machine.

94
If the drive letter appears on both computers, then the folders are shared and drives are
mapped properly on both Windows XP workstations. You can perform the same steps on
any folder. When a drive is properly mapped to shared folders, all files and folders within
the shared folder will be accessible from the workstations.
Step 4: Reflection
a. What are some of the benefits of mapped drives and shared folders in a home or small
office network?
b. Which folders cannot be shared? Can you think of reasons why an operating system
might not allow certain types of folders to be shared?
________________________________________________________________________
c. A mapped drive provides a pointer to a network resource, but mapped drive letters are
said to be locally significant only. What do you think is meant by locally significant?
Practical 8: Troubleshoot basic connectivity issues
Practical Objectives
In this practical you will learn to:
 Troubleshoot basic connectivity issues and verify name resolution between
computers, follow these steps in the order in which they are provided until you
isolate and resolve the issue.
Step 1: Verify the physical connection between computers
The back of each network adapter in a desktop computer has visible lights. These lights
indicate a good connection. If you are using a network hub, or a switch to connect the
computers, make sure that the network hub or the switch is turned on and that the lights
are illuminated for each client connection. This indicates a good link.
Step 2: Make sure that all computers have TCP/IP installed
This step is especially important with Microsoft Windows 95-based computers. By
default, Windows 95-based computers do not have TCP/IP installed. If you are using
computers that run Windows 95, Microsoft Windows 98, or Microsoft Windows
Millennium Edition on the network, you can look for TCP/IP by using the Network item
in Control Panel. If TCP/IP is not installed, you must install it to communicate with
Windows XP-based computers on the network. TCP/IP is always installed in Windows
XP.

95
Step 3: Make sure that the network configuration includes the IP addresses
Collect network configuration information from at least two computers on the network by
using the adapter status. Then, make sure that the assigned IP addresses match the home-
network configurations described in the "Home-network structures and their
configurations" section. Follow these steps:
1. Click Start, click Run, type ncpa.cpl and then click OK.
2. Locate and right-click the icon that represents this computer's connection to the
home network, and then click Status.
3. Click the Support tab, and then under Connection status, locate the IP addresses.
If the assigned IP addresses do not match the topology that this article described in the
"Home-network structures and their configurations" section, the computer that is
assigning the addresses may not be available. This is likely to be true if 169.254.x.y
addresses are in a configuration where you expect a different address range.
To change the configuration so that the addresses on the home network adapter for each
computer are in the same range, determine which address is correct based on the network
topology. To do this, check whether one computer receives an address in the range
192.168.0.x, and another receives an address in the range 169.254.x.y. When you isolate
which computer has the incorrect address, troubleshoot the computer that has the
incorrect address.
Note:- For Windows 95-based computers in a network that uses 169.254.x.y addressing,
you must configure IP addresses manually. For information about how to do this, see the
online Help for Windows 95.
Step 4: Make sure that firewall features are not enabled on the home network
adapters
Verify that the Internet Connection Firewall (ICF) or Windows Firewall (WF) feature is
not enabled on the adapters that you use to connect the computers to the home network. If
these features are enabled on these adapters, you cannot connect to shared resources on
other computers in the network.
Note:-Edgeless networks are the exception. You can use ICF with edgeless networks if
you take additional measures to enable connectivity in the home network.
Step 5: Test connectivity between computers by using the "ping" command
To use the ping command to test connectivity between two computers on the network,
on one of the computers, click Start, click Run, type command and then click OK.
At the command prompt, type ping x.x.x.x (where x.x.x.x is the IP address of the other
computer), and then press ENTER. If the ping command is successful, and the computers
can connect correctly after you have verified connectivity and name resolution between
computers, you can troubleshoot the connectivity for file and printer sharing.

Practical 9: Troubleshoot file sharing and printer sharing

96
Practical Objectives
In this practical you will learn to:
After the computers are connected, you can share files and printers between computers
through the home network. To troubleshoot file sharing and printer sharing, follow these
steps in the order in which they are provided until you isolate and resolve the issue.
Step 1: Run the Network Setup Wizard to configure each computer in the network
To configure file and printer sharing, run the Network Setup Wizard on each computer in
the network. When you are finished configuring file sharing and printer sharing on each
computer in the network, go to step 2. If you were unable to configure file sharing and
printer sharing, go to the "Next Steps" section for information about how to contact
Support.
Step 2: Make sure that file sharing is configured correctly on each computer.
When you are finished configuring file sharing on each computer, go to step 3. If you
were unable to configure file sharing, go to the "Next Steps" section for information
about how to contact Support.
Step 3: Make sure that the Guest account is set up for network access
All network access to either a Windows XP Home Edition-based computer in a
workgroup or to a Windows XP Professional-based computer in a workgroup uses the
Guest account. Before you continue to troubleshoot, make sure that the Guest account is
set up for network access. Follow these steps:
 Click Start, click Run, type command, and then click OK.
 Type the net user guest and then press ENTER.
 If the account is active, a line appears in the output of the command that has the
following format:
Account active Yes
 If the account is not active,
 type net user guest /active: yes and then press ENTER to give the Guest account
network access. The following text returns after the command:
The command completed successfully.
If you receive any other response, make sure that you are logged on as an administrator,
and then confirm that you typed the command correctly before you try again. When you
are finished setting up the Guest account for network access, go to step 4. If you were
unable to set up the Guest account, go to the "Next Steps" section for information about
how to contact Support.

97
Step 4: Make sure that folder for the computer name is shared
After you have verified the file-sharing configuration and set up the Guest account for
network access, make sure that the folder for each computer is shared. Follow these steps:
 To locate the computer name for each computer, click Start, click Run, type
sysdm.cpl, and then click OK.
 On the Computer Name tab, under Full computer name, locate the computer
name.
 To determine whether a folder is shared, click Start, click Run, type fsmgmt.msc,
and then click OK.
 In the left navigation pane, click Shares. A list of shared folders is displayed in
the right navigation pane.
 Locate the share folder for each computer.
 If all computer names are listed, go to step 5.
Step 5: Test the connection between computers
To test the connection from one computer to another, follow these steps:
 Click Start, click Run, type \\computername (where computer name is the name
of another computer on the network), and then press ENTER. A window opens
that contains an icon for each shared folder on the other computer.
 Try to open one of the shared folders to confirm that the connection is working.
 If you can open a shared folder, the computers are connected. Go to step 6.
 If you cannot open a shared folder, go to step c.
 Test the connection from the opposite direction. To do this, go to the other
computer on the network and repeat steps 1 and 2 to try to open a shared folder
between the computers, or between other computers to make sure that the
problem is not with a particular computer on the network.
 If you can open a shared folder from each computer, the computers are connected.
Go to step 6.
 If you can open a shared folder from one computer but not the other, the problem
may be that the other computer cannot access the folder. Go to step d to
troubleshoot the connection for the other computer.
 If you cannot open a shared folder from either computer, there may be a problem
with the connection. Go to the "Troubleshoot basic connectivity" section and see
step 5.
 If you still cannot open a shared folder, try again to test the connection with the
computer name as the name of the local computer. This tests the connection
locally. A window is displayed with an icon for each shared folder on the
computer. Try to open one of the shared folders to make sure that you have
access.
 If you can open a shared folder, the computers are connected. Go to step 6.
Step 6: Check the Network Setup Wizard log file for errors
Check the Network Setup Wizard log file for errors in any events that are not followed by
successful operations. To open the log and check for errors, follow these steps:

98
Click Start, click Run, type %SystemRoot%\nsw.log and then press ENTER.
If you find errors in the log, search the computernetworkingnotes.com for more
information about how to manually configure the computer to have the correct settings.
When you are finished checking the Network Setup Wizard log file for errors, you should
now have connectivity for file and printer sharing
Practical 10: Connect and Configure Hosts and Router


Practical Objectives
In this practical you will learn to:

• Connect a PC to a router using a straight-through cable.
• Configure the PC with an appropriate IP address.
• Configure the PC with a NetBIOS computer name.
• Verify the PC configuration using Windows XP and through a command prompt.

Background / Preparation

In order for the PC to participate in the local network and the Internet, it must be
connected to a network device. The following resources will be required:
• Linksys Model WRT300N wireless router or equivalent SOHO router
• Two computers with Ethernet NICs and Windows XP Professional installed on both
• Two straight-through cables
Step 1: Identify Ethernet ports
a. On the Linksys router, locate the Ethernet (Local Area Network) LAN ports. The
Ethernet LAN ports connect your network hosts and devices. The four LAN ports are
grouped together in the center of the router as shown in the following figure.
b. On the PC, locate the Ethernet port. The port could be integrated into the motherboard
or it could be an adapter. In either case, the port will be an RJ-45 port. The photo shows
an Ethernet port on an adapter.
Step 2: Connect the cable between the PC and the router
a. Connect one end of the straight-through Ethernet cable to an Ethernet LAN port on the
router.
b. Connect the other end of the cable to the PC Ethernet port.
c. Repeat this procedure for the second PC.

99
Step 3: Assign the PCs an IP address and default gateway
a. In order to assign an IP address and default gateway to a Windows XP host, from the
Start menu, select Control Panel.
b. There are two ways to view Control Panels: Classic view and Category view. The
options available depend on which one of these two views you are using. If you see an
option on the left that says Switch to Category View, you are currently in the Classic
view mode. If you see an option on the left that says Switch to Classic View, you are
currently in Category view mode. Ensure that you are in Classic view mode.
c. Locate and double-click the Network Connections control panel icon.
d. Right-click the Local Area Connection icon that represents your NIC and click the
Properties menu option.
e. In the middle window, scroll down until you see and can double-click the Internet
Protocol (TCP/IP) option. The figure that follows shows this option.
f. Click the Properties button and the Internet Protocol [TCP/IP] Properties window will
appear.. Next, click the Use the following IP address button, which activates the IP
address, Subnet mask, and Default gateway textboxes.
In the IP address field, enter 192.168.10.2. Configure the subnet mask to 255.255.255.0.
Configure the default gateway to 192.168.10.1. The figure that follows shows these
settings. (DNS server information is not necessary at this time, so the fields under Use
the following DNS server addresses don’t need to be filled out.) When finished, click
OK.
g. From the Internet Protocol [TCP/IP] Properties window, click OK to apply the
changes. Be patient, since this step may take some time. After the changes are applied,
you will be returned to the Network Connections window.
h. Since the two computers are on the same network, their IP addresses will be similar,
their subnet masks will be identical, and their default gateways will be identical. Perform
the same procedures on the second PC to assign an IP address, subnet mask, and default
gateway using the following information:
IP address: 192.168.10.3
Subnet mask: 255.255.255.0
Default gateway: 192.168.10.1
i. Why do you think the IP addresses are different, but the subnet masks and default
gateways are the same?

100
Step 4: Verify the IP address configuration
a. On the Windows XP desktop, click Start.
b. From the Start menu, select the Run menu option.
c. In the Open: textbox, type cmd and press Enter. A command prompt appears. The
figures that follow show this process.
d. In the command line prompt, type ipconfig /all. Verify that the IP address and the
default gateway are the values that you entered in the earlier steps. If they are incorrect,
repeat Steps 3 and 4.
e. Are the IP address, subnet mask, and default gateway correct for the first PC?
f. Perform the same configuration check on the second PC. If the values are incorrect,
repeat Steps 3 and 4.
g. Are the IP address, subnet mask, and default gateway correct for the second PC?

Step 5: Test connectivity between the two PCs
NOTE: To test TCP/IP connectivity between the PCs, Windows Firewall must be
disabled temporarily on both
PCs. Windows Firewall should be re-enabled after the tests have been completed.
a. On PC1, on the Windows XP desktop, click Start. From the Start menu, select Control
Panel, and double-click Network Connections.
b. Right-click the Local Area Connection icon and select Properties. Click the Advanced
tab. Locate and click the Settings button.
c. Make a note of whether the firewall settings are ENABLED (ON) for the Ethernet port
or DISABLED (OFF) for the Ethernet port.
_______________________________________________________
d. If the firewall settings are enabled, click the Off (not recommended) radio button to
disable the firewall. The setting will be re-enabled in a later step. Click OK in this dialog
box and the following to apply this setting.
e. From the same command prompt on the first PC, type ping 192.168.10.3 to test
connectivity with the second PC.
f. If the ping is successful, you will see results similar to the following figure. If the ping
is not successful, perform the appropriate troubleshooting steps such as checking the
cabling and checking your IP address, subnet mask, and default gateway assignments.

101
g. From the command prompt on the second PC, type ping 192.168.10.2 to check
connectivity to the first PC.
The ping should succeed.

Step 6: Configure the NetBIOS name
a. Right-click Start and select the Explore option.
b. How many drive letters are shown in the window that appears?
_________________________
c. Which drive letters are shown?
d. Right-click the My Computer icon on your Windows XP desktop and select the
Properties option. The System Properties window appears.
NOTE: If the My Computer icon does not appear on the desktop, click Start then right-
click MyComputer.
e. Click the Computer Name tab. An example of the window that appears follows:
f. Click Change. Make a note of the current computer name. _______________
g. In the Computer Name textbox, type PC1. Ensure the Member of radio button or field
is set to Workgroup.
h. Make a note of the Workgroup name.
__________________________________________
i. Click OK. If prompted to restart the computer, click OK to restart and follow the
directions on the screen.
j. Use the same process to name the second computer PC2. Also ensure that the
Workgroup name is set to the same value as PC1.
Step 7: Verify configuration
a. To verify the new configuration, open a command prompt on each computer. If you
forgot how, refer to Steps 4a, b, and c.
b. Use the nbtstat command to view and gather information about remote computers.
From the command prompt, type nbtstat and press Enter. Help for the command displays
as shown:
The letters shown are options called switches that you can use with the nbtstat
command.
a. On PC1, type nbtstat –n and press Enter to see the local NetBIOS name of PC1.
b. On PC2, type the same command to verify the NetBIOS name is set to PC2.

102
c. The nbtstat –a command can be used to look at a remote computer’s name table. Type
nbtstat again from the command prompt. Notice in the output that when you use the –a
switch, you have to put a space and then type a remote computer’s name (RemoteName).
From PC1, type nbtstat –a PC2 and press Enter. The nbtstat information for PC2 shows
on PC1’s monitor.
What command would be used from the command prompt on PC2 to view information
about PC1?
d. From PC2, type the appropriate command to view PC1’s nbtstat information.
e. The nbtstat –A (notice that the switch is a capital A this time) can be used to view the
same information using an IP address rather than a name. If you type nbtstat again, you
can see that the command syntax tells us that we use –A followed by an IP address. The
IP address is that of the remote computer.
From PC1, type nbtstat –A 192.168.10.3 to see the same information that was returned
by the nbtstat –a PC2 command.
f. Write the command that would be typed on PC2 to view information about PC1, using
the IP address of PC1 instead of the NetBIOS name.
_____________________________________________
g. From PC1, you can use the ping command to verify connectivity. However, instead of
using an IP address, you can use the NetBIOS name. From the PC1 command prompt,
type ping PC2 (notice the capitalization). The result should be successful.
h. From PC1, type ping pc2 (notice the capitalization).
i. Does the ping succeed using lower case letters?
______________________________________
j. You can use the nbtstat –r command to see NetBIOS names that have been resolved
(they are known). From the PC1 and PC2 command prompt, type nbtstat –r to see that
the remote computer is known using NetBIOS.
k. Close the command prompt window.
Step 8: (Optional – Use only if the Firewall was originally ENABLED) Re-enable the
firewall
a. If the answer to Step 5c was OFF or ENABLED on PC1, click Start, select Control
Panel, and open the Network Connections control panel.
b. Right-click the Ethernet network connection icon and select Properties. Click the
Advanced tab. Locate and click Settings.

103
c. If the firewall settings are disabled (and they were enabled before this lab began), click
the on radio button to disable the firewall. Click OK in this dialog box and the following
one to apply this setting.
Step 9: Return IP Address and NetBIOS Name to original values
a. Return to Step 3 to change the IP address back to the original.
b. Return to Step 6d to change the NetBIOS name back to the original.
Step 10: Reflection
a. Check two or three computers in your lab at school. Complete the following table:
Computer Name IP Address & Subnet Mask
Default Gateway
1
2
3
b. Either with a classmate assigned to you or by choosing one yourself, share this
information with them.
In your opinion, are the names descriptive?
_________________________________________
c. Are all of the computers in the classroom part of the same local network? How could
you prove that?

PRACTICAL 11: SEVEN STEPS TO SUBNETING

Creating Class C Subnetting Scheme

Basic subnetting is very easy when performed in seven steps. This example uses the
Class C address 211.212.10.0. Using the seven steps provided here, you can create a
subnetting scheme that allows you to use this address on your network.

Step 1: Determining Number of Subnets Needed

Determining the number of subnets you need is the very first step in subnetting. The
number really depends upon your particular network. In Figure 2-3, the network consists
of three routers connected via serial links. Each router also has a single Ethernet network
attached.
Each shared serial link requires one subnet. Therefore, you need two subnets for the serial
links between Router A and Routers B and C. You must also have one subnet per
Ethernet interface on each router. Since you have three Ethernet networks, you need three
subnets. Using this very simple counting method, you find that you need a total of five
subnets. Unfortunately, you have been assigned a Class C address. The network address

104
211.212.10.0 allows for a single network of 254 hosts. You must borrow host ID bits to
make this address work for you.

Step 2: Determining Number of Bits You Can Borrow

In Step 2, you must determine the number of bits that you can borrow. This number
changes depending on the type of network address you start with. For Class A addresses,
you have 24 host ID bits, but you can only borrow up to 22. For Class B addresses, you
have 16 host ID bits, but you must have a minimum of two host bits; therefore, you can
borrow 14 bits. Your Class C address (211.212.10.0) has eight total







Host ID bits, but you can only borrow a maximum of six. The easiest way to determine
the number of bits you can borrow is to write the number of octets that contain host ID
bits in binary. In the Class C example network 211.212.10.0, you have the following bits
to ―play‖ with: 00000000

Step 3: Determining Number of Bits You Must Borrow to Get Needed Number of
Subnets

After you determine the number of subnets you need and the number of bits you can
borrow, you must calculate the number of host ID bits you must borrow to get the needed
number of subnets. The formula for determining the number if bits you must borrow is
2
n
-2= # of subnets. The n represents the number of bits you borrow. In other words, raise
two to the power of the number of bits you borrow and subtract two from that number.
The result is the number of useable subnets created when you borrow that number of bits.

105
For the example network, you need five subnets. If you borrow three bits, the formula’s
result is six usable subnets: 2
3
= 8-2 = 6.

Step 4: Turning On Borrowed Bits and Determining Decimal Value

In Step 4, using the bits you determined were available in Step 2, you turn on (set to 1)
the number of bits determined you must borrow in Step 3. You must always begin with
the high-order bits (the bits starting on the left of a binary number). Using the number of
bits you can work with and the number of bits you must borrow (from Step 3), your result
is the following: 11100000. In other words, from the eight total bits from Step 2 (six of
which you could borrow), you borrow three host ID bits. In Step 4, you also need to
determine the decimal value of the octets from which you borrow host ID bits. In this
example, 11100000 equals 224. (128 + 64 + 32 = 224)

Step 5: Determining New Subnet Mask

Step 5 calculates the new subnet mask after you borrow the host ID bits in Step 4. You
must add the decimal value from Step 4 to the default subnet mask for the class of
address you are subnetting. The example is a Class C address, so the default mask is
255.255.255.0. The new mask after borrowing three bits becomes 255.255.255.224.

Step 6: Finding Host/Subnet Variable

In Step 6, you must find the lowest of the high-order bits (bits starting from the left)
turned ―on.‖ Step 6 takes you all the way back to earlier in the chapter to the values found
in each bit position within the octet. Our example defines the octets from which we
borrow as 11100000. The highest order bit turned on represents 2
5
, which equals 32.
Since 2
5
is the last high-order bit turned on, the Host/Subnet variable you use in Step 7 is
32.

Step 7: Determining Range of Addresses
The final step allows you to take the Host/Subnet variable from Step 6 (32) and create
your subnet ranges. Using the Class C network above, the range of subnets when you
borrow three bits are:
211.212.10.0 to 211.212.10.31
211.212.10.32 to 211.212.10.63
211.212.10.64 to 211.212.10.95
211.212.10.96 to 211.212.10.127
211.212.10.128 to 211.212.10.159
211.212.10.160 to 211.212.10.191
211.212.10.192 to 211.212.10.223
211.212.10.224 to 211.212.10.255

IP addresses cannot be all ones or all zeros; therefore, in most cases the first range of
addresses and the last range of addresses are unusable. (In some special circumstances,
you can use the first range of addresses, or subnet 0. Only certain manufacturers’
equipment, such as Cisco Systems, fully supports the use of subnet zero.) In each subnet,
the first IP address is unusable because it represents the subnet ID. The final address is

106
also unusable because it is the broadcast address for the subnet. Due to these two
restrictions, in subnet one, 211.212.10.33 is the first useable host ID and 211.212.10.62 is
the last useable host ID.

Tailoring a Class B Address

This example takes a Class B address and tries to fit it within the needs of a network
containing 1000 subnets. You are assigned the Class B address 131.107.0.0. Using the
following seven steps, you are going to subnet the Class B address to meet your needs.

Step 1: Determining Number of Subnets Needed

Examine your network and determine your needs based on current network configuration
and future growth (in this case, 1000 subnets).

Step 2: Determining Number of Bits You Can Borrow

With this Class B network address, you have 16 total bits to work with. You can only
borrow up to 14 of these. On your sheet of paper, you should write the number of bits you
have in the host ID portion of the address:
00000000.00000000

107
Step 3: Determining Number of Bits You Must Borrow to Get Number of Subsets
Needed
Using the formula 2
n
-2= # of usable subnets, you can easily see that you need to borrow
10 bits. When you plug in 10 borrowed bits, you get the following result:
2
10
= 1024 – 2 = 1022 useable subnets

Step 4: Turning on Borrowed Bits and Determining Decimal Value

If you turn on 10 bits, you get the following:
11111111.11000000
The decimal values for the octets are 255.192.

Step 5: Determining New Subnet Mask

Your example is a Class B address. In Class B addresses, the default subnet mask is
255.255.0.0. To get your new mask, you add the default mask to the decimal values
found in Step 4. The new mask becomes:
255.255.255.192

Step 6: Finding Host/Subnet Variable

In the next-to-last step, you must find the value of the lowest high-order bit turned on in
each octet, from which you borrowed host bits. Since this example is a Class B network
and you must borrow a great number of bits to get the proper number of subnets, the
borrowing crosses an octet boundary. As a result, you have two Host/Subnet variables. In
this example, the variable in the third octet is 1, and the variable for the fourth octet is 64.
You get these values by looking at the binary numbers in Step 4. The third octet has the
final bit position, or the 2
0
bit position, turned on. Since 2
0
= 1, your variable is 1 in the
third octet. In the fourth octet, the second high-order bit or 2
6
is turned on. The variable in
this octet is 64.

108
Step 7: Determining Range of Addresses
Figuring the range of addresses for Class B networks is much harder than for Class C.
This is especially true in cases like this scenario in which you must borrow a large
number of bits. Using 1 as the variable in the third octet and 64 as the variable in the
fourth octet, the range of the first 9 subnets world be:

131.107.0.0 to 131.107.0.63
131.107.0.64 to 131.107.0.127
131.107.0.128 to 131.107.0.191
131.107.0.192 to 131.107.0.255
131.107.1.0 to 131.107.1.63
131.107.1.64. to 131.107.1.127
131.107.1.128 to 131.107.1.191
131.107.1.192 to 131.107.1.255
131.107.2.0 to 131.107.2.63