You are on page 1of 120

IP Network Fundamental

www.huawei.com

T
HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Network is more and more important in


modern times. This course will introduce
data traffic and basic knowledge of IP
network.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 2

Upon completion of this course, you will be


able to:
Know basic concepts of data traffic
Know basic knowledge of network
and internet
Know familiar standardization
organization
Enterprise Applications in reality

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 3

Chapter 1 Data Traffic Basis


Chapter 2 Brief Introduction of Network and

Internet
Chapter 3 Protocol and Standard
Chapter 4 Enterprise Applications in reality

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 4

Data and Data Traffic

Data
Data means the information expressed by any format. The
format should be negotiated ahead by information creator and
receiver.

Data Traffic
The process of data exchange between two devices via
transfer medium such as line.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 5

Composing of Data Traffic System


The first step:
The second step:
The third step:

The first step:


The second step:
The third step:

Protocol

Protocol
Message
Medium

Sender

HUAWEI TECHNOLOGIES CO., LTD..

Receiver

All rights reserved

Page 6

Data Flow Direction


Data direction
simplex
mode
Host

Display
Data direction at time 1

half-duplex
mode

Data direction at time 2

Workstation

Workstation

Data direction at whole time


full-duplex
mode
Workstation

HUAWEI TECHNOLOGIES CO., LTD..

Workstation

All rights reserved

Page 7

Chapter 1 Data Traffic Basis


Chapter 2 Brief Introduction of Network and

Internet
Chapter 3 Protocol and Standard
Chapter 4 Enterprise Applications in reality

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 8

Computer Network

SOHO

Intranet
Server

IP Hotel

HUAWEI TECHNOLOGIES CO., LTD..

Mobile
network
All rights reserved

Page 9

Evolution of Network
WAN
Intra-network
interconnection
1980s

Network based
Connections
1970s 1980s

Host

Host
Simple Connections
1960s 1970s

Low speed lines

Host Network
HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 10

Common Network Topologies

Bus

Star

Mesh

Ring

HUAWEI TECHNOLOGIES CO., LTD..

Tree

All rights reserved

Page 11

Composing of Internet

LAN
LAN

LAN

LAN

LAN
WAN

WAN

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 12

LAN Characteristics and Common Equipment

Short

distance

Low

delay

High

bandwidth

Reliable

HUB

Switch

transmission

Router

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

ATM Switch

Page 13

Types of WAN

ISDN: Integrated Services Digital Network


DDN: Digital Data Network
X.25 Public Packet Switched Network
Frame Relay
ATM: Asynchronous Transfer Mode

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 14

Commonly-Used Equipment in WAN

Modem

Router

Wan Switch

HUAWEI TECHNOLOGIES CO., LTD..

Access Server

All rights reserved

Page 15

The Development History of Internet

ARPAnet was launched into running in 1969. It comes of America DARPA (Defence
Advanced Research Projects Agency), ARPAnet is the sign of the naissance of
modern computer network.

ARPAnet was divided into two parts in 1983:ARPAnet and MILNET for military
affairs.

America NSF (National Science Foundation) founded NSFnet in 1985.

NSFnet quite replaced ARPAnet in June 1990 and became the backbone network of
Internet.

Merit, IBM and MCI founded a non-payoff organizationANS (Advanced Network


&Science Inc.) in September 1990, the objective of ANS is to found a T3 backbone
network that covers with whole American, it is able to transmit data as the speed of
45Mbps.

At the end of 1991, all the backbone network of NSFnet connected with T3 backbone
network of ANS.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 16

Actuality of Internet
ISP

ISP

Area ISP

ISP

ISP

Area ISP

International or nation ISP

ISP

Area ISP

ISP

ISP

Area ISP

NAP

International or nation ISP

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 17

ISP

Chapter 1 Data Traffic Basis


Chapter 2 Brief Introduction of Network and

Internet
Chapter 3 Protocol and Standard
Chapter 4 Enterprise Applications in reality

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 18

Rule of Network World


Network

Standard
Protocol
Network

HUAWEI TECHNOLOGIES CO., LTD..

Network

All rights reserved

Page 19

Standard

Data traffic standard divides into two types: de facto and de jure
de facto standard: not admitted by organization but commonly
used and acceptable
de jure standard: the standard established by organization
which approbated by government

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 20

Standardization Organization

International Organization for Standardization (ISO)

Institute of Electrical and Electronics Engineers (IEEE)

American National Standards Institute (ANSI)

Electronic Industries Association/Telecomm Industries


Association (EIA / TIA)

International Telecomm Union (ITU)

Internet Engineering Task Force (IETF)

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 21

Standardization OrganizationTypes of IETF


Standard

IETF creates two types of documents, one is Internet Draft,


and the other is RFC.
Any one can refer Draft, no any special limit, and other
member can take a indifferent attitude, but many important
documents of IETF begin with Draft
RFC is more official, and it would be kept in the archives in
the history. Generally, if it is sanctioned to come on, the
contents will not be changed.
RFC (Request For Comments)

It almost includes all the important documents of


internet

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 22

Chapter 1 Data Traffic Basis


Chapter 2 Brief Introduction of Network and

Internet
Chapter 3 Protocol and Standard
Chapter 4 Enterprise Applications in reality

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 23

Case of Typical Enterprise Applications in reality


Site-1

Server Farm

DHCP Server
Radius Server

SNMP Server
SW 23

DMZ

SW 33
SW 33

Web Server
SW 53

SW 53

AR 49

InterNet

AR 49

HeadQuarter
Serial Link
(V.35)

EtherNet
(RJ45)

FW Eudemon 200E

EtherNet
(RJ45)

IPsec VPN

Lease Line
HDLC/PPP/FR/ATM/E1
Traditional telecom network

MPLS VPN
(L3 /L2 VPN)
Modern telecom
network

Metro Ethernet
Access network

InterNet

3G / xDSL

Branch-A

Serial Link
(V.35)
AR 29

EtherNet
(RJ45)

IPsec VPN
Embedded WiFi

AR 29
3G link or xDSL

SW 33
SW 23

AR 19
AP (WIFI)
SW 23

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 24

Branch-B

TCP/IP Basis

www.huawei.com

T
HUAWEI TECHNOLOGIES CO., LTD.

All rights reserved

The communication is realized via


TCP/IP protocol stack between The
computers with different model, different
manufacturer and different OS. This
course will introduce the architecture of
TCP/IP protocol stack, the function of
each layer and data encapsulation.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 26

Upon completion of this course, you will be


able to :
Know architecture of OSI RM
Master architecture TCP/IP and
the function of each layer
Understand the process of TCP/IP
data encapsulation

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 27

Chapter 1 TCP/IP Protocol Stack


Chapter 2 Data Encapsulation of
TCP/IP Protocol Stack
Chapter 3 Case analysis

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 28

OSI Reference Model

OSI RM: Open System Interconnection Reference Model

OSI RM has the following advantages


To predigest pertinent network operation
To provide compatibility and standard interface between devices
To accelerate standardization working
Structure is separable
Easy to realize and maintenance

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 29

OSI Reference Model

Application layer

Presentation layer

Session layer

Transport layer

Network layer

Data link layer

Physical layer

HUAWEI TECHNOLOGIES CO., LTD..

High Layers: In charge of data


transmission between hosts.

Low Layers: In charge of data


transmission in network.

All rights reserved

Page 30

Functions of the Seven Layers

Application layer

Presentation layer

Provide communications
between applications

Deal with data format problems

Session layer

Transport layer

Network layer

Addressing and routing

Data link layer

Provide link medium access


and link management

Physical layer

Bit flow transmission

HUAWEI TECHNOLOGIES CO., LTD..

Establish, maintain and manage sessions

Establish, maintain and


manage end to end connection

All rights reserved

Page 31

TCP/IP model
OSI
7

Application layer

Presentation layer

TCP/IP

VS

Application layer

Session layer

Transport layer

Transport layer

Network layer

Network layer

Data link layer

Data link layer

Physical layer

Physical layer

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 32

TCP/IP Protocol Stack

Application layer

HTTP, Telnet, FTP


TFTP, Ping

Transport layer

TCP/UDP

Network layer

IP

Data link layer

Ethernet, 802.3, PPP

Physical layer

Interfaces, wires

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Provide application program


network interfaces

Establish terminal to
terminal connection
Addressing and
route selecting
Physical media access
Binary data flow transmission

Page 33

Communication between Layers of TCP/IP


Model and Data Encapsulation
Host A

PDU

Upper layer
data

Application
layer

TCP header

Upper layer
data

Transport layer Segment

IP header

Upper layer
data

Network layer

Packet

Data link layer

Frame

Physical layer

Bit

LLC header Upper layer FCS


data
MAC header Upper layer FCS
data

0101110101001000010

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 34

Data De-encapsulation

Host B
Application
layer
Transport
layer
Network
layer

Upper layer data


Upper layer data

TCP+ upper layer data


IP+TCP+ upper layer data

Data link
layer
Physical
layer

HUAWEI TECHNOLOGIES CO., LTD..

LLC header+ IP+TCP+ upper layer data


0101110101001000010

All rights reserved

Page 35

The Function of Physical Layer


Define medium type, interface type, sign type

criterion of requirement for electric, engine, flow and function


when physical link is activation, maintenance and shutdown

between the terminal system.

Criterion of character such as voltages, data rate, maximum


transmission distance and physical connector.
LAN
Physical
(Bits,
signals,
clocking)

8
0
2
.
3

8
0
2
.
4

HUAWEI TECHNOLOGIES CO., LTD..

8
0
2
.
5

WAN
F
D
D
I

V.24
V.35

All rights reserved

G.703
EIA/TIA-232

Page 36

Physical layer medium and device


Physical layer medium

Coaxial cable
Twisted-pair
Fiber
Wireless radio

Physical layer device


Repeaters, HUB

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 37

The Function of Data Link Layer

MAC Sub-layer : Media Access Control Sub-Layer


Appoint that how to transmit data packet via physical line and
communicate with physical layer

LLC Sub-layer: Logic Link Control Sub-layer


Distinguish protocol types, encapsulate the data and transmit via
network
Application layer
Transport layer

Network layer
Data link layer

LLC sub-layer

Physical layer

MAC sub-layer

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 38

Protocols of Data Link Layer


Data link layer LAN, WAN protocol

LAN

WAN

802.2 LLC

Data Link
(Frames)

Physical
(Bits,
signals,
clocking)

8
0
2
.
3

8
0
2
.
4

8
0
2
.
5

F
D
D
I

Dial
on
Demand

SDLC

HDLC

V.24
V.35

G.703
EIA/TIA-232

Data link layer device

Ethernet switch
HUAWEI TECHNOLOGIES CO., LTD..

Frame
Relay

All rights reserved

Page 39

PPP

Data Link Layer Address


MAC address is composed of 48 bits. The vendor ID of Huawei

products is 0x00e0fc.

24 bits

24 bits

Vender Code Serial Number

00e0.fc01.2345
00e0.fc01.2345
Rom
Ram

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 40

The Function and Device of Network Layer


Function

Data forwarding in the different networkDevice


Router, layer 3 swtich

D
Host A

Host B

A
B

Application layer

Router A

Router B

Router C

Network layer

Network layer

Network layer

Network layer

Data link layer

Data link layer

Data link layer

Data link layer

Physical layer

Physical layer

Physical layer

Physical layer

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 41

Transport layer

Protocols of Network Layer


Protocols of Network layer

Network
(Packets)

IP/ICMP/ARP/RARP

802.2 LLC

Dial
on
Demand

Data Link
(Frames)
Physical
(Bits,
signals,
clocking)

8
0
2
.
3

8
0
2
.
4

HUAWEI TECHNOLOGIES CO., LTD..

8
0
2
.
5

F
D
D
I

SDLC

HDLC

Frame
Relay

V.24
G.703
V.35

All rights reserved

EIA/TIA-232

Page 42

PPP

Network Address
Network address identifies a device in the network layer

uniquely

Network address include two parts

Network ID
Host ID
Network ID

Host ID

10.

8.2.48

IP Address

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 43

The Function of Transport Layer

Segment upper layer data

Set up end to end connection

Transmit data from end to end

ensure the reliability of the data


transmission

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 44

Protocols of Transport Layer

Transport
(Segments)

TCP

UDP

Network
(Packets)

IP

802.2 LLC

Dial
on
Demand

Data Link
(Frames)
Physical
(Bits,
signals,
clocking)

8
0
2
.
3

8
0
2
.
4

HUAWEI TECHNOLOGIES CO., LTD..

8
0
2
.
5

F
D
D
I

SDLC

HDLC

Frame
Relay

V.24
G.703
V.35

All rights reserved

EIA/TIA-232

Page 45

PPP

Main Protocols of Transport Layer

UDP

TCP
Connection-oriented

Connectionless

Reliable

Trustless

Suit the application with

Suit the application that

high reliability

concerns transmission

High cost

efficiency
Reliability depends on
application

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 46

The Function of Application Layer

Provide user interfaces and deal with specify applications

Provide data encryption, decryption, compression


and decompression.

Specify the standards of data presentation.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 47

Protocols of Application Layer


Application
(Data)

FTP TELNET HTTP


SMTP/POP3 DNS

Transport
(Segments)

TFTP SNMP RIP DNS Radius

TCP

UDP

Network
(Packets)

Data Link
(Frames)
Physical
(Bits,
signals,
clocking)

IP

802.2 LLC
8
0
2
.
3

8
0
2
.
4

HUAWEI TECHNOLOGIES CO., LTD..

8
0
2
.
5

F
D
D
I

Dial
on
Demand

SDLC

HDLC

Frame
Relay

V.24
V.35

All rights reserved

G.703

Page 48

EIA/TIA-232

PPP

Chapter 1 Internet Connection of

TCP/IP
Chapter 2 Data Encapsulation of
TCP/IP Protocol Stack
Chapter 3 Case Analysis

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 49

The Encapsulation Process of TCP/IP Protocol


Stack
user data

Application
App header

User data

TCP
TCP Segment

TCP header

User data

IP Packet

IP header

TCP header

User data

Ethernet header

IP header

TCP header

user data

20-64B

20-60B

14B

IP

Ethernet trailer
4B

Ethernet Frame
46-1500 bytes

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 50

Application drive

TCP Segment
Ethernet Frame

Ethernet header

14B

Source
Port

16b

IP header

TCP header

User data

Ethernet trailer

20-60B 20B-60B

Dest.
Port

16b

HUAWEI TECHNOLOGIES CO., LTD..

Seq Num

32b

4B

Ack Num

32b

All rights reserved

...

64b

Page 51

Option

IP Packet
Ethernet header

14B

IP header

TCP header

User data

20-60B 20B-60B

4B

0
15 16
version Message Service type
length
identification
Flag
Fixed
message
header

Ethernet trailer

Time to live

protocol

31
Total length
Chip offset

Message header checksum


20 B

Source IP address

Destination IP address
IP options

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 52

Issue of IP Fragment
Fragment principle: comparing with data length and MTU, if the former is

larger than the latter, fragment is needed.

IP
packet
Host

Host

MTU

MTU

Fragment on sending end


Fragment on the middle routers

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 53

Ethernet Frame

Ethernet header

14B

DMAC

6B

IP header

TCP header

User data

Ethernet trailer

20-60B 20B-60B

SMAC

L/T

6B

2B

4B

Length/Type value
Ethernet_II

802.3

HUAWEI TECHNOLOGIES CO., LTD..

Length/T > 1500

Length/T <= 1500

All rights reserved

meaning
Represents Type

Represents Length

Page 54

Chapter 1 Internet Connection of


TCP/IP

Chapter 2 Data Encapsulation in


TCP/IP Protocol Stack

Chapter 3 Case Analysis

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 55

Case Analysis (1)

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 56

Case Analysis (2)

Source
MAC

Destination
MAC

Type

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 57

Case Analysis (3)


Destination
IP

Source IP

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 58

Case Analysis (4)


Source port

Destination port

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 59

Summary

What layers does OSI RM divide into?

Whats the function of each layer of TCP/IP protocol stack?

whats the process of message encapsulation and de-encapsulation


in TCP/IP protocol stack?

Whats the difference between MAC address and IP address?

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 60

Transport Layer of TCP/IP


T
www.huawei.com

HUAWEI TECHNOLOGIES CO., LTD.

All rights reserved

Transport layer locates the forth layer of


TCP/IP, provide service for application.
Transport layer defines the end to end
communication between the applications
on hosts.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 62

Upon completion of this course, you will be


able to
Master principle of TCP and UDP
protocol
Understand the difference between
TCP and UDP

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 63

Chapter 1 TCP

Chapter 2 UDP

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 64

Overview of TCP Protocol

TCP provides connection-oriented and reliable service for applications.

Reliability of TCP

Connection-oriented transmission
Maximum segment size
Acknowledgement mechanism of transmission
Checksum of header and data
Flow control

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 65

Format of TCP Header


TCP data segment

IP Head

TCP Head

TCP Data

15 16
16 bits source port

31
16 bits destination port

32 bits sequence number


20

32 bits acknowledge number

bytes
Header
length

reserve

U A P R S F
R C S S Y I
G K H T N N

16 bits checksum

16 bits windows size

16 bits urgent pointer

option
data

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 66

Establishment of TCP Connection

Client

HUAWEI TECHNOLOGIES CO., LTD..

Server

All rights reserved

Page 67

Termination of TCP Connection

Client

HUAWEI TECHNOLOGIES CO., LTD..

Server

All rights reserved

Page 68

End to End Communication


Transmission virtual circuit

WWW.HUAWEI.COM

Host

FTP.HUAWEI.COM

Application data
Transmission
data packet

Data

Data
21

FTP

1028
Port

HUAWEI TECHNOLOGIES CO., LTD..

Data

80

1027

HTTP
All rights reserved

Data

Port

Page 69

MSS
Host A

Host B

Host AMSS

Host BMSS

When it is going to establish connection, the two hosts need to


negotiate about MSS.

The default value of MSS is 536so allowable length of IP


data message is 576 bytes.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 70

Windowing MechanismAcknowledgement
Technology
Transmission virtual circuit

source

destination

Host

Host

Send 1,2,3

Acknowledge 4
Send 4,5,6

Acknowledge 4
Send 4,5,6

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 71

Slide windows

To modify the
windows size

HUAWEI TECHNOLOGIES CO., LTD..

The sender
is too fast!

All rights reserved

Page 72

Chapter 1 TCP
Chapter 2 UDP

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 73

Overview of UDP Protocol

UDP provide connectionless-oriented service for application. It


neednt to establish connection between source site and

destination site before data transmission.

It neednt to maintain the state of connection, receiving and


sending, so the server can send same message to some clients at
one time.

UDP is suitable for the application with requirement of high

transmission efficiency.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 74

Format of UDP Header

UDP Head

0
8bytes

UDP Data

15 16
31
16 bits source port 16 bits destination
port
16 bits UDP length

16 bits UDP
checksum

data

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 75

TCP VS UDP

TCP

UDP

connection

Connection-oriented

Connectionlessoriented

reliability

reliable

unreliable

Application
situation

Transmission of a
mass of data

High transmission
efficiency

rate

slow

fast

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 76

Summary

How does TCP establish and terminate


connection?

How does TCP provide reliability?

Whats the purpose of TCP slide


windows technology?

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 77

Introduction to Common
Application
T

www.huawei.com

HUAWEI TECHNOLOGIES CO., LTD.

All rights reserved

Application layer is used to operate


specified application. This course
describes the universal application via
instance such as Ping, Tracert, Telnet,
FTP, TFTP.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 79

Upon completion of this course, you will be


able to :
Mast the function of some common
applications and usage method

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 80

Chapter 1 Common Application

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 81

PING
1.1.1.1

1.1.1.2

ICMP Echo
ICMP Echo Reply

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 82

ICMP
Internet Control Message Protocol (ICMP) is a part of network

layer. It transfers the information such as error, control and query.

ICMP message is often used by IP or protocols of higher layer (TCP


or
UDP), such as Ping.

IP Header

ICMP Message

20 Bytes

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 83

ICMP Message

78

Type

15 16

Code

31

Checksum

Contents depends on type and code

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 84

Common Used Message Types of ICMP

0 Echo Reply

3 Destination Unreachable

5 Redirect

8 Echo

11 Time Exceeded

12 Parameter Problem

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 85

Tracert
Tracert is used to observe the route that the IP data message

transmitted from one host to another host.

Traceroute makes use of ICMP message and TTL filed in the IP


header (time to live).
ICMP port
Unreachable message
n

ICMP time exceeded message


1
Source site

IP Network
1

Destination site

UDP data message TTL = 1


2

UDP data message TTL = 2

n
UDP data message TTLn

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 86

Case Analysis
RTA

RTB
10.1.1.0/30
.1

.2

RTC
10.2.2.0/30
.1

3.3.3.3/32
.2

[Quidway]ping 3.3.3.3
PING 3.3.3.3: 56 data bytes, press CTRL_C to break
Reply from 3.3.3.3: bytes=56 Sequence=1 ttl=254 time=63 ms
Reply from 3.3.3.3: bytes=56 Sequence=2 ttl=254 time=63 ms
Reply from 3.3.3.3: bytes=56 Sequence=3 ttl=254 time=63 ms
Reply from 3.3.3.3: bytes=56 Sequence=4 ttl=254 time=63 ms
Reply from 3.3.3.3: bytes=56 Sequence=5 ttl=254 time=63 ms

[RTA]tracert 3.3.3.3
traceroute to 3.3.3.3(3.3.3.3) 30 hops max,40 bytes packet
1 10.1.1.2 31 ms 31 ms 32 ms
2 10.2.2.2 62 ms 63 ms 62 ms

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 87

Application of Telnet

Telnet provides a method to login the long-distance server via


connective terminal.

Telnet uses TCP as its transport layer protocol, the port number is
23.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 88

FTPServer
1.1.1.1

FTP client

HUAWEI TECHNOLOGIES CO., LTD..

FTP Server

All rights reserved

Page 89

FTPClient
1.1.1.2

FTP Server

HUAWEI TECHNOLOGIES CO., LTD..

FTP client

All rights reserved

Page 90

FTPClient (cont.)
1.1.1.2

FTP Server

HUAWEI TECHNOLOGIES CO., LTD..

FTP client

All rights reserved

Page 91

TFTPServer
1.1.1.2

TFTP Server

TFTP client

download switch.bin to router from TFTP server


<Quidway> tftp 1.1.1.2 get switch.bin switch.bin
Upload vrpcfg.cfg to TFTP server
<Quidway> tftp 1.1.1.2 put vrpcfg.cfg vrpcfg.cfg

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 92

Summary

What are the functions of Ping and


Tracert?

Format of ICMP message.

Whats the difference between


FTP and TFTP?

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 93

IP Addressing and
Routing
www.huawei.com

T
HUAWEI TECHNOLOGIES CO., LTD.

All rights reserved

Network layer locates the third layer of


TCP/IP protocol stack, between the
data link layer and transport layer.
Network layer defines some protocols to
ensure the right forwarding of data
packet.

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 95

Upon completion of this course, you will be


able to :
Master the classes of IP address
Subnet address planning in reason
Understand ARP/RARP protocol
principle
Know the working principle of router

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 96

Chapter 1 IP Address
Chapter 2 Protocols of Network Layer
Chapter 3 Working Principle of Router

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 97

Data Encapsulation and De-encapsulation

upper layer
data
TCP header upper layer
data
IP header

upper layer
data

LLC header upper layer FCS


data
MAC header upper layer FCS
data
0101110101001000010

Application
layer

Application
layer

upper layer data


upper layer data

Transport
layer

segment

Transport
layer

Network
layer

packet

Network
layer

Data link
layer

frame

Data link
layer

TCP+ upper layer data


IP+TCP+ upper layer data
LLC header +IP+TCP+ upper layer data

Physical
layer

HUAWEI TECHNOLOGIES CO., LTD..

bit

Physical
layer

All rights reserved

0101110101001000010

Page 98

Data Encapsulation on Network Layer

TCP Header

IP Header

IP Header

source
address
171.17.1.1

HUAWEI TECHNOLOGIES CO., LTD..

Upper layer
data

Upper layer
data

destination
address

Transport layer

Network layer

data

IP address

All rights reserved

Page 99

IP Address

IP address identifies a network device uniquely, it is made up


of 32 binary digit.

IP address is shown as dotted decimal format.

IP address is divided into two parts:


Network address portion
Host address portion
IP address

Network address

HUAWEI TECHNOLOGIES CO., LTD..

Host address

All rights reserved

Page 100

Classification of IP Address
Class A

1.0.0.0~126.255.255.255
0 Network(7bit)

Class B

Host(24bit)

128.0.0.0~191.255.255.255
1 0 Network(14bit)

Class C

Host(16bit)

192.0.0.0~223.255.255.255
1 1 0

Network(21bit)

Class D

224.0.0.0~239.255.255.255
1 1 1 0
Multicast address

Class E

240.0.0.0~255.255.255.255
1 1 1 1 0
reserve

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Host(8bit)

Page 101

Special IP Address

Network part

Host part

Address type

Any

all 0

Network
Address

Any

all 1

Broadcast
Address

127

Any

all 0

Usage
Representing a network
Segment
All the nodes of a Specially
designated network segment

Loopback
Address
All Networks

Loop test
As the designate default routes
in Huawei Quidway router

all 1

HUAWEI TECHNOLOGIES CO., LTD..

Broadcast
Address

All nodes of
Local network segment

All rights reserved

Page 102

Private IP Address

Private IP address
10.0.0.0~10.255.255.255
172.16.0.0~172.31.255.255
192.168.0.0~192.168.255.255

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 103

Subnet Mask Introduction

Distinguish between network part and host part by subnet mask

The subnet mask format is same as the IP address format

All of the network part and subnet part of subnet mask are 1, and all of

the host part are 0

For example Class Bs subnet


mask is 255.255.0.0

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 104

Network Address and Subnet Mask

IP Address

192.168.1

Subnet Mask

255.255.255

Network Address:

192.168.1

HUAWEI TECHNOLOGIES CO., LTD..

100

Page 105

System Conversion

8bit
Binary system

27

26

25

24

23

22

21

20

128

64

32

16

Decimal Summation is 255

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 106

Example of System Conversion

Example :

1*128

1*64

1*32

0*16

1*8

0*4

0*2

1*1

128

64

32

233

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 107

System Conversion of IP Address

IP address192.168.1.11(decimal)

byte8bits

byte8bits

byte8bits

byte8bits

2726252423222120 2726252423222120 2726252423222120 2726252423222120

11000000

10101000

00000001

00001011

192

168

11

binary digit11000000.10101000.00000001.00001011

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 108

Addressing without Subnet


Addressing without Subnet means using nature mask, no subdivision of

network segment. Class B segment 172.16.0.0 with mask 255.255.0.0

172.16.30.1/16

172.16.28.1/16

Et her net

172.16.30.10/16

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 109

Addressing with Subnets

Class B segment 172.16.0.0


172.16.4.1/24

Ethernet

Ethernet

172.16.8.1/24

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 110

Subnet Mask Representation


192 .

IP Address

168 .

11000000 10101000 00000001 00000111

Subnet mask

11111111

Bits of subnet mask

Subnet mask representation

HUAWEI TECHNOLOGIES CO., LTD..

255 . 255

. 255

11111111

11111111

. 240

11110000

8 + 8 + 8+ 4 = 28

192 . 168 . 1 . 7 / 28

All rights reserved

Page 111

Calculation of Network address


IP Address is: 192.168.1.7/28
192

IP Address

168

11000000 10101000 00000001 00000111

255

Subnet Mask

11111111

255

11111111

255 .

11111111

240

11110000

Network Address
11000000 10101000 00000001 00000000
(Binary)

Network Address

HUAWEI TECHNOLOGIES CO., LTD..

192.168.1.0/28

All rights reserved

Page 112

Calculation of Host Number


Subnet Mask

Network Portion

Host Portion

1 1 1 1 1 1 1 1 1 1 1 1 1 1 1

0 0 0 0 0 0 00 0 0 0 0 0 00

N bit

Host Number 2n
Valid Host Number : 2n - 2

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 113

Example of Host Number Calculation

IP Address192.168.1.100/28
/28=255.255.255.240

The binary representation of subnet mask:


11111111111111111111111111110000

28bits
network portion
The total number of host: 24

4bits
Host portion

The valid number of host: 24 -2

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 114

Example of Subnet Address Planning


examplea company gets class C address 201.222.5.0. if it needs

20 subnet and 5 host in each subnet. How to plan the IP address?

Subnet address

Usable host address

201.222.5.8/29

201.222.5.9~201.222.5.14

201.222.5.16/29

201.222.5.17~201.222.5.22

201.222.5.232/29

201.222.5.233~201.222.5.238

201.222.5.240/29

201.222.5.241~201.222.5.246

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 115

Example of Planning Class B

Subnet address
Host address

172.16.2.0
172.16.2.1172.16.2.254

Broadcast address

172.16.2.255

IP host address

172.16.2.120

Subnet mask

255.255.255.0

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 116

Example of Planning Class C

Subnet address

192.168.5.120

Host address

192.168.5.121-192.168.5.126

Broadcast address

192.168.5.127

IP host address

192.168.5.121

Subnet mask

255.255.255.248

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 117

Classless Inter-Domain Routing (VLSM)


192.168.1.32/27
192.168.1.160/30
192.168.1.64/27

ISP

announce
192.168.1.0

192.168.1.164/30

192.168.1.96/27
192.168.1.168/30

192.168.1.128/27
192.168.1.172/30

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 118

Classless Inter-Domain Routing (CIDR)


CIDR reduces scale of routing table and enhances network

extensibility.

198.168.1.0

Internet

Announce route
198.168.0.0/16

198.168.2.0

ISP
198.168.3.0

HUAWEI TECHNOLOGIES CO., LTD..

All rights reserved

Page 119

Thank You
www.huawei.com
T

You might also like