49
1 CSCI 233 Internet Protocols Class 2 Dave Roberts

1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Embed Size (px)

Citation preview

Page 1: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

1

CSCI 233Internet Protocols

Class 2

Dave Roberts

Page 2: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

More on Course Mechanics

• 50 word limit on homework answers and exam answers

• “Which is better?”--trick question! Usually there is no “better”, there are tradeoffs

2

Page 3: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

3

Good Citizen Principle

• In a crisis, when resources are short, we tend to hoard resources

• The hoarding creates shortages• What if, in a crisis, each of us

reduced our use of scarce resources?

• The Internet operates on the Good Citizen Principle

Page 4: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Good Citizen Principle

When a resource is scarce, instead of trying to claim as much of it as possible, reduce your use of that resource until the scarcity passes

4

This is an important Internet design principle.

We will see it again and again.

Page 5: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Important Internet Principles

1. Good Citizen Principle—when a resource is scarce, reduce your demand for it

5

Page 6: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

6

Tonight

• Review of networking technologies• Internetworking• Protocol Layering• Internet addresses

Page 7: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Early Ethernet

7

• Stiff wire, hard to bend

• Vampire connectors reduce performance

• Hard to change when offices are rearranged

Page 8: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Modern Ethernet

8

Page 9: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Ethernet Frame

9

Header Payload

Page 10: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Internetworking

• How to interconnect networks?– Application level

– Network Level• Users attach to a local network• Internetworking software hides details of

networks, forwards information among them 10

Page 11: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Internet Architecture

11

Page 12: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

The User’s View

12

ThisLooks Like This

Page 13: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Protocol Layering

• Internet protocols are organized into levels, called “layers”

• Each layer deals with certain topics

• Layers make protocols easier to understand

13

Page 14: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Just Think of Problems

• Hardware failure• Network congestion• Packet loss• Data corruption• Data duplication• Data arriving out of sequence

14

Page 15: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Layering and Problems

• Layering allows a problem to be solved in just one layer

• Especially, applications do not have to deal with network problems

15

Page 16: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Layers

16

Page 17: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Layering Models• OSI 7-layer model

– Developed for Open System Interconnect protocol family

– International standard developed over years by ISO

– Failed• TCP/IP 5-layer model

– Developed by US DARPA for military use– Widely adopted, basis for the Internet

17

Page 18: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

OSI Model

• We may have an exercise or two• The course is about Internet

protocols• You will never be examined on the

OSI model

18

Page 19: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

TCP-IP 5-Layer Reference Model

19

VERY

IMPORTANT!!!!

Page 20: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Important Boundaries

20

Page 21: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

In Reality

21

Page 22: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

How It Works

22

Page 23: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

What’s Happening

1. Sender hands message to transport layer, which packages message and hands it to Internet layer

2. Internet layer packages message as an IP datagram, with IP addresses, then hands it to network layer

3. Network interface puts message into an Ethernet frame, with Ethernet addresses, and sends through network adapter

23

Page 24: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Encapsulation

24

Page 25: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IP Demultiplexing

25

Page 26: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

INTERNET ADDRESSING

26

Page 27: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

The Internet

• Is it a physical or virtual network?• It’s a virtual network, defined by

protocols that run on hosts and routers.

• Internet protocols make the Internet look like a world-wide uniform network, although it encompasses many networks that are very different from each other.

27

Page 28: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Internet Addresses

• Each host connection on the Internet has a unique Internet address

• The addresses are designed to make forwarding of Internet packets simple

• An IP address has two parts: a prefix that identifies a network and a suffix that identifies a host on the network 28

Page 29: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Need for Control• To avoid conflicts in address use, some

sort of authority is needed• It makes sense to assign addresses in

blocks, not one at a time• ICANN (Internet Corporation for

Assigned names and Numbers) oversees IP address assignment

• Originally assigned in blocks of Class A, B and C addresses

29

Page 30: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IPv6 Addressing

• Each address is 128 bits• Enough addresses for every

person on earth to have an internet with three times the addresses of the present Internet!

• 1024 addresses per square meter of the earth’s surface

30

Page 31: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IPv6 Address Assignments

31

Page 32: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IPv4 to IPv6 Transition

32

Page 33: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IPv6 Address Split

33

Page 34: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Question• How many Internet addresses can one

host have?• As many as it has network adapters

34

Page 35: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IP Addresses

35

Page 36: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Functions of Internet Addresses

• Provide a unique identification for a particular interface between a device and the network so that a datagram can be delivered to the correct recipient

• Enable a path to be found across the Internet to reach the recipient, a process called routing

36

Page 37: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IP and Ethernet Addresses

• Is the IP address the same as the Ethernet address?– No!

• What is the role of each?– Ethernet: delivery on the local area

network– IP: forwarding across the Internet

37

Page 38: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

38

IPv4 Address

• 32-bit integer, unique for each host on the network, used in all communication with the host

• <IP address> ::= <netid> <hostid>– Netid: identifier of a network– Hostid: identifier of a host on the

network

Page 39: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

39

Dotted Decimal Notation

32-bit Internet address

10000000 00001010 00000010 00011110

Is written

128.10.2.30

Page 40: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

40

Classes of IPv4 Addresses

“Classful” addresses—types A, B and C below

first 2 bits distinguish 3 primary classes

Design of these classes is for efficient routing

There have been other refinements—to discuss later

Page 41: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Class Determination Algorithm

41

Page 42: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Address Class Characteristics

42

Page 43: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Host Capacities

43

Page 44: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IP Address Split

44

Page 45: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Advantages of Classful Addressing

• Simplicity and clarity—addresses and their setup are very easy to understand

• Flexibility to accommodate different sizes of networks

• Ease of separating host address for routing

• Allows for reservation of some addresses for special purposes

45

Page 46: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Classless IPv4 Addressing

• Temporary addressing scheme that does away with class A, B, C addresses

• Network prefix can be any specified length

• Forwarding techniques expanded to account for this: called Classless Inter-Domain Routing (CIDR)

46

Page 47: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

47

Special IP Addresses

Page 48: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

IP and Ethernet Addresses

• Physical transmissions are all made using Ethernet addresses across a local area network

• IP addresses give destinations across the Internet

• When a router gets an IP datagram, it decides whether to send it on to another router or deliver it locally

48

Page 49: 1 CSCI 233 Internet Protocols Class 2 Dave Roberts

Address Resolution

• If the router decides to deliver locally, then it must find out the local network’s Ethernet address that corresponds to the IP address in the datagram

• We’ll talk about address resolution next week!!

49