0% found this document useful (0 votes)
32 views28 pages

Data Communication and Networking: VLSM and Routing by Mr. Chishala G

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1/ 28

DATA VLSM AND ROUTING

COMMUNICATION AND By Mr. CHISHALA G


[email protected]
NETWORKING
VARIABLE LENGTH SUBNET MASKS
Creating many networks from a large single network using subnet masks of different
lengths in various kinds of network designs is what is called VLSM networking.
Classless routing protocols do support the advertisement of subnet information,
which means you can use VLSM with routing protocols such as RIPv2,(but not RIPv1)
Enhanced Interior Gateway Protocol (EIGRP), and Open Shortest Path First (OSPF).
The benefit of this type of network is that it saves a bunch of IP address space.
As the name suggests, VLSMs can use subnet masks with different lengths for
different router interfaces.
Check out Figure 6.1 on the next slide to see an example of why classful network
designs are inefficient.
Looking at Figure 6.1, you can see that there are two routers, each with two LANs and
connected together with a WAN serial link.
VARIABLE LENGTH SUBNET MASKS
VARIABLE LENGTH SUBNET MASKS
In a typical classful network design that’s running RIP, you could subnet a network like this:
192.168.10.0 = Network
255.255.255.240 (/28) = Mask
Our subnets would be—you know this part, right?— 0, 16, 32, 48, 64, 80, etc., which allows us to
assign 16 subnets to our internetwork.
But how many hosts would be available on each network?
Each subnet provides only 14 hosts, so each LAN has only 14 valid hosts available (don’t forget
that the router interface needs an address too and is included in the amount of needed valid hosts).
This means that one LAN doesn’t even have enough addresses needed for all the hosts, and this
network as it is shown would not work as addressed in the figure.
 Since the point-to-point WAN link also has 14 valid hosts, it would be great to be able to nick a
few valid hosts from that WAN link to give to our LANs!
VARIABLE LENGTH SUBNET MASKS
All hosts and router interfaces have the same subnet mask—again, known as classful routing—and
if we want this network to be efficient, we would definitely need to add different masks to each
router interface.
But that’s not our only problem—the link between the two routers will never use more than two
valid hosts.
This wastes valuable IP address space, and it’s the big reason you need to use VLSM network
design.
VLSM Design: Let’s take Figure 6.1 and use a classless design instead, which will become the
new network shown in Figure 6.2.
In the previous example, we wasted address space—one LAN didn’t have enough addresses
because every router interface and host used the same subnet mask. Not so good.
A better solution would be to provide for only the needed number of hosts on each router interface,
and we’re going to use VLSMs to achieve that goal.
VARIABLE LENGTH SUBNET MASKS
FIG 6.2 Classless network design
VARIABLE LENGTH SUBNET MASKS
Now remember that we can use different size masks on each router interface.
 If we use a /30 on our WAN links and a /27, /28, and /29 on our LANs, we’ll get 2 hosts per WAN
interface and 30, 14, and 6 hosts per LAN interface—nice!
This makes a huge difference—not only can we get just the right amount of hosts on each LAN, we
still have room to add more WANs and LANs using this same network!
To implement a VLSM design on your network, you need to have a routing protocol that sends
subnet mask information with the route updates.
The protocols that do that are RIPv2, EIGRP, and OSPF. Remember, RIPv1 will not work in
classless networks, so it’s considered a classful routing protocol.
Implementing VLSM Networks
To create VLSMs quickly and efficiently, you need to understand how block sizes and charts
work together to create the VLSM masks. Table 5.1 shows you the block sizes used when creating
VLSMs with Class C networks.
VARIABLE LENGTH SUBNET MASKS
For example, if you need 25 hosts, then you’ll need a block size of 32. If you need 11 hosts, you’ll
use a block size of 16. Need 40 hosts?
Then you’ll need a block of 64. You cannot just make up block sizes—they’ve got to be the block
sizes shown in Table 5.1. So memorize the block sizes in this table—it’s easy.
They’re the same numbers we used with subnetting!
VARIABLE LENGTH SUBNET MASKS
Notice that the block sizes start at 4 and advance all the way up to a block size of
128.
 If you have two networks with block sizes of 128, you can have only 2 networks.
With a block size of 64, you can have only 4, and so on, all the way to 64 networks
using a block size of 4.
Based on what you’ve learned so far about block sizes and the VLSM table,
 let’s create a VLSM network using a Class C network address 192.168.10.0 for the
network in Figure 5.6 then fill out the VLSM table.
In Figure 6.4, we have four WAN links and four LANs connected together, so we
need to create a VLSM network that will save address space.
Looks like we have two block sizes of 32, a block size of 16, and a block size of 8,
and our WANs each have a block size of 4. Take a look and see how I figured out the
VLSM table.
VARIABLE LENGTH SUBNET MASKS
There are two important things to note here, the first is that we still have plenty of room for growth
with this VLSM network design.
The second point is that we could never achieve this goal with one subnet mask using classful
routing.
VLSM network example is shown below:
SUMMARIZATION
Summarization, also called route aggregation, allows routing protocols to advertise many networks
as one address.
The purpose of this is to reduce the size of routing tables on routers to save memory,
which also shortens the amount of time IP requires to parse the routing table when determining the
best path to a remote network.
Figure 6.5 shows how a summary address would be used in an internetwork.
SUMMARIZATION
Summarization is pretty straightforward because all you really need to have down is a solid
understanding of the block sizes we’ve been using for subnetting and VLSM design.
For example, if you wanted to summarize the following networks into one network advertisement, you
just have to find the block size first, which will make it easy to find your answer:
192.168.16.0 through network 192.168.31.0 Okay—so what’s the block size? Well, there are exactly
16 Class C networks, which fit neatly into a block size of 16.
Now that we’ve determined the block size, we just need to find the network address and mask used to
summarize these networks into one advertisement.
The network address used to advertise the summary address is always the first network address in the
block—in this example, 192.168.16.0.
To figure out a summary mask, we just need to figure out which mask will get us a block size of 16.
If you came up with 240, you got it right! 240 would be placed in the third octet, which is exactly the
octet where we’re summarizing, so the mask would be 255.255.240.0.
SUMMARIZATION
Here’s another example:
Networks 172.16.32.0 through 172.16.50.0 .This isn’t as clean as the previous example because
there are two possible answers. Here’s why:
Since you’re starting at network 32, your options for block sizes are 4, 8, 16, 32, 64, etc., and
block sizes of 16 and 32 could work as this summary address. Let’s explore your two options:
If you went with a block size of 16, then the network address would be 172.16.32.0 with a mask
of 255.255.240.0 (240 provides a block of 16).
The problem is that this only summarizes from 32 to 47, which means that networks 48 through
50 would be advertised as single networks. Even so, this could still be a good solution depending
on your network design.
If you decided to go with a block size of 32 instead, then your summary address would still be
172.16.32.0, but the mask would be 255.255.224.0 (224 provides a block of 32).
The possible problem with this answer is that it will summarize networks 32 through 63 and we
only have networks 32 to 50.
SUMMARIZATION
No worries if you’re planning on adding networks 51 to 63 later into the same
network,
but you could have serious problems in your internetwork if somehow networks 51
to 63 were to show up and be advertised from somewhere else in your network!
So even though this option does allow for growth, it’s a lot safer to go with option
#1.
IP ROUTING
Routing Basics:
Once you create an internetwork by connecting your WANs and LANs to a router, you’ll need to
configure logical network addresses,
like IP addresses, to all hosts on that internetwork for them to communicate successfully throughout
it.
The term routing refers to taking a packet from one device and sending it through the network to
another device on a different network.
Routers don’t really care about hosts— they only care about networks and the best path to each one
of them.
The logical network address of the destination host is key to get packets through a routed network.
 It’s the hardware address of the host that’s used to deliver the packet from a router and ensure it
arrives at the correct destination host.
Routing is irrelevant if your network has no routers because their job is to route traffic to all the
networks in your internetwork, but this is rarely the case!
IP ROUTING
So here’s an important list of the minimum factors a router must know to be able to affectively
route packets:
Destination address
Neighbor routers from which it can learn about remote networks
Possible routes to all remote networks
The best route to each remote network
How to maintain and verify routing information
The router learns about remote networks from neighboring routers or from an administrator.
The router then builds a routing table, which is basically a map of the internetwork, and it
describes how to find remote networks.
If a network is directly connected, then the router already knows how to get to it.
IP ROUTING
But if a network isn’t directly connected to the router, the router must use one of two ways to learn
how to get to the remote network.
The static routing method requires someone to hand-type all network locations into the routing
table.
Conversely, when dynamic routing is used, a protocol on one router communicates with the same
protocol running on neighboring routers.
The routers then update each other about all the networks they know about and place this
information into the routing table.
If a change occurs in the network, the dynamic routing protocols automatically inform all routers
about the event.
If static routing is used, the administrator is responsible for updating all changes by hand onto all
routers
IP ROUTING
The IP Routing Process: The IP routing process is fairly simple and doesn’t change, regardless of
the size of your network.
Consider an IP routing example below that uses two routers. Since understanding IP routing is
super-important, it’s time for us to look at how IP routing process down so far takes place.
Fig below shows a LAN connected to RouterA that’s connected via a WAN link to RouterB.
RouterB has a LAN connected with an HTTP server attached.
IP ROUTING
1. The destination address of a frame from HostA would be the MAC address of
Router A’s Fa0/0 interface.
2. The destination address of a packet would be the IP address of the HTTP server’s
network interface card (NIC).
3. The destination port number in the segment header would be 80.
One thing to remember is that when multiple hosts are communicating to a server using HTTP,
they must all use a different source port number.
The source and destination IP addresses and port numbers are how the server keeps the data
separated at the Transport layer.
IP routing example 2:
 The key thing to understand about the IP routing process in this scenario is what happens when
HostA sends data to the HTTPS server? Here’s your answer:
IP ROUTING

1. The destination address of a frame from HostA would be the MAC address of
RouterA’s Fa0/0 interface.
2. The destination address of a packet is the IP address of the HTTPS server’s network
interface card (NIC).
3. The destination port number in the segment header will have a value of 443.
Did you notice that the switches weren’t used as either a default gateway or any other destination?
That’s because switches have nothing to do with routing.
It’s very important to remember that the destination MAC address will always be the router’s
interface—if your packets are destined for outside the LAN, as they were in these last two examples.
Basic IP routing using MAC and IP addresses:
IP ROUTING
IP ROUTING
Referring to Fig in the previous slide, here’s a list of all the answers to questions you need to master.
1. In order to begin communicating with the server, Host 4 sends out an ARP request. How will the
devices exhibited in the topology respond to this request? Since MAC addresses must stay on the local
network, the Lab_B router will respond with the MAC address of the Fa0/0 interface and Host 4 will send
all frames to the MAC address of the Lab_B Fa0/0 interface when sending packets to the Sales server.
2. Host 4 has received an ARP reply. Host 4 will now build a packet, then place this packet in the frame.
What information will be placed in the header of the packet that eaves Host 4 if Host 4 is going to
communicate to the Sales server? Since we’re now talking about packets, not frames, the source address
will be the IP address of Host 4 and the destination address will be the IP address of the Sales server.
3. Finally, the Lab_A router has received the packet and will send it out Fa0/0 onto the LAN toward the
server. What will the frame have in the header as the source and destination addresses? The source MAC
address will be the Lab_A router’s Fa0/0 interface, and the destination MAC address will be the Sales
server’s MAC address because all MAC addresses must be local on the LAN.
4. Host 4 is displaying two web documents from the Sales server in two different browser windows at the
same time. How did the data find its way to the correct browser windows? TCP port numbers are used to
direct the data to the correct application window.
IP ROUTING
Configuring IP Routing:
There are the three routing methods that are used in routing.
Static routing
Default routing
Dynamic routing
Static Routing
Static routing is the process that ensues when you manually add routes in each router’s routing table.
Predictably, there are pros and cons to static routing, but that’s true for all routing approaches.
Here are the pros:
There is no overhead on the router CPU, which means you could probably make do with a cheaper router than you
would need for dynamic routing.
There is no bandwidth usage between routers, saving you money on WAN links as well as minimizing overhead on
the router since you’re not using a routing protocol.
It adds security because you, the administrator, can be very exclusive and choose to allow routing access to certain
networks only.
IP ROUTING
And here are the cons:
Whoever the administrator is must have a vault-tight knowledge of the internetwork and how each
router is connected in order to configure routes correctly.
 If you don’t have a good, accurate map of your internetwork, things will get very messy quickly.
 If you add a network to the internetwork, you have to tediously add a route to it on all routers by
hand, which only gets increasingly insane as the network grows.
Due to the last point, it’s just not feasible to use it in most large networks because maintaining it
would be a full-time job in itself.
Starting at the beginning, here’s the command syntax you use to add a static route to a routing
table from global config:
ip route [destination_network] [mask] [next-hop_address or
exitinterface] [administrative_distance] [permanent]
•// ip route: The command used to create the static route.
IP ROUTING
•// Mask: The subnet mask being used on the network.
•//next-hop_address: This is the IP address of the next-hop router that will receive packets and
forward them to the remote network, which must signify a router interface that’s on a directly
connected network.
•//exitinterface: Used in place of the next-hop address if you want, and shows up as a directly
connected route.
•//administrative_distance: By default, static routes have an administrative distance of 1 or 0 if you
use an exit interface instead of a next-hop address.
Dynamic Routing:
Dynamic routing is when protocols are used to find networks and update routing tables on routers.
This is whole lot easier than using static or default routing, but it will cost you in terms of router
CPU processing and bandwidth on network links.
A routing protocol defines the set of rules used by a router when it communicates routing
information between neighboring routers.
IP ROUTING
Administrative Distances: The administrative distance (AD) is used to rate the trustworthiness of
routing information received on a router from a neighbor router.
An administrative distance is an integer from 0 to 255, where 0 is the most trusted and 255 means
no traffic will be passed via this route.
If a router receives two updates listing the same remote network, the first thing the router checks is
the AD.
If one of the advertised routes has a lower AD than the other, then the route with the lowest AD will
be chosen and placed in the routing table.
If both advertised routes to the same network have the same AD, then routing protocol metrics like
hop count and/or the bandwidth of the lines will be used to find the best path to the remote network.
 The advertised route with the lowest metric will be placed in the routing table, but if both
advertised routes have the same AD as well as the same metrics,
then the routing protocol will load-balance to the remote network, meaning the protocol will send
data down each link.
IP ROUTING
Default administrative distances for different routing protocols are shown below:

There are three classes of routing protocols:


Distance vector: The distance-vector protocols in use today find the best path to a remote network
by judging distance.
In RIP routing, each instance where a packet goes through a router is called a hop, and the route with
the least number of hops to the network will be chosen as the best one.
The vector indicates the direction to the remote network. RIP is a distance-vector routing protocol
and periodically sends out the entire routing table to directly connected neighbors.
IP ROUTING
Link state: In link-state protocols, also called shortest-path-first protocols, the routers each create
three separate tables.
One of these tables keeps track of directly attached neighbors, one determines the topology of the
entire internetwork, and one is used as the routing table.
Link-state routers know more about the internetwork than any distance-vector routing protocol ever
could. OSPF is an IP routing protocol that’s completely link-state.
Link state protocols send updates containing the state of their own links to all other directly
connected routers on the network. This is then propagated to their neighbors.
Hybrid: Hybrid protocols use aspects of both distance-vector and link-state protocols, and EIGRP
is a great example.
There’s no set of rules to follow that dictate exactly how to broadly configure routing protocols for
every situation.
If you understand how the different routing protocols work, you can make good, solid decisions that
will solidly meet the individual needs of any business!

You might also like