Megh CN
Megh CN
Megh CN
:220840116069
PRACTICAL – 1
AIM: Study of different network devices in detail.
Network Devices: Network devices, also known as networking hardware, are physical
devices that allow hardware on a computer network to communicate and interact with one
another. For example, Repeater, Hub, Bridge, Switch, Routers, Gateway, Brouter, and NIC,
etc.
Types of Network Devices:
1. Repeater – A repeater operates at the physical layer. Its job is to amplifies (i.e.,
regenerates) the signal over the same network before the signal becomes too weak or
corrupted to extend the length to which the signal can be transmitted over the same
network. When the signal becomes weak, they copy it bit by bit and regenerate it at its
star topology connectors connecting following the original strength. It is a 2-port
device.
Fig. 1 - Repeater
Advantages of Repeaters:
• Repeaters are simple to install and can easily extend the length or the coverage area
of networks.
• They are cost effective.
• Repeaters don’t require any processing overhead. The only time they need to be
investigated is in case of degradation of performance.
• They can connect signals using different types of cables.
Disadvantages of Repeaters:
• Repeaters cannot connect dissimilar networks.
• They cannot differentiate between actual signal and noise.
• They cannot reduce network traffic or congestion.
2. Hub – A hub is a basically multi-port repeater. A hub connects multiple wires coming
from different branches, for example, the connector in star topology which connects
different stations. Hubs cannot filter data, so data packets are sent to all connected
devices. In other words, the collision domain of all hosts connected through Hub
remains one. Also, they do not have the intelligence to find out the best path for data
packets which leads to inefficiencies and wastage.
1
Enrolment No.:220840116069
Fig. 2 - Hub
Types of Hub:
• Active Hub:- These are the hubs that have their power supply and can clean,
boost, and relay the signal along with the network. It serves both as a repeater as
well as a wiring center. These are used to extend the maximum distance between
nodes.
• Passive Hub:- These are the hubs that collect wiring from nodes and power
supply from the active hub. These hubs relay signals onto the network without
cleaning and boosting them and can’t be used to extend the distance between
nodes.
• Intelligent Hub:- It works like an active hub and includes remote management
capabilities. They also provide flexible data rates to network devices. It also
enables an administrator to monitor the traffic passing through the hub and to
configure each port in the hub.
Advantages of Hub:
• Connectivity – The primary function of the hub is to permit clients to attach to a
network in order that they will share and have conversations. For this purpose, hubs
use network protocol analyzer.
• Performance – Hub is understood for having very less number of performance
impacts on the network. This is often because it operates using a broadcast model
which rarely affects the network.
• Cost – Comparing to switches, hubs are really inexpensive. Basically, thanks to its
sort of simplicity. Therefore, they will assist you to save lots of money. And also due
to their products they are widely available within the market.
• Device Support – Hubs can connect different types of media all at once with a
central hub. Albeit the media want to operate at different speeds they will be wont to
support them.
2
Enrolment No.:220840116069
Fig.3 - Bridge
Types of Bridges:
• Transparent Bridges:- These are the bridge in which the stations are
completely unaware of the bridge’s existence i.e. whether or not a bridge is
added or deleted from the network, reconfiguration of the stations is
unnecessary. These bridges make use of two processes i.e. bridge forwarding
and bridge learning.
3
Enrolment No.:220840116069
4. Switch – A switch is a multiport bridge with a buffer and a design that can boost its
efficiency (a large number of ports imply less traffic) and performance. A switch is a data
link layer device. The switch can perform error checking before forwarding data, which
makes it very efficient as it does not forward packets that have errors and forward good
packets selectively to the correct port only. In other words, the switch divides the
collision domain of hosts, but the broadcast domain remains the same.
Fig. 4 - Switch
4
Enrolment No.:220840116069
Types of Switch:
1. Unmanaged switches: These switches have a simple plug-and-play design and do not
offer advanced configuration options. They are suitable for small networks or for use
as an expansion to a larger network.
2. Managed switches: These switches offer advanced configuration options such as
VLANs, QoS, and link aggregation. They are suitable for larger, more complex
networks and allow for centralized management.
3. Smart switches: These switches have features similar to managed switches but are
typically easier to set up and manage. They are suitable for small- to medium-sized
networks.
4. Layer 2 switches: These switches operate at the Data Link layer of the OSI model and
are responsible for forwarding data between devices on the same network segment.
5. Layer 3 switches: These switches operate at the Network layer of the OSI model and
can route data between different network segments. They are more advanced than
Layer 2 switches and are often used in larger, more complex networks.
6. PoE switches: These switches have Power over Ethernet capabilities, which allows
them to supply power to network devices over the same cable that carries data.
7. Gigabit switches: These switches support Gigabit Ethernet speeds, which are faster
than traditional Ethernet speeds.
8. Rack-mounted switches: These switches are designed to be mounted in a server rack
and are suitable for use in data centers or other large networks.
9. Desktop switches: These switches are designed for use on a desktop or in a small
office environment and are typically smaller in size than rack-mounted switches.
10. Modular switches: These switches have modular design, which allows for easy
expansion or customization. They are suitable for large networks and data centers.
Advantages of Switches:
• Increases Capacity – They increment the accessible data transfer capacity of the
organization.
• Reduces Burden – They help in lessening the outstanding burden on individual host
PCs.
• Less casing Impacts – Networks that use switches will have fewer casing impacts.
This is because of the way that switches make impact areas for every association.
Disadvantages of Switches:
• Costly – They are more costly in contrast with network spans.
5
Enrolment No.:220840116069
• Defenseless – If switches are in the indiscriminate mode, they are defenseless against
security assaults for example caricaturing IP address or catching Ethernet outlines.
5. Routers – A router is a device like a switch that routes data packets based on their IP
addresses. The router is mainly a Network Layer device. Routers normally connect
LANs and WANs and have a dynamically updating routing table based on which they
make decisions on routing the data packets. The router divides the broadcast domains of
hosts connected through it.
Fig. 5 - Router
6
Enrolment No.:220840116069
Fig. 6 - Gateway
Advantages of Gateway:
Disadvantages of Gateway:
7. Brouter – It is also known as the bridging router is a device that combines features of
both bridge and router. It can work either at the data link layer or a network layer.
Working as a router, it is capable of routing packets across networks and working as the
bridge, it is capable of filtering local area network traffic.
Fig. 7 - Brouter
7
Enrolment No.:220840116069
Advantages of Brouter:
• It offers best route for the data packets and hence reduces network traffic. This
increases efficiency of internet connection as it only transmits or receives traffic
intended for it instead of all the traffic on the network.
• It supports packet filtering and packet switching.
• It can be used with both LAN and WAN.
• It offers NAT to be configured and hence hides real IP address of internal network
which makes network more secure.
• It can connect with different mediums.
Disadvantages of Brouter:
8. NIC – NIC or network interface card is a network adapter that is used to connect the
computer to the network. It is installed in the computer to establish a LAN. It has a
unique id that is written on the chip, and it has a connector to connect the cable to it. The
cable acts as an interface between the computer and the router or modem. NIC card is a
layer 2 device which means that it works on both the physical and data link layers of the
network model.
Fig. 8 - NIC
Advantages of NIC:
• Faster network Speed − One of the major benefits of NICs is that they offer
quicker transfer rates than other networking equipment like modems and routers.
8
Enrolment No.:220840116069
• Reliability − A good quality NIC can provide more reliable network connectivity
than built in adaptors.
• Security − Some network interface cards (NICs) have security features like
hardware-based encryption that can add a layer of security to network
communications.
• Lower CPU usage − NICs can offload some processing tasks from the CPU, which
can reduce CPU usage and improve overall system performance. One example is
Cyclic redundancy check (CRC) is done by NIC for this task which saves so many
clocks of the CPU.
Disadvantages of NIC:
• Limited transfer speed − NICs are constrained by the network interface's top
performance. For high bandwidth apps like streaming video, large file transfers, or
gaming, this can be a bottleneck.
• Driver issues − Like any hardware, NICs require drivers to function properly. These
drivers may be incompatible with certain operating systems or may require frequent
updates.
9
Enrolment No.:220840116069
PRACTICAL – 2
AIM: Study of different types of network cables and practically implement
the cross-wired cable and straight through cable using clamping tool.
o Definition:
Networking cable is a piece of networking hardware used to connect one network
device to other network devices or to connect two or more computers to share
devices such as printers or scanners. Different types of network cables, such as
coaxial cable, optical fiber cable, and twisted pair cables, are used depending on the
network's topology, protocol, and size. The devices can be separated by a few meters
or nearly unlimited distances.
While wireless networks are more easily deployed when total throughput is not an
issue, most permanent larger computer networks utilize cables to transfer signals
from one point to another.
o Types of Cable:
There are three different types of network cabling.
1) Coaxial Cable
2) Fibre Optics Cable
3) Twisted Pair Cable
1. Coaxial Cable: A coaxial cable is an electrical cable with a copper conductor and an
insulator shielding around it and a braided metal mesh that prevents signal
interference and cross talk. Coaxial cable is also known as coax.
The core copper conductor is used for the transmission of signals and the insulator is
used to provide insulation to the copper conductor and the insulator is surrounded by a
braided metal conductor which helps to prevent the interference of electrical signals
and prevent cross talk. This entire setup is again covered with a protective plastic
layer to provide extra safety to the cable.
10
Enrolment No.:220840116069
Fiber optic cables are commonly used because of their advantages over copper cables.
Some of those benefits include higher bandwidth and transmit speeds.
STP cables are frequently used in areas that encounter interference due to
electrical currents. Shielded twisted pair cables may also be used in situations
where the distance between cables needs to be expanded.
11
Enrolment No.:220840116069
UTP cables are one of the least expensive wires available and are suitable for
basic phone systems. These cables have also been successfully used in video
applications, such as security cameras, due to an improvement in bandwidth. UTP
cables are made up of four components: conductor, insulator, twisted unit, and
sheath.
These physical cables are limited by length and durability. If a network cable is too long or
of poor quality, it won't carry a good network signal. These limits are one reason there are
different types of Ethernet cables that are optimized to perform certain tasks in specific
situations.
12
Enrolment No.:220840116069
o CAT 6:
A Cat 6 cable is used mainly for computer networks reaching a Gb, 1000 Mbps or one
Gbps of data transfer speed (DTR) or higher. Characteristics are as follows:
• Consists of four pairs of copper wires, which are all utilized for data transfer
• Provides bandwidth of 250 MHz, speed up to 10 Gbps and may be stretched to 100
meters in length.
• Provides more enhanced crosstalk and attenuation protection than its previous
twisted pair cable versions.
The Cat 6 cable is supported by Ethernet networks, including 10BaseT, 100Base-TX,
1000 Base-T and 10 GBase-T.
o Crimping Tool:
A crimping tool is a device used to conjoin two pieces of metal by deforming one or
both of them to hold each other. The result of the tool's work is called a crimp. An
example of crimping is affixing a connector to the end of a cable. For instance, network
cables and phone cables are created using a crimping tool to join RJ-45 and RJ 11
connectors to both ends of phone or Cat 5 cable.
13
Enrolment No.:220840116069
PRACTICAL-3
AIM: Study of basic network command and Network configuration
commands.
1. Tracert Command:
The tracert command is a Command Prompt command that's used to show several
details about the path that a packet takes from the computer or device you're on to
whatever destination you specify.
Practical in CMD.
14
Enrolment No.:220840116069
Practical in CMD.
15
Enrolment No.:220840116069
4. ARP Command:
ARP stands for “Address Resolution Protocol” is a protocol for mapping an IP
address to a physical MAC address on a local area network. Basically, ARP is a
program used by a computer system to find another computer’s MAC address based
on its IP address. Communication between two computers on the same broadcast
domain means a local area network. First, the client checks its ARP cache. ARP cache
is a table of IP addresses with their corresponding MAC addresses.
1. netstat –f :- The -f switch will force the netstat command to display the Fully
Qualified Domain Name (FQDN) for each foreign IP addresses when possible.
16
Enrolment No.:220840116069
2. netstat –o :- A handy option for many troubleshooting tasks, the -o switch displays
the process identifier (PID) associated with each displayed connection. See the
example below for more about using netstat -o.
6. Nbtstat Command:
Nbtstat is a utility that displays protocol statistics and current TCP/IP connections
using NBT (NetBIOS over TCP/IP), which helps troubleshoot NetBIOS name
resolution issues.
1. nbtstat –c :- Lists NBT’s cache of remote machine names and their IP addresses.
Practical in CMD.
17
Enrolment No.:220840116069
7. IPConfig Command:
This utility allows you to get the IP address information of a Windows computer. It
also allows some control over your network adapters, IP addresses (DHCP-assigned
specifically), even your DNS cache.
18
Enrolment No.:220840116069
8. Nslookup Command:
Nslookup is the name of a program that lets an Internet server administrator or any
computer user enter a host name (for example, "whatis.com") and find out the
corresponding IP address or domain name system (DNS) record.
The user can also enter a command for it to do a reverse DNS lookup and find the
host name for an IP address that is specified.
19
Enrolment No.:220840116069
20
Enrolment No.:220840116069
PRACTICAL – 4
AIM: Implement different LAN topologies using Network Simulator.
1. BUS TOPOLOGY:
• Bus topology is a specific kind of network topology in which all of the various
devices in the network are connected to a single cable or line.
• It transmits data only in one direction.
• It is a multi-point connection and a non-robust topology because if the backbone
fails the topology crashes.
• It is used in small networks.
• Easy to expand joining two cables together.
• It is used in early LAN connection.
Disadvantages:
• Bus topology is not great for large networks.
• Identification of problem becomes difficult if whole network goes down.
• Troubleshooting of individual device issues is very hard.
• Need of terminators are required at both ends of main cable.
• Additional devices slow network down.
• If a main cable is damaged, whole network fails or splits into two.
• Packet loss is high.
• This network topology is very slow as compared to other topologies.
21
Enrolment No.:220840116069
2. RING TOPOLOGY:
• It forms a ring as each computer is connected to another computer, with the last
one connected to the first.
• Transmission is unidirectional & sequential way that is bit by bit.
• In ring topology Transmitting network is not affected by high traffic or by adding
more nodes, as only the nodes having tokens can transmit data.
• It is cheap to install and expand.
Disadvantages:
• One malfunctioning workstation can create problems for the entire network. This
can be solved by using a dual ring or a switch that closes off the break.
• Moving, adding and changing the devices can affect the network.
• Communication delay is directly proportional to number of nodes in the network.
• Bandwidth is shared on all links between devices.
• More difficult to configure than a Star: node adjunction = Ring shutdown and
reconfiguration.
22
Enrolment No.:220840116069
3. STAR TOPOLOGY:
• In star topology Computers are connected to a single central hub through a cable.
• Fast performance with few nodes and low network traffic.
• Easy to troubleshoot & Easy to setup and modify.
• Only that node is affected which has failed rest of the nodes can work smoothly.
• Hub can be upgraded easily.
Advantages:
• If one node or its connection breaks, it does not affect the other computers nor
their connections.
• Devices can be added or removed without disturbing the network.
• Works well under heavy load.
• Appropriate for a large network.
Disadvantages:
• Expensive due to the number and length of cables needed to wire each host to the
central hub.
• The central hub is a single point of failure for the network.
4. MESH TOPOLOGY:
• Point-to-point connection to other devices or fully connected.
• Traffic is carried only between two connected devices.
• Robust, costly but not flexible.
• Fault is diagnosed easily.
• More cable resource used in setup.
23
Enrolment No.:220840116069
Disadvantages:
• It’s costly as compared to the opposite network topologies i.e. star, bus, point to
point topology.
• Installation is extremely difficult in the mesh.
• Power requirement is higher as all the nodes will need to remain active all the
time and share the load.
• Complex process.
• The cost to implement mesh is above other selections.
• There is a high risk of redundant connections.
• Each node requires a further utility cost to think about.
• Maintenance needs are challenging with a mesh.
5. TREE TOPOLOGY:
• It has a root node and all other nodes are connected to it forming a hierarchy.
• Also called hierarchical topology.
• Mostly used in Wide Area Network- WAN.
• Expansion of nodes is possible and easy.
• Easily managed and maintained.
24
Enrolment No.:220840116069
Advantages:
• This topology is the combination of bus and star topology.
• his topology provides a hierarchical as well as central data arrangement of the
nodes.
• As the leaf nodes can add one or more nodes in the hierarchical chain, this
topology provides high scalability.
• The other nodes in a network are not affected, if one of their nodes get damaged
or not working.
• Tree topology provides easy maintenance and easy fault identification can be
done.
• A callable topology. Leaf nodes can hold more nodes.
• Supported by several hardware and software vendors.
• Point-to-point wiring for individual segments.
Disadvantages:
• This network is very difficult to configure as compared to the other network
topologies.
• If the computer in first level is erroneous, next level computer will also go under
problems.
• Requires large number of cables compared to star and ring topology.
• As the data needs to travel from the central cable this creates dense network
traffic.
• The Backbone appears as the failure point of the entire segment of the network.
• Treatment of the topology is pretty complex.
• The establishment cost increases as well.
6. HYBRID TOPOLOGY:
• A network structure whose design contains more than one topology is said to be
hybrid topology.
• It is a combination of two or more topologies.
• Flexible & reliable as error detection and easy to troubleshoot.
• Scalable as size can be increased easily.
25
Enrolment No.:220840116069
Disadvantages:
• It is a type of network expensive.
• Design of a hybrid network is very complex.
• There is change hardware in order to connect topology with another topology. •
Usually, hybrid architectures are usually larger in scales so they require a lot of
cables in installation process.
• Hubs which are used to connect two distinct networks, are very costly. And hubs
are different from usual hubs as they need to be intelligent enough to work with
different architectures.
• Installation is a difficult process.
26
Enrolment No.:220840116069
PRACTICAL – 5
AIM: Implement the concept of VLAN using Network Simulator (Cisco
Packet Tracer).
Step-1: In Cisco Packet Tracer, create the network topology as shown below.
27
Enrolment No.:220840116069
Step-3: Assign switch ports to the VLANs. (Remember each VLAN is viewed as
separate broadcast domain.)
Configure switch interfaces fa 0/1 through fa 0/4 as access ports to connect to our
PCs. Assign interfaces fa 0/1 and fa 0/2 to VLAN10
Switch Interface fa 0/5 will be configured as trunk port, as it will be used to carry
traffic between the two VLANs via the router.
28
Enrolment No.:220840116069
In the above commands, we have specified an interface range and the n proceeded to
configure all the ports specified as access ports.
Interface fa 0/5 is configured as trunk and will be used to for inter-VLAN
communication.
Step-4: Assign static IP addresses to the four PCs which are located in the
separate VLANs. PC1 and PC2 fall in VLAN10 while PC3 and PC4 fall in
VLAN20.
29
Enrolment No.:220840116069
30
Enrolment No.:220840116069
Now, the routers physical interface fa 0/0 was subdivided into two sub-interfaces
(fa0/0.10and fa0/0.20), which are then configured as trunk interfaces and given IP
addresses.
Step-7: Test inter-VLAN connectivity.
Test connectivity between computers in different VLANs. Don’t forget that it is the
router that enables inter-VLAN routing. Ping PC3 in VLAN 20 from PC1 in VLAN
10.
The ping should work perfectly.
31
Enrolment No.:220840116069
PRACTICAL – 6
AIM: Implement the concept of static routing.
Static routing is the most secure way of routing. It reduces overhead from network resources.
In this type of routing, we manually add routes in routing table. It is useful where numbers of
route are limited.
Advantages:
• It is easy to implement.
• It is most secure way of routing, since no information is shared with other routers.
• It puts no overhead on resources such as CPU or memory.
Disadvantages:
• It is suitable only for small network.
• If a link fails it cannot reroute the traffic.
Implementation:
Step 1: Create following structure in network simulator (Cisco Packet Tracer).
32
Enrolment No.:220840116069
Double click Router0 and click CLI and press Enter key to access the command prompt
ofRouter0.
Two interfaces FastEthernet0/0 and Serial0/0/0 of Router0 are used in this topology. By
default, interfaces on router are remain administratively down during the start up. We need to
configure IP address and other parameters on interfaces before we could actually use them for
routing. Interface mode is used to assign IP address and other parameters. Interface mode can
be accessed from global configuration mode. Following commands are used to access the
global configuration mode.
33
Enrolment No.:220840116069
From global configuration mode we can enter in interface mode. From there we can
configure the interface. Following commands will assign IP address on Fast Ethernet 0/0.
Serial interface needs two additional parameters clock rate and bandwidth. Every serial cable
has two ends DTE and DCE. These parameters areal ways configured at DCE end.
We can use show controllers interface command from privilege mode to check the cable’s
end.
Fourth line of output confirms that DCE end of serial cable is attached. If you see DTE here
instead of DCE skip these parameters.
34
Enrolment No.:220840116069
ROUTER 1:
35
Enrolment No.:220840116069
Now we know how to assign IP addresses on interfaces. We will use same commands to
assign IP addresses on interfaces of Router2.
36
Enrolment No.:220840116069
ROUTER 2:
ROUTER 3:
Now routers have information about the networks that they have on their own interfaces.
Routers do not exchange network information between them on their own. We need to
implement a mechanism that insists them to share this information. This mechanism is called
routing.
37
Enrolment No.:220840116069
Router(config)#iproutedestination_network_#[subnet_mask]
IP_address_of_next_hop_neighbor[administrative_distance]
[permanent]
OR
Router(config)#iproutedestination_network_#[subnet_mask] interface_to_exit
[administrative_distance] [permanent]
Ip route: This is the base command that adds new routes in routing table.
Permanent: When a route goes down router will remove that from routing table. Permanent
parameter will keep this route in routing table even if it goes down. Its optional parameter we
can omit it. If we omit it, router will remove this route from routing table if it goes down. You
might use this parameter for security reason if you never want packets to take another path.
38
Enrolment No.:220840116069
ROUTER 0:
Network 20.0.0.0 is directly connected so we only need to configure network 10.0.0.0 on this
router.
That’s all we need to switch packet from one network to another. To verify the results we can
use ping command. Access the command prompt of PC1 and use ping command to test the
connectivity from PC0.
39
Enrolment No.:220840116069
PRACTICAL – 7
AIM: Implement the concept of dynamic routing (RIP, OSPF, BGP).
Hop Count:
Hop count is the number of routers occurring in between the source and destination network.
The path with the lowest hop count is considered as the best route to reach a network and
therefore placed in the routing table. RIP prevents routing loops by limiting the number of
hopes allowed in a path from source and destination. The maximum hop count allowed for
RIP is 15 and hop count of 16 is considered as network unreachable.
Features of RIP:
1.Updates of the network are exchanged periodically.
2.Updates (routing information) are always broadcast.
3.Full routing tables are sent in updates.
4.Routers always trust on routing information received from neighbour routers. This is also
known as Routing on rumours.
RIP versions:
There are three versions of routing information protocol– RIP Version1, RIP Version2 and
RIPng.
RIP v1 is known as Classful Routing Protocol because it doesn’t send information of subnet
mask in its routing update.
RIP v2 is known as Classless Routing Protocol because it sends information of subnet mask
in its routing update.
>> Use this command to show all routes configured in router, say for router R1:
R1# show ip route
>> Use this command to show all protocols configured in router, say for router R1:
R1# show ip protocols
40
Enrolment No.:220840116069
Configuration:
Consider the above given topology which has 3-routers R1, R2, R3. R1 has IP address
172.16.10.6/30 on s0/0/1, 192.168.20.1/24 on fa0/0. R2 has IP address 172.16.10.2/30 on
s0/0/0, 192.168.10.1/24 on fa0/0. R3 has IP address 172.16.10.5/30 on s0/1, 172.16.10.1/30
on s0/0, 10.10.10.1/24 on fa0/0.
RIP timers:
• Update timer: The default timing for routing information being exchanged by the routers
operating RIP is 30 seconds. Using Update timer, the routers exchange their routing table
periodically.
• Invalid timer: If no update comes until 180 seconds, then the destination router considers it
as invalid. In this scenario, the destination router mark hop count as 16 for that router.
• Hold down timer: This is the time for which the router waits for neighbour router to
respond. If the router isn’t able to respond within a given time then it is declared dead. It is
180 seconds by default.
• Flush time: It is the time after which the entry of the route will be flushed if it doesn’t
respond within the flush time. It is 60 seconds by default. This timer starts after the route
has been declared invalid and after 60 seconds i.e time will be 180 + 60 = 240 seconds.
Note that all these times are adjustable. Use this command to change the timers:
R1(config-router)# timers basic
R1(config-router)# timers basic 20 80 80 90
Open shortest path first (OSPF) is a link-state routing protocol which is used to find the best
path between the source and the destination router using its own SPF algorithm.
Open shortest path first (OSPF) router roles –
An area is a group of contiguous network and routers. Routers belonging to same area shares
a common topology table and area I’d. The area I’d is associated with router’s interface as a
router can belong to more than one area. There are some roles of router in OSPF:
42
Enrolment No.:220840116069
1. Backbone router– The area 0 is known as backbone area and the routers in area 0 are
known as backbone routers. If the routers exist partially in the area 0then also it is a backbone
router.
2. Internal router– An internal router is a router which has all of its interfaces in a single
area.
3.Area Boundary Router (ABR)– The router which connects backbone area with another
area is called Area Boundary Router. It belongs to more than one area. The ABRs therefore
maintain multiple link-state databases that describe both the backbone topology and the
topology of the other areas.
4.Area Summary Border Router (ASBR)– When an OSPF router is connected to a
different protocol like EIGRP, or Border Gateway Protocol, or any other routing protocol
then it is known as AS. The router which connects two different AS (in which one of the
interface is operating OSPF) is known as Area Summary Border Router. These routers
perform redistribution. ASBRs run both OSPF and another routing protocol, such as RIP or
BGP. ASBRs advertise the exchanged external routing information throughout their AS.
Note– A router can be backbone router and Area Boundary Router at the same time.
i.e, a router can perform more than one role at a time.
PROGRAM:
#include <stdio.h>
#include <string.h>
int main() {
int count, src_router, i, j, k, w, v, min;
int cost_matrix[100][100], dist[100], last[100];
int flag[100];
}
}
printf("\n Enter the source router:");
scanf("%d", & src_router);
for (v = 0; v < count; v++) {
43
Enrolment No.:220840116069
flag[v] = 0;
last[v] = src_router;
dist[v] = cost_matrix[src_router][v];
}
flag[src_router] = 1;
for (i = 0; i < count; i++) {
min = 1000;
for (w = 0; w < count; w++) {
if (!flag[w])
if (dist[w] < min) {
v = w;
min = dist[w];
}
}
flag[v] = 1;
for (w = 0; w < count; w++) {
if (!flag[w])
if (min + cost_matrix[v][w] < dist[w]) {
dist[w] = min + cost_matrix[v][w];
last[w] = v;
}
}
}
for (i = 0; i < count; i++) {
printf("\n%d==>%d:Path taken:%d", src_router, i, i);
w=i;
while (w != src_router) {
printf("\n<--%d",
last[w]);w = last[w];
}
printf("\n Shortest path cost:%d", dist[i]);
}
}
44
Enrolment No.:220840116069
OUTPUT:
The protocol can connect together any internetwork of autonomous system using an arbitrary
topology. The only requirement is that each AS have at least one router that is able to run
BGP and that is router connect to at least one other AS’s BGP router. BGP’s main function is
to exchange network reach-ability information with other BGP systems. Border Gateway
Protocol constructs an autonomous systems’ graph based on the information exchanged
between BGP routers.
45
Enrolment No.:220840116069
• Path Information: BGP advertisement also includes path information, along with the
reachable destination and next destination pair.
• Policy Support:
BGP can implement policies that can be configured by the administrator.
For ex:- a router running BGP can be configured to distinguish between the routes that are
known within the AS and that which are known from outside the AS.
• Runs Over TCP.
• BGPconserve network Bandwidth.
• BGPsupports CIDR.
• BGPalso supports Security.
PROGRAM:
#include <stdio.h>
int main() {
int n;
int i, j, k;
int a[10][10], b[10][10];
46
Enrolment No.:220840116069
47
Enrolment No.:220840116069
OUTPUT:
48
Enrolment No.:220840116069
PRACTICAL – 8
AIM: Packet capture and header analysis by wire-shark.
What is Wireshark?
o Wireshark is a network packet analyser. A network packet analyser presents captured
packet data in as much detail as possible.
o You could think of a network packet analyser as a measuring device for examining
what’s happening inside a network cable, just like an electrician uses a voltmeter for
examining what’s happening inside an electric cable (but at a higher level, of course).
o In the past, such tools were either very expensive, proprietary, or both. However, with the
advent of Wireshark, that has changed. Wireshark is available for free, is open source,
and is one of the best packet analysers available today.
Purposes of wireshark:
➢ Network administrators use it to troubleshoot network problems
➢ Network security engineers use it to examine security problems
➢ QA engineers use it to verify network applications
➢ Developers use it to debug protocol implementations
➢ People use it to learn network protocol internals
Features:
➢ The following are some of the many features Wireshark provides:
➢ Available for UNIX and Windows.
➢ Capture live packet data from a network interface.
➢ Open files containing packet data captured with tcpdump/WinDump, Wireshark, and
many
➢ Other packet capture programs.
➢ Import packets from text files containing hex dumps of packet data.
➢ Display packets with very detailed protocol information.
➢ Save packet data captured.
➢ Export some or all packets in a number of capture file formats.
➢ Filter packets on many criteria.
➢ Search for packets on many criteria.
➢ Colorize packet display based on filters.
➢ Create various statistics.
Figure:
49
Enrolment No.:220840116069
50
Enrolment No.:220840116069
3. SSDP Protocols: The Simple Service Discovery Protocol is a network protocol based
on the Internet protocol suite for advertisement and discovery of network services and
presence information.
4. ARP (Address Resolution Protocols): It is a network protocol used to find out the
hardware (MAC) address of a device from an IP address.
5. Hyper Text Transfer Protocols (HTTP): HTTP is designed for transferring a hypertext
among two or more systems.
6. DNS (Domain Name Protocols): The DNS protocol helps in translating or mapping
host names to IP addresses. DNS works on a client-server model, and uses a distributed
database over a hierarchy of name servers.
51
Enrolment No.:220840116069
PRACTICAL – 9
AIM: Study of data link control protocol.
➢ DataLinkLayer:
• In the OSI model, the data link layer is a 4th layer from the top and 2nd layer from the
bottom.
• The communication channel that connects the adjacent nodes is known as links, and in
order to move the datagram from source to the destination, the datagram must be
moved across an individual link.
• The main responsibility of the Data Link Layer is to transfer the datagram across an
individual link.
• TheData link layer protocol defines the format of the packet exchanged across the
nodes as well as the actions such as Error detection, retransmission, flow control, and
random access.
• TheDataLink Layer protocols are Ethernet, token ring, FDDI and PPP.
• An important characteristic of a Data Link Layer is that datagram can be handled by
different link layer protocols on different links in a path. For example, the datagram is
handled by Ethernet on the first link, PPP on the second link.
2. Reliable delivery:
Data Link Layer provides a reliable delivery service, which means that it sends the
network layer datagram without any mistakes. A reliable delivery service is
accomplished with transmissions and acknowledgements. A data link layer's main job is
to make sure that data is delivered reliably over the links, which have higher error rates
and can be fixed locally instead of having to send the data again.
3. Flow control:
A node that is getting frames can get them faster than it can process them. Without flow
control, the receiver's buffer can fill up and frames can be lost. To solve this problem, the
data link layer uses flow control to stop the sending node on one side of the link from
flooding the receiving node on the other side of the link.
4. Error detection:
Errors can be introduced by signal attenuation and noise. Data Link Layer protocol
provides a mechanism to detect one or more errors. This is achieved by adding error
detection bits in the frame and then receiving node can perform an error check.
52
Enrolment No.:220840116069
5. Error correction:
Error correction is similar to the Error detection, except that receiving node not only
detect the errors but also determine where the errors have occurred in the frame.
1. Actual Communication:
In this communication, physical medium is present through which Data Link Layer
simply transmits data frames. The actual path is Network Layer-> Data link layer->
Physical Layer on sending machine, then to physical media and after that to Physical
Layer-> Data link layer-> Network Layer on receiving machine.
2. Virtual Communication:
In this communication, no physical medium is present for Data Link Layer to transmit
data. It can be only be visualized and imagined that two Data Link Layers are
communicating with each other with the help of or using data link protocol.
53
Enrolment No.:220840116069
1. This service simply provides acknowledged connectionless service i.e. packet delivery
is simply acknowledged, with help of stop and wait for protocol.
2. In this service, each frame that is transmitted by Data Link Layer is simply
acknowledged individually and then sender usually knows whether or not these
transmitted data frames received safely.
3. There is no logical connection established and each frame that is transmitted is
acknowledged individually.
4. This mode simply provides means by which user of data link can just send or transfer
data and request return of data at the same time. It also uses particular time period that
if it has passed frame without getting acknowledgment, then it will resend data frame
on time period.
5. This service is more reliable than unacknowledged connectionless service. This
service is generally useful over several unreliable channels, like wireless systems, Wi-
Fi services, etc.
1. In this type of service, connection is established first among sender and receiver or
source and destination before data is transferred.
2. Then data is transferred or transmitted along with this established connection.
3. In this service, each of frames that are transmitted is provided individual numbers first,
so as to confirm and guarantee that each of frames is received only once that too in an
appropriate order and sequence.
Data Link Layer protocols are generally responsible to simply ensure and confirm that the
bits and bytes that are receive dare identical to the bits and bytes being transferred. It is
basicallyasetofspecificationsthatareusedforimplementationofdatalinklayerjustabove the
physical layer of the Open System Interconnections (OSI)Model.
54
Enrolment No.:220840116069
The Open System Interconnections (OSI) model is a layered networking framework that
conceptualizes how communications should be done between heterogeneous systems.
The data link layer is the second lowest layer. It is divided into two sublayers –
55
Enrolment No.:220840116069
➢ MAC Addresses:
MAC address or media access control address is a unique identifier allotted to a network
interface controller (NIC) of a device. It is used as a network address for data
transmission within a network segment like Ethernet, Wi-Fi, and Bluetooth.
56
Enrolment No.:220840116069
PRACTICAL – 10
AIM: St Study of Application Layer protocol.
What is Application Layer?
The Application Layer is topmost layer in the Open System Interconnection (OSI) model.
This layer provides several ways for manipulating the data (information) which actually
enables any type of user to access network with ease. This layer also makes a request to its
bottom layer, which is presentation layer for receiving various types of information from it.
The Application Layer interface directly interacts with application and provides common web
application services. This layer is basically highest level of open system, which provides
services directly for application process.
Following are list of functions which are performed by Application Layer of OSI Model
Data from User <=> Application layer <=> Data from Presentation Layer
1. Application Layer provides a facility by which users can forward several emails and it
also provides a storage facility.
2. This layer allows users to access, retrieve and manage files in a remote computer.
3. It allows users to log on as a remote host.
4. This layer provides access to global information about various services.
5. This layer provides services which include: e-mail, transferring files, distributing
results to the user, directory services, network resources and so on.
6. It provides protocols that allow software to send and receive information and present
meaningful data to users.
7. It handles issues such as network transparency, resource allocation and so on.
8. This layer serves as a window for users and application processes to access network
services.
9. Application Layer is basically not a function, but it performs application layer
functions.
57
Enrolment No.:220840116069
10. The application layer is actually an abstraction layer that specifies the shared
protocols and interface methods used by hosts in a communication network.
11. Application Layer helps us to identify communication partners, and synchronizing
communication.
12. This layer allows users to interact with other software applications.
13. In this layer, data is in visual form, which makes users truly understand data rather
than remembering or visualize the data in the binary format (0’s or 1’s).
14. This application layer basically interacts with Operating System (OS) and thus
further preserves the data in a suitable manner.
15. This layer also receives and preserves data from it’s previous layer, which is
Presentation Layer (which carries in itself the syntax and semantics of the information
transmitted).
16. The protocols which are used in this application layer depend upon what information
users wish to send or receive.
17. This application layer, in general, performs host initialization followed by remote
login to hosts.
Client initially transmits an instruction to the server, and after the server receives it, it
assigns a port number to the client. The client then initiates a connection with the server,
and when the server receives the request, it acknowledges it (ACK) to the client. At this
point, the client has access to the server and can either request the server send any kind
of file or other document, or it can upload files or other documents directly to the server.
Features:
To ensure smooth communication, application layer protocols are implemented the same on
source host and destination host.
The following are some of the features which are provided by Application layer protocols.
• The Application Layer protocol defines process for both parties which are involved in
communication.
• These protocols define the type of message being sent or received from any side (either
source host or destination host).
• These protocols also define basic syntax of the message being forwarded or retrieved.
• These protocols define the way to send a message and the expected response.
• These protocols also define interaction with the next level.
58
Enrolment No.:220840116069
Command:
telnet [\\RemoteServer]
\\RemoteServer: Specifies the name of the server to which you want to connect
2. FTP:
FTP stands for file transfer protocol. It is the protocol that actually lets us transfer
files. It can facilitate this between any two machines using it. But FTP is not just a
protocol but it is also a program. FTP promotes sharing of files via remote computers
with reliable and efficient data transfer. The Port number for FTP is 20 for data and
21 for control.
3. TFTP: The Trivial File Transfer Protocol (TFTP) is a simplified, stock version of
FTP, but if you know exactly what you're looking for and where to find it, it's the
protocol of choice. It is a streamlined form of FTP and a mechanism for moving files
across network devices. TFTP uses port number 69.
Command:
tftp [ options... ] [host [port]] [-c command]
4. NFS:
It stands for a network file system. It allows remote hosts to mount file systems over
a network and interact with those file systems as though they are mounted locally.
This enables system administrators to consolidate resources onto centralized servers
on the network. The Port number for NFS is 2049.
59
Enrolment No.:220840116069
Command:
service nfs start
5. SMTP:
It stands for Simple Mail Transfer Protocol. It is a part of the TCP/IP protocol. Using
a process called “store and forward,” SMTP moves your email on and across
networks. It works closely with something called the Mail Transfer Agent (MTA) to
send your communication to the right computer and email inbox. The Port number
for SMTP is 25.
Command:
MAIL FROM:<[email protected]?
6. LPD:
It stands for Line Printer Daemon. It is designed for printer sharing. It is the part that
receives and processes the request. A “daemon” is a server or agent. The Port number
for LPD is 515.
Command:
lpd [-d ] [-l ] [-D DebugOutputFile]
7. X window:
It defines a protocol for the writing of graphical user interface–based client/server
applications. The idea is to allow a program, called a client, to run on one computer.
It is primarily used in networks of interconnected mainframes. Port number for X
window starts from 6000 and increases by 1 for each server.
Command:
Run xdm in runlevel 5
8. SNMP:
60
Enrolment No.:220840116069
It stands for Simple Network Management Protocol. It gathers data by polling the
devices on the network from a management station at fixed or random intervals,
requiring them to disclose certain information. It is a way that servers can share
information about their current state, and also a channel through which an
administrate can modify pre-defined values. The Port number of SNMP is 161(TCP)
and 162(UDP).
Command:
snmpget-mALL-v1-cpublic snmp_agent_Ip_address sysName.0
9. DNS:
It stands for Domain Name System. Every time you use a domain name, therefore, a
DNS service must translate the name into the corresponding IP address. For example,
the domain name www.abc.com might translate to 198.105.232.4. The Port number
for DNS is 53.
Command:
ipconfig /flushdns
10. DHCP:
It stands for Dynamic Host Configuration Protocol (DHCP). It gives IP addresses to
hosts. There is a lot of information a DHCP server can provide to a host when the
host is registering for an IP address with the DHCP server. Port number for DHCP is
67, 68.
Command:
clear ip dhcp binding {address | * }
61