Internetworking: Samson A. School of Electrical & Computer Engineering, Hawassa Institute of Technology
Internetworking: Samson A. School of Electrical & Computer Engineering, Hawassa Institute of Technology
Samson A.
samialemayehu@gmail.com
School of Electrical & Computer Engineering,
Hawassa Institute of Technology
Chapter
Outline
Internetworking Concepts
Internetworking with TCP/IP
Addressing System
MAC, IP and Port
IP Addressing, Subnetting, Masking
Network Applications
2
Introduction
• Internetworking:
• Is a set of interconnected networks.
• Is any interconnection between public, private, commercial,
industrial, or governmental computer networks by routing packet
through gateways.
• Network: is a group of two or more computer systems linked together.
• It is implemented in Layer 3 (Network Layer) of OSI model.
• There are three variants of internetwork or Internetworking,
depending on who administers and who participates in them.
• Internet,
• Intranet
• Extranet
• Introduction
• Number system
• Address System and Address Space
Notation
• MAC address
• Port address
• IP address
IPv4 - Address
IPv4 Enhancements:
•Subnet Mask
•CIDR (Classless Inter-Domain Routing)
•VLSM (Variable Length Subnet Mask)
•Private Addressing
•NAT/PAT (Network Address Translation / Port Address
Translation)
• The subnet mask is the 32-bit number that the router uses to cover
up the network address to show which bits are being used to identify
the subnet.
• i.e it indicates how much of the IP address bits represents the
network or subnet
• The function of a subnet mask is to determine whether an IP
address exists on the local network or whether it must be routed
outside the local network. That is:-
• The subnet masking process is used to identify & extract the
network part of the address
• i.e. it is applied (logical AND) to an address to determine
whether the address is on the local Network.
• If it is not, the process of routing it to an outside network begins.
• Given:
• Network address 192.168.10.0 and Subnet mask
255.255.255.192. Subnet the network.
• Solution
• How many subnets?
• Since the last octet in the subnet mask is 192, it has 2 bits in
11000000. This gives us: 22 = 4 subnets
• How many hosts per subnet?
• We have six host bits 11000000, so the #hosts = 26-2 = 62
• What are the valid subnets?
• Block size = 256 – 192 = 64
• Starting at zero and counting in the block size, the subnets are 0,
64, 128, and 192.
192.168.10.0 192.168.10.128
Dec 2019 .1
Internetworking
.129
44
Example 2d
255.255.255.224 (/27)
Network 192.168.10.0
How many subnets? 224 is 11100000, so our equation would be 23 = 8.
How many hosts? 25– 2 = 30.
What are the valid subnets? 256 – 224 = 32. We just start at zero and
count to the subnet mask value in blocks (increments) of 32: 0, 32, 64,
96, 128, 160, 192, and 224.
What’s the broadcast address for each subnet (always the number right
before the next subnet)?
What are the valid hosts (the numbers between the subnet number and
the broadcast address)?
Subnet Address 192.168.10.0 192.168.10.32 ……. 192.168.10.192 192.168.10.224
Subnets? 21 = 2
Hosts? 215– 2 = 32,766 (7 bits in the third octet, and 8 in the fourth)
Valid subnets? 256 – 128 = 128. 0, 128. Remember that subnetting is
performed in the third octet, so the subnet numbers are really 0.0 and
128.0, as shown in the next table
Broadcast address for each subnet?
Valid hosts?
Hosts = 2^5 – 2 = 30
But which is
Waste of Space
• A classless address is one that does not follow the classfull rules.
• Network not identified based on default classes
• Router uses prefix (/) to describe how many bits are network bits
• More efficient use of IPv4 address space
• In CIDR, we could have a class with 16 mask, 24 mask or any.
Clas Range CIDR Possible NW Possible Host From To
s -Mask per NW
A 1-126 /8 27 =128 224 -2 = 0.0.0.0 126.255.255.255
16,777,214
B 128-191 /16 214 =16,348 216 -2 = 65,534 128.0.0.0 191.255.255.255
C 192-223 /24 221 28 - 2 = 254 192.0.0.0 223.255.255.255
=2,097,152
D 224-239 N/A - - 224.0.0.0 239.255.255.255
E 240-255 N/A - - 240.0.0.0 255.255.255.255
• VLSM allows:
• More than one subnet mask within the same NW
• Or . . . Multiple SNMasks with ONE IP Address
• Use of long mask on networks with few hosts
• Use of short mask on networks with many hosts
netE:
Dec 2019 204.15.5.128/27 host address range 129 to 158
Internetworking 57
Variable Length Subnet Mask(VLSM)
Subnet with requirements shown?
With Fixed subnet
With VLSM
The easiest way to assign the subnets is to assign the largest first. For
example, you can assign in this manner:
With VLSM
Step - 2
Sort the requirements of IPs in descending order (Highest to
Lowest).
Sales 100
Purchase 50
Accounts 25
Management 5
Step - 4
Allocate the next highest range, so let's assign 192.168.1.128 /26
(255.255.255.192) to the Purchase department. This IP subnet with
Network number 192.168.1.128 has 62 valid Host IP Addresses
which can be easily assigned to all the PCs of the Purchase
department. The subnet mask used has 11000000 in the last octet.
Step - 5
Allocate the next highest range, i.e. Accounts. The requirement of 25
IPs can be fulfilled with 192.168.1.192 /27 (255.255.255.224) IP
subnet, which contains 30 valid host IPs. The network number of
Accounts department will be 192.168.1.192. The last octet of subnet
mask is 11100000.
Dec 2019 Internetworking 64
• Step - 6
• Allocate the next highest range to Management. The Management department
contains only 5 computers. The subnet 192.168.1.224 /29 with the Mask
255.255.255.248 has exactly 6 valid host IP addresses. So this can be assigned to
Management. The last octet of the subnet mask will contain 11111000.
• By using VLSM, the administrator can subnet the IP subnet in such a way that least
number of IP addresses are wasted. Even after assigning IPs to every department,
the administrator, in this example, is still left with plenty of IP addresses which was
not possible if he has used CIDR.
Net ID CI Mask b SM BA
D o
R r
Sales 192.168.1.0 /25 255.255.255.128 1 126 100
Solution
We replace each decimal number with its binary equivalent:
•01101111 00111000 00101101 01001110
•11011101 00100010 00000111 01010010
•11110001 00001000 00111000 00001100
•01001011 00101101 00100010 01001110
Solution
a.There are no leading zeroes in dotted-decimal notation (045).
b.We may not have more than four numbers in an IP address.
c.In dotted-decimal notation, each number is less than or equal to 255;
301 is outside this range.
d.A mixture of binary notation and dotted-decimal notation is not
allowed.
1. 192.168.1.3
Class ___________________ Default Mask:________________
Network: _________________ Broadcast: __________________
Hosts: _________________ through ___________________
2. 1.12.100.31
Class _____________________ Default
Mask:_________________
Network: _________________ Broadcast: ________________
Hosts: _________________ through ____________________
2. 172.30.77.5
Class ___________________ Default Mask:________________
Network: ________________ Broadcast: __________________
Hosts: _________________ through ___________________