Presentation is loading. Please wait.

Presentation is loading. Please wait.

4 IP Address (IPv4)  A unique 32-bit number  Identifies an interface (on a host, on a router, …)  Represented in dotted-quad notation 0000110000100010.

Similar presentations


Presentation on theme: "4 IP Address (IPv4)  A unique 32-bit number  Identifies an interface (on a host, on a router, …)  Represented in dotted-quad notation 0000110000100010."— Presentation transcript:

1

2

3

4 4 IP Address (IPv4)  A unique 32-bit number  Identifies an interface (on a host, on a router, …)  Represented in dotted-quad notation 0000110000100010 1001111000000101 12341585

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22 Network ID, Host ID, Gateway

23 خط فرضی = Netmask

24

25 Network Layer Addressing IP addresses 0 network host 10 network host 110 networkhost 1110 multicast address A B C D class 1.0.0.0 to 127.255.255.255 128.0.0.0 to 191.255.255.255 192.0.0.0 to 239.255.255.255 240.0.0.0 to 247.255.255.255 32 bits

26 Internet Classes  10011101 10001111 11111100 11001111 (Class B)  11011101 10001111 11111100 11001111 (Class C)  01111011 10001111 11111100 11001111 (Class A)  11101011 10001111 11111100 11001111 (Class D)  11110101 10001111 11111100 11001111 (Class E)  Class A, B are full; class C still has available addresses; D is reserved for multicasting and class E is reserved for future use

27 Network Layer Addressing Subnetting class C address  Only 8 bits are available for hosts : possible subnet masks are: 10000000 = 128 10000000 = 128 11000000 = 192 11000000 = 192 11100000 = 224 11100000 = 224 11110000 = 240 11110000 = 240 11111000 = 248 11111000 = 248 11111100 = 252 11111100 = 252 11111110 = 254 11111110 = 254

28 28 IP Address and a 24-bit Subnet Mask 0000110000100010 1001111000000101 12341585 11111111 00000000 255 0 Address Mask

29

30 30 Scalability Improved  Number related hosts from a common subnet 1.2.3.0/24 on the left LAN 1.2.3.0/24 on the left LAN 5.6.7.0/24 on the right LAN 5.6.7.0/24 on the right LAN host LAN 1... host LAN 2... router WAN 1.2.3.41.2.3.71.2.3.1565.6.7.85.6.7.95.6.7.212 1.2.3.0/24 5.6.7.0/24 forwarding table

31 31 Classless Inter-Domain Routing (CIDR) IP Address : 12.4.0.0 IP Mask: 255.254.0.0 0000110000000100 00000000 1111111111111110 00000000 Address Mask for hostsNetwork Prefix Use two 32-bit numbers to represent a network. Network number = IP address + Mask Written as 12.4.0.0/15

32 32 CIDR: Hierarchal Address Allocation 12.0.0.0/8 12.0.0.0/16 12.254.0.0/16 12.1.0.0/16 12.2.0.0/16 12.3.0.0/16 :::::: 12.3.0.0/24 12.3.1.0/24 :::: 12.3.254.0/24 12.253.0.0/19 12.253.32.0/19 12.253.64.0/19 12.253.96.0/19 12.253.128.0/19 12.253.160.0/19 :::::: Prefixes are key to Internet scalability –Address allocated in contiguous chunks (prefixes) –Routing protocols and packet forwarding based on prefixes –Today, routing tables contain ~150,000-200,000 prefixes

33 33 Scalability: Address Aggregation Provider is given 201.10.0.0/21 201.10.0.0/22201.10.4.0/24201.10.5.0/24201.10.6.0/23 Provider Routers in the rest of the Internet just need to know how to reach 201.10.0.0/21. The provider can direct the IP packets to the appropriate customer.

34 Netmasks and IP addresses  The netmask splits the IP address into the network part and the host part.  The address is and-ed with the netmask to determine the two parts E.g – 141.163.143.231, netmask 255.255.192.0 IP: 10001101.10100011.10001111.11100111 Mask: 11111111.11111111.11000000.00000000 Net: 10001101.10100011.10000000.00000000 Host: 00000000.00000000.00001111.11100111 Net: 141.163.128.0 Host: 127.231 (less used)

35 © 2000, Cisco Systems, Inc. www.cisco.com BSCN v1.0—3-35 Host Addresses 172.16.2.1 172.16.3.10 172.16.12.12 10.1.1.1 10.250.8.11 10.180.30.118 E1 172.1612 NetworkHost.. NetworkInterface 172.16.0.0 10.0.0.0 E0 E1 Routing Table 172.16.2.1 10.6.24.2 E0

36 © 2000, Cisco Systems, Inc. www.cisco.com BSCN v1.0—3-36 IP Addressing 223.1.1.1 223.1.1.2 223.1.1.3 223.1.1.4 223.1.2.9 223.1.2.2 223.1.2.1 223.1.3.2 223.1.3.1 223.1.3.27 network consisting of 3 IP networks (for IP addresses starting with 223, first 24 bits are network address) LAN

37 © 2000, Cisco Systems, Inc. www.cisco.com BSCN v1.0—3-37 IP Addressing How to find the networks? Detach each interface from router, host create “islands of isolated networks 223.1.1.1 223.1.1.3 223.1.1.4 223.1.2.2 223.1.2.1 223.1.2.6 223.1.3.2 223.1.3.1 223.1.3.27 223.1.1.2 223.1.7.0 223.1.7.1 223.1.8.0223.1.8.1 223.1.9.1 223.1.9.2 Interconnected system consisting of six networks

38 © 2000, Cisco Systems, Inc. www.cisco.com BSCN v1.0—3-38 Getting a datagram from source to dest. IP datagram: 223.1.1.1 223.1.1.2 223.1.1.3 223.1.1.4 223.1.2.9 223.1.2.2 223.1.2.1 223.1.3.2 223.1.3.1 223.1.3.27 A B E misc fields source IP addr dest IP addr data l datagram remains unchanged, as it travels source to destination l addr fields of interest here Dest. Net. next router Nhops 223.1.1 1 223.1.2 223.1.1.4 2 223.1.3 223.1.1.4 2 routing table in A:

39 © 2000, Cisco Systems, Inc. www.cisco.com BSCN v1.0—3-39 Getting a datagram from source to dest. 223.1.1.1 223.1.1.2 223.1.1.3 223.1.1.4 223.1.2.9 223.1.2.2 223.1.2.1 223.1.3.2 223.1.3.1 223.1.3.27 A B E Starting at A, given IP datagram addressed to B: l look up net. address of B l find B is on same net. as A l link layer will send datagram directly to B inside link-layer frame n B and A are directly connected Dest. Net. next router Nhops 223.1.1 1 223.1.2 223.1.1.4 2 223.1.3 223.1.1.4 2 misc fields 223.1.1.1223.1.1.3 data

40 © 2000, Cisco Systems, Inc. www.cisco.com BSCN v1.0—3-40 Getting a datagram from source to dest. 223.1.1.1 223.1.1.2 223.1.1.3 223.1.1.4 223.1.2.9 223.1.2.2 223.1.2.1 223.1.3.2 223.1.3.1 223.1.3.27 A B E Dest. Net. next router Nhops 223.1.1 1 223.1.2 223.1.1.4 2 223.1.3 223.1.1.4 2 Starting at A, dest. E: l look up network address of E l E on different network n A, E not directly attached l routing table: next hop router to E is 223.1.1.4 l link layer sends datagram to router 223.1.1.4 inside link- layer frame l datagram arrives at 223.1.1.4 l continued….. misc fields 223.1.1.1223.1.2.2 data

41 © 2000, Cisco Systems, Inc. www.cisco.com BSCN v1.0—3-41 Getting a datagram from source to dest. 223.1.1.1 223.1.1.2 223.1.1.3 223.1.1.4 223.1.2.9 223.1.2.2 223.1.2.1 223.1.3.2 223.1.3.1 223.1.3.27 A B E Arriving at 223.1.4, destined for 223.1.2.2 l look up network address of E l E on same network as router’s interface 223.1.2.9 n router, E directly attached l link layer sends datagram to 223.1.2.2 inside link-layer frame via interface 223.1.2.9 l datagram arrives at 223.1.2.2!!! (hooray!) misc fields 223.1.1.1223.1.2.2 data network router Nhops interface 223.1.1 - 1 223.1.1.4 223.1.2 - 1 223.1.2.9 223.1.3 - 1 223.1.3.27 Dest. next

42 Netmasks - the easy way  The scope of a network is defined by the network mask:  Class B network example Address: 137.17.0.0 Mask: 255.255.0.0  Class C network example Address: 196.14.37.0 Mask: 255.255.255.0 Scope: 137.17.0.1 - 137.17.254.254 Scope: 196.14.37.1 - 196.14.37.254

43 Router’s operations At each hop the data link layer frame is changed but the packets above never change

44 44 Are 32-bit Addresses Enough?  Not all that many unique addresses 2 32 = 4,294,967,296 (just over four billion) 2 32 = 4,294,967,296 (just over four billion) Plus, some are reserved for special purposes Plus, some are reserved for special purposes And, addresses are allocated in larger blocks And, addresses are allocated in larger blocks  And, many devices need IP addresses Computers, PDAs, routers, tanks, toasters, … Computers, PDAs, routers, tanks, toasters, …  Long-term solution: a larger address space IPv6 has 128-bit addresses (2 128 = 3.403 × 10 38 ) IPv6 has 128-bit addresses (2 128 = 3.403 × 10 38 )  Short-term solutions: limping along with IPv4 Private addresses Private addresses Network address translation (NAT) Network address translation (NAT) Dynamically-assigned addresses (DHCP) Dynamically-assigned addresses (DHCP)

45

46 46 IPv6 Header compared to IPv4 Header Ver. Time to Live Source Address Total Length Type of Service Hdr Len Identification Fragment Offset Flg Protocol Header Checksum Destination Address Options... Ver. Traffic Class Source Address Payload Length Next Header Hop Limit Destination Address Hdr Len Identification Fragment Offset Flg Header Checksum Options... shaded fields have no equivalent in the other version IPv6 header is twice as long (40 bytes) as IPv4 header without options (20 bytes) Flow Label

47

48

49

50

51

52

53

54

55

56

57

58

59


Download ppt "4 IP Address (IPv4)  A unique 32-bit number  Identifies an interface (on a host, on a router, …)  Represented in dotted-quad notation 0000110000100010."

Similar presentations


Ads by Google