You are on page 1of 38

Chapter 4: IP Addressing

Objectives:
 Internet Architecture
IPv4 Addressing
IP address Classes
Subnets and subnet mask
Subnets design with IP addressing
IPv6
Internet Architecture
Taibah University

• Two computers, anywhere in


the world, following certain
hardware, software, protocol
specifications, can
communicate, reliably even
when not directly connected.

• LANs are no longer scalable


beyond a certain number of
stations or geographic
separation.

2
Internet Addresses
Taibah University

IP Address as a 32-Bit Binary Number

3
Decimal Equivalents of 8-Bit Patterns
Taibah University

4
Binary and Decimal Conversion
Taibah University

5
IP Address Classes
Taibah University

6
IP Address Classes
Taibah University

7
IP Addresses as Decimal Numbers
Taibah University

8
Hosts for Classes of
IP Addresses
Taibah University

Class A (24 bits for hosts) 224 - 2* = 16,777,214 maximum hosts


Class B (16 bits for hosts) 216 - 2* = 65,534 maximum hosts
Class C (8 bits for hosts) 28 - 2* = 254 maximum hosts
*
Subtracting the network and broadcast reserved address

9
IPv4 Address Classes
Taibah University

Class D Addresses
• A Class D address begins with binary 1110 in the first octet.
• First octet range 224 to 239.
• Class D address can be used to represent a group of hosts called a
host group, or multicast group.

Class E Addresses

• First octet of an IP address begins with 1111


• First octet range 240 to 255.
• Class E addresses are reserved for experimental purposes and should
not be used for addressing hosts or multicast groups. 
10
IP Addresses as Decimal Numbers
Taibah University

11
Network IDs and Broadcast Addresses
Taibah University

An IP address such as 176.10.0.0 that has all binary 0s in


the host bit positions is reserved for the network address.

An IP address such as 176.10.255.255 that has all binary 1s


in the host bit positions is reserved for the broadcast
address.

12
Private Addresses
Taibah University

13
Reserved Address Space
Taibah University

• Network ID
• Broadcast address
• Hosts for classes of IP addresses

14
Basics of Subnetting
Taibah University

• Classical IP addressing
• Subnetworks
• Subnet mask
• Boolean operations: AND, OR, and NOT
• Performing the AND function

15
Subnetworks
Taibah University

To create a subnet address, a network administrator


borrows bits from the original host portion and
designates them as the subnet field.

16
Subnetworks
Taibah University

17
Subnet Mask
Taibah University

• Determines which part of an IP address is the network field and which


part is the host field
• Follow these steps to determine the subnet mask:
– 1. Express the subnetwork IP address in binary form.
– 2. Replace the network and subnet portion of the address with all
1s.
– 3. Replace the host portion of the address with all 0s.
– 4. Convert the binary expression back to dotted-decimal notation.

18
Subnet Mask
Taibah University

Subnet mask in decimal = 255.255.240.0

19
Boolean Operations: AND, OR, and NOT
Taibah University

• AND is like multiplication.


• OR is like addition.
• NOT changes 1 to 0, and 0 to 1.

20
Performing the AND Function
Taibah University

21
Range of Bits Needed to Create Subnets
Taibah University

22
Subnet Addresses
Taibah University

23
Creating a Subnet
Taibah University

• Determining subnet mask size


• Computing subnet mask and IP address
• Computing hosts per subnetwork
• Boolean AND operation
• IP configuration on a network diagram
• Host and subnet schemes
• Private addresses

24
Determining Subnet Mask Size
Taibah University

Class B address with 8 bits borrowed for the subnet


130.5.2.144 (8 bits borrowed for subnetting) routes to subnet
130.5.2.0 rather than just to network 130.5.0.0.

25
Determining Subnet Mask Size
Taibah University

Class C address 197.15.22.131 with a subnet


mask of 255.255.255.224 (3 bits borrowed)

11000101 00001111 00010110 100 00011

Network Field SN Host Field

The address 197.15.22.131 would be on the


subnet 197.15.22.128.

26
Subnetting Example with AND Operation
Taibah University

27
IP Configuration on a Network Diagram
Taibah University

The router connects subnetworks and networks.

28
Subnet Example
Taibah University
Given the Class B address 190.52.0.0

Class B Network Network Host Host

Using /24
subnet... Network Network Subnet Host

Internet routers still “see” this net as 190.52.0.0

190.52.1.2 But internal routers think all


190.52.2.2 these addresses are on different
190.52.3.2 networks, called subnetworks

29
Subnet Example
Taibah University

Network Network Subnet Host

Using the 3rd octet, 190.52.0.0 was divided into:


190.52.1.0 190.52.2.0 190.52.3.0 190.52.4.0
190.52.5.0 190.52.6.0 190.52.7.0 190.52.8.0
190.52.9.0 190.52.10.0 190.52.11.0 190.52.12.0
190.52.13.0 190.52.14.0 190.52.15.0 190.52.16.0
190.52.17.0 190.52.18.0 190.52.19.0 and so on ...

30
Subnet Example
Taibah University
Network address 190.52.0.0 with /16 network mask
Using Subnets: subnet mask 255.255.255.0 or /24

Network Network Subnet Host

190 52 0 Host Subnets


190 52 1 Host
190 52 2 Host
255
190 52 3 Host Subnets

190 52 Etc. Host 28 - 1

190 52 254 Host


Cannot use last
190 52 255 Host subnet as it
contains broadcast
address 31
Subnet Example
Taibah University
Subnet 0 (all 0’s subnet) issue: The address of the subnet,
190.52.0.0/24 is the same address as the major network,
190.52.0.0/16.
Network Network Subnet Host

190 52 0 Host Subnets


190 52 1 Host
190 52 Etc. Host
255
190 52 254 Host Subnets
28 - 1
190 52 255 Host
Last subnet (all 1’s subnet) issue: The broadcast address for
the subnet, 190.52.255.255 is the same as the broadcast
address as the major network, 190.52.255.255. 32
Host Subnet Schemes
Taibah University

The number of lost IP addresses with a Class C network


depends on the number of bits borrowed for subnetting.

33
IP addressing crisis
Taibah University

• Address Depletion
• Internet Routing Table Explosion
34
IPv4 Addressing
Taibah University

Subnet Mask
• One solution to the IP address shortage was thought to be the
subnet mask.
• Formalized in 1985 (RFC 950), the subnet mask breaks a single
class A, B or C network in to smaller pieces.

35
Short Term Solutions: IPv4 Enhancements
Taibah University

• CIDR (Classless Inter-Domain Routing) – RFCs 1517,


1518, 1519, 1520
• VLSM (Variable Length Subnet Mask) – RFC 1009
• Private Addressing - RFC 1918
• NAT/PAT (Network Address Translation / Port Address
Translation) – RFC

36
IPv4 versus IPv6
Taibah University

• IP version 6 (IPv6) has been defined and developed.


• IPv6 uses 128 bits rather than the 32 bits currently used in IPv4.
• IPv6 uses hexadecimal numbers to represent the 128 bits.

IPv4

37
Long Term Solution: IPv6 (coming)
Taibah University

• IPv6, or IPng (IP – the Next Generation) uses a 128-bit address


space, yielding
340,282,366,920,938,463,463,374,607,431,768,211,456
possible addresses.
• IPv6 has been slow to arrive
• IPv4 revitalized by new features, making IPv6 a luxury, and not
a desperately needed fix
• IPv6 requires new software; IT staffs must be retrained
• IPv6 will most likely coexist with IPv4 for years to come.
• Some experts believe IPv4 will remain for more than 10 years.

38

You might also like