• Tidak ada hasil yang ditemukan

Network Layer (Part IV)

N/A
N/A
Protected

Academic year: 2018

Membagikan "Network Layer (Part IV)"

Copied!
42
0
0

Teks penuh

(1)
(2)

Overview

A router is a type of internetworking

device that passes data packets between

networks based on Layer 3 addresses.

A router has the ability to make

intelligent decisions regarding the best

path for delivery of data on the network.

In this chapter, you will learn how routers

(3)

Overview

In addition, you will learn how devices on local-area

networks (LANs) use Address Resolution Protocol

(ARP) before forwarding data to a destination.

You will learn what happens when a device on one

network does not know the MAC address of a device

on another network.

You will learn that Reverse Address Resolution

Protocol (RARP) is the protocol a device uses when

it does not know its own IP address.

Lastly, you will learn the diference between routing

and routed protocols and how routers track distance

between locations.

(4)

Layer 3 Devices

: Routers

In networking, there are two addressing schemes:

one uses the MAC address, a data link (Layer 2)

address; the other uses an address located at the

network layer (Layer 3) of the OSI model.

An example of a Layer 3 address is an IP address.

A router is a type of internetworking device that

passes data packets between networks, based on

Layer 3 addresses.

(5)
(6)
(7)

Layer 3 Devices

: Layer 3

addresses

Bridges and switches use physical, or MAC

addresses, to make data forwarding decisions.

(8)

Layer 3 Devices

: Layer 3

addresses

Physical, or MAC addresses, are usually assigned by

the NIC manufacturer and are hard-coded into the

NIC.

The network administrator usually assigns IP

addresses.

In fact, it is not unusual for a network administrator

to group devices together in the IP addressing

scheme, according to their geographical location,

department, or foor within a building.

Because they are implemented in software, IP

addresses are fairly easy to change.

Finally, bridges and switches are primarily used to

connect segments of a network.

(9)
(10)
(11)

Layer 3 Devices

: Unique

network numbers

Routers connect two or more

networks, each of which must have a

unique network number in order for

routing to be successful.

(12)
(13)

Layer 3 Devices

: Unique

network numbers

Example:

Another network, with a unique

network number - B - has four

devices attached to it. This network

is also attached to the same router,

but at a diferent interface. The IP

addresses of the devices on this

second network are B1, B2, B3, and

B4. The IP address of the router's

(14)

Layer 3 Devices

: Unique

network numbers

Example:

You want to send data from one network to another. The source network is A; the destination network is B; and a router is connected to networks A, B, C, and D. When data (frames), coming from network A, reaches the router, the router performs the following functions:

– It strips of the data link header, carried by the frame. (The

data link header contains the MAC addresses of the source and destination.)

– It examines the network layer address to determine the destination network.

– It consults its routing tables to determine which of its interfaces it will use to send the data, in order for it to reach its

(15)

Layer 3 Devices

: Unique

network numbers

(16)
(17)
(18)
(19)

Layer 3 Devices :

Router

interface/port

A router’s attachment to a network is

called an interface; it may also be

referred to as a port.

(20)
(21)

Network-to-Network Communications :

Methods for assigning an IP address

After you have determined the addressing

scheme for a network, you must choose

the method for assigning addresses to

hosts.

There are essentially two methods for

assigning IP addresses -

static addressing

and

dynamic addressing

.

(22)

Network-to-Network Communications :

Methods for assigning an IP address

Static Addressing

If you assign IP addresses statically, you must go to each individual device and confgure it with an IP address.

• This method requires you to keep very meticulous records, because problems can occur on the network if you use

duplicate IP addresses.

• Some operating systems, such as Windows 95 and

Windows NT, send an ARP request to check for a duplicate IP address when they attempt to initialize TCP/IP.

• If they discover a duplicate, the operating systems will not initialize TCP/IP and will generate an error message.

(23)

Network-to-Network Communications :

Methods for assigning an IP address

Dynamic

Addressing

There are a few diferent methods that you can use to

assign IP addresses dynamically. Examples of these

are:

Reverse Address Resolution Protocol (RARP)

(24)

Network-to-Network Communications :

Methods for assigning an IP address

Let's look at an example where a source device wants to

send data to another device.

In our example the source knows its own MAC address,

but is unable to locate its own IP address in its ARP table.

In order for the destination device to retrieve the data,

pass it to higher layers of the OSI model, and respond to the originating device, the source must include both its MAC address and IP address.

Therefore, the source initiates a process called a RARP

(25)

Network-to-Network Communications :

Methods for assigning an IP address

RARP uses the same packet format as ARP. But in a

RARP request, the MAC headers, IP headers, and

"operation code" are diferent from an ARP request.

The RARP packet format contains places for MAC

addresses of both destination and source.

The source IP address feld is empty. The broadcast

goes to all devices on the network; therefore the

destination IP address will be set to all binary 1s.

Workstations running RARP have codes in ROM that

(26)

Network-to-Network Communications :

Methods for assigning an IP address

BOOTstrap Protocol (BOOTP)

A device uses

BOOTstrap protocol

(BOOTP)

when

it starts up, to obtain an IP address.

BOOTP uses UDP to carry messages; the UDP

message is encapsulated in an IP datagram.

A computer uses BOOTP to send a broadcast IP

datagram (using a destination IP address of all

1s - 255.255.255.255).

A BOOTP server receives the broadcast and then

(27)

Network-to-Network Communications :

Methods for assigning an IP address

If it fnds its own MAC address in the destination address

feld, then it takes the IP address in that datagram.

Like RARP, BOOTP operates in a client-server

environment, and only requires a single packet exchange.

However, unlike RARP, which only sends back a 4 octet IP

address, BOOTP datagrams can include the IP address, the address of a router (default gateway), the address of a server, and a vendor-specifc feld.

One of the problems with BOOTP is that it was not

designed to provide dynamic address assignment.

With BOOTP you create a confguration fle that specifes

(28)

Network-to-Network Communications :

Methods for assigning an IP address

Dynamic Host Confguration Protocol (DHCP)

Dynamic host confguration protocol (DHCP) has been proposed as a successor to BOOTP.

Unlike BOOTP, DHCP allows a host to obtain an IP address

quickly and dynamically.

All that is required using DHCP is a defned range of IP

addresses on a DHCP server. As hosts come online they contact the DHCP server and request an address.

The DHCP server chooses an address and allocates it to

that host.

With DHCP, the entire computer’s confguration can be

(29)
(30)
(31)

Network-to-Network Communications :

DHCP initialization sequence

When a DHCP client boots, it enters an

initialize

state

. It sends

DHCPDISCOVER

broadcast

messages, which are UDP packets with the port

number set to the BOOTP port.

After sending the DHCPDISCOVER packets, the

client moves into the

select state

and collects

DHCPOFFER

responses from DHCP server. 

The client then selects the frst response it

receives and negotiates lease time (the length of

time it can keep the address without renewing it)

with

the

DHCP

server

by

sending

a

DHCPREQUEST packet.

The DHCP server acknowledges a client request

with

a DHCPACK

packet.

The client can now enter the

bound state

and

(32)
(33)

Network-to-Network

Communications :

IP key components

In order for devices to communicate, the sending

devices need both, the IP addresses and the

MAC addresses, of the destination devices.

When they try to communicate with devices

whose IP addresses they know, they must

determine the MAC addresses.

The TCP/IP suite has a protocol, called ARP, that

can automatically obtain the MAC address.

ARP enables a computer to fnd the MAC address

(34)

Network-to-Network Communications :

A packet is divided into two major components:

the header, which includes source and

destination addresses; and the data.

Other types of protocols have their own

(35)

Network-to-Network Communications :

IP key components

Note:

Another major component of IP is

Internet

Control Message Protocol (ICMP)

.

This protocol is used by a device to report a

problem to the sender of a message.

For example, if a router receives a packet that it

cannot deliver, it sends a message back to the

sender of the packet.

(36)
(37)

Network-to-Network Communications : Function

of the address resolution protocol (ARP)

Layer 3 protocols determine whether data passes

beyond the network layer to higher levels of the OSI

model.

A data packet must contain both, a destination MAC

address and a destination IP address.

If it lacks one or the other, the data will not pass from

Layer 3 to the upper layers.

In this way, MAC addresses and IP addresses act as

checks and balances for each other.

After devices determine the IP addresses of the

(38)

Network-to-Network Communications : Function

of the address resolution protocol (ARP)

There are a variety of ways that devices can

determine the MAC addresses they need to

add to the encapsulated data.

Some keep tables that contain all the MAC

addresses and IP addresses of other devices

that are connected to the same LAN.

They are called

Address Resolution Protocol

(

ARP)

tables

, and they map IP addresses to

(39)

Network-to-Network Communications : Function

of the address resolution protocol (ARP)

ARP tables are sections of RAM memory, in

which the cached memory is maintained

automatically on each of the devices.

(40)

Network-to-Network Communications : Function

of the address resolution protocol (ARP)

When a source determines the IP address for a

destination, the source consults its ARP table in

order to locate the MAC address for the

destination.

If the source locates an entry in its table

(41)
(42)

Referensi

Dokumen terkait

ABSTRAK: Telah dilakukan pengembangan insrumen untuk pengukuran kepuasan pasien terhadap pelayanan kefarmasian yang diberikan oleh suatu rumah sakit.. Instrumen terdiri atas

Sebagai bagian dari rangkaian acara KSAN 2015, Pokja AMPL menggelar berbagai program public engagement untuk semakin menyebarluaskan misi masa depan sanitasi dan air minum di

2.000.000.000 ,- (Dua Milyar Rupiah) Tahun Anggaran 2017, maka dengan ini diumumkan bahwa Pemenang E-lelang Pemilihan Langsung pekerjaan tersebut di atas adalah

Buku ini merupakan pedoman bagi Badan Akreditasi Nasional Perguruan Tinggi (BAN-PT), termasuk kedua organ utamanya, yaitu Majelis Akreditasi (MA) yang bertugas dan berwenang

Perusahaan yang memenuhi persyaratan dan lulus pembuktian kualifikasi terdiri dari 4 (empat) Perusahaan..

Dengan ini diberitahukan bahwa setelah diadakan penelitian secara seksama mengenai Surat Penawaran beserta kelengkapan Dokumen penawaran menurut ketentuan-ketentuan

Pada hari ini, hari Senin, tanggal enam, bulan Oktober, tahun Dua ribu empat belas setelah diadakan penjelasan pekerjaan tersebut di atas, di dalam

Tutor menjelaskan operasi-operasi himpunan serta cara-cara menggambarkan himpunan dengan menggunakan diagram venn, kemudian memberikan contoh soal aplikasi himpunan dalam masalah