Presentation is loading. Please wait.

Presentation is loading. Please wait.

ICS 156: Lecture 2 (part 1) Today:  IP addressing  Data link protocols and ARP  Notes about lab.

Similar presentations


Presentation on theme: "ICS 156: Lecture 2 (part 1) Today:  IP addressing  Data link protocols and ARP  Notes about lab."— Presentation transcript:

1 ICS 156: Lecture 2 (part 1) Today:  IP addressing  Data link protocols and ARP  Notes about lab

2 IP Addressing  Addressing defines how addresses are allocated and the structure of addresses  IPv4 Classful IP addresses (obsolete) Classless inter-domain routing (CIDR) (RFC 854, current standard)  IP Version 6 addresses

3 What is an IP Address?  An IP address is a unique global address for a network interface.  An IP address uniquely identifies a network location.  Routers forwards a packet based on the destination address of the packet.  Exceptions: DHCP and NAT (lab 7)

4 IP Addresses

5 0x40x50x0044 10 9d08010 2 0000000000000 2 128.143.137.144 128.143.71.21 128 10 0x068bff 32 bits

6 An IP address is often written in dotted decimal notation  Each byte is identified by a decimal number in the range [0..255]: 10001111100000001000100110010000 1 st Byte = 128 2 nd Byte = 143 3 rd Byte = 137 4 th Byte = 144 128.143.137.144

7 Structure of an IP address network prefixhost number  An IP address encodes both a network number (network prefix) and an interface number (host number). network prefix identifies a network the host number identifies a specific host (actually, interface on the network). 0 31

8 How long the network prefix is?  Before 1993: The network prefix is implicitly defined (class-based addressing)  After 1993: The network prefix is indicated by a netmask.

9 Before 1993: Class-based addressing  The Internet address space was divided up into classes: Class A: Network prefix is 8 bits long Class B: Network prefix is 16 bits long Class C: Network prefix is 24 bits long Class D is multicast address Class E is reserved

10 Classful IP Adresses (Until 1993)  Each IP address contained a key which identifies the class: Class A: IP address starts with “0” Class B: IP address starts with “10” Class C : IP address starts with “110” Class D: IP address starts with “1110” Class E: IP address starts wit “11110”

11 The old way: Internet Address Classes

12

13 Problems with Classful IP Addresses  Fast growing routing table size Each router must have an entry for every network prefix ~ 2 21 = 2,097,152 class C networks In 1993, the size of routing tables started to outgrow the capacity of routers

14 Other problems with classful addresses  Address depletion for large networks Class A and Class B addresses were gone  How many class A/B network prefixes can there be? Limited flexibility for network addresses:  Class A and B addresses are overkill (>64,000 addresses)  Class C address is insufficient (256 addresses)

15 Classless Inter-domain routing (CIDR)  Network prefix is of variable length  Addresses are allocated hierarchically  Routers aggregate multiple address prefixes into one routing entry to minimize routing table size

16 CIDR network prefix is variable length  A network mask specifies the number of bits used to identify a network in an IP address. 10001111100000001000100110010000 11111111 111111100000000 128143 137 144 255 0 Addr Mask

17 CIDR notation  CIDR notation of an IP address: 128.143.137.144/24 /24 is the prefix length. It states that the first 24 bits are the network prefix of the address (and the remaining 8 bits are available for specific host addresses)  CIDR notation can nicely express blocks of addresses An address block [128.195.0.0, 128.195.255.255] can be represented by an address prefix 128.195.0.0/16 How many addresses are there in a /x address block?  2 (32-x)

18 CIDR hierarchical address allocation  IP addresses are hierarchically allocated.  An ISP obtains an address block from a Regional Internet Registry  An ISP allocates a subdivision of the address block to an organization  An organization recursively allocates subdivision of its address block to its networks  A host in a network obtains an address within the address block assigned to the network ISP 128.0.0.0/8 128.1.0.0/16 Foo.com 128.2.0.0/16 Library CS 128.195.0.0/16 128.195.1.0/24 128.195.4.0/24 University Bar.com 128.195.4.150

19 Hierarchical address allocation  ISP obtains an address block 128.0.0.0/8  [128.0.0.0, 128.255.255.255]  ISP allocates 128.195.0.0/16 ([128.195.0.0, 128.195.255.255]) to the university.  University allocates 128.195.4.0/24 ([128.195.4.0, 128.195.4.255]) to the CS department’s network  A host on the CS department’s network gets one IP address 128.195.4.150 128.0.0.0128.255.255.255 128.195.0.0 128.196.255.255 128.195.4.0 128.195.4.255 128.195.4.150

20 CIDR allows route aggregation  ISP1 announces one address prefix 128.0.0.0./8 to ISP2  ISP2 can use one routing entry to reach all networks connected to ISP1 ISP1 128.0.0.0/8 128.1.0.0/16 Foo.com 128.2.0.0/16 Library CS 128.195.0.0/16 University Bar.com I ISP3 You can reach 128.0.0.0/8 via ISP1 128.0.0.0/8 ISP1

21 CIDR summary  A network prefix is of variable length: a.b.c.d/x  Addresses are hierarchical allocated  Routers aggregate multiple address prefixes into one routing entry to minimize routing table size.

22 What problems CIDR does not solve (I)  An multi-homing site still adds one entry into global routing tables Mutil-home.com 128.0.0.0/8 204.0.0.0/8 204.1.0.0/16 ISP2 ISP1 You can reach 128.0.0.0/8 And 204.1.0.0/16 via ISP1 ISP3 204.1.0.0/16 ISP1 204.1.0.0/16 128.0.0.0/8 ISP1

23 What problems CIDR does not solve (II)  A site switches provider without renumbering still adds one entry into global routing tables Switched.com 128.0.0.0/8 204.0.0.0/8 204.1.0.0/16 ISP2 ISP1 You can reach 128.0.0.0/8 And 204.1.0.0/16 via ISP1 ISP3 128.0.0.0/8 ISP1 204.1.0.0/16 ISP1

24 Global routing tables continue to grow Source: http://bgp.potaroo.net/as6447/

25 Special IP Addresses  Reserved or (by convention) special addresses: Loopback interfaces all addresses 127.0.0.1-127.255.255.255 are reserved for loopback interfaces Most systems use 127.0.0.1 as loopback address loopback interface is associated with name “localhost” Broadcast address Host number is all ones, e.g., 128.143.255.255 Broadcast goes to all hosts on the network Often ignored due to security concerns  Test / Experimental addresses 10.0.0.0 - 10.255.255.255 172.16.0.0- 172.31.255.255 192.168.0.0 - 192.168.255.255  Convention (but not a reserved address) Default gateway has host number set to ‘1’, e.g., 128.195.4.1

26 IP Addressing  Addressing defines how addresses are allocated and the structure of addresses  IPv4 Classful IP addresses (obsolete) Classless inter-domain routing (CIDR) (current standard)  IP Version 6 addresses

27 IPv6 - IP Version 6  IP Version 6 Designed to be the successor to the currently used IPv4 Specification completed in 1994 Makes improvements to IPv4 (no revolutionary changes)  One (not the only !) feature of IPv6 is a significant increase in of the IP address to 128 bits (16 bytes)  IPv6 will solve – for the foreseeable future – the problems with IP addressing  10 24 addresses per square inch on the surface of the Earth.

28 IPv6 Header

29 IPv6 vs. IPv4: Address Comparison  IPv4 has a maximum of 2 32  4 billion addresses  IPv6 has a maximum of 2 128 = (2 32 ) 4  4 billion x 4 billion x 4 billion x 4 billion addresses

30 Notation of IPv6 addresses  Convention: The 128-bit IPv6 address is written as eight 16-bit integers (using hexadecimal digits for each integer) CEDF:BP76:3245:4464:FACE:2E50:3025:DF 12  Short notation:  Abbreviations of leading zeroes: CEDF:BP76:0000:0000:009E:0000:3025:D F12  CEDF:BP76:0:0:9E :0:3025:DF12  “:0000:0000:0000” can be written as “::” CEDF:BP76:0:0:FACE:0:3025:DF12  CEDF:BP76::FACE:0:3025:DF12

31 IPv4 address in IPv6  IPv6 addresses derived from IPv4 addresses have 96 leading zero bits.  Convention allows to use IPv4 notation for the last 32 bits. ::80:8F:89:90  ::128.143.137.144


Download ppt "ICS 156: Lecture 2 (part 1) Today:  IP addressing  Data link protocols and ARP  Notes about lab."

Similar presentations


Ads by Google