0% found this document useful (0 votes)
11 views41 pages

CN Lab Manual

Uploaded by

userx3882
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views41 pages

CN Lab Manual

Uploaded by

userx3882
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

COMPUTER NETWORKS LAB

CSE (AI&ML, DS)

[DATE]
[COMPANY NAME]
[Company address]
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

Introduction To Cisco Packet Tracer

Cisco Packet Tracer is a powerful network simulation tool developed by Cisco Systems. It allows users
to create, configure, and troubleshoot complex network topologies in a virtual environment. It is widely
used for educational purposes, especially for students preparing for Cisco certifications like CCNA.
Packet Tracer provides an interactive platform where users can simulate real-world networking
scenarios, understand how different network devices interact, and gain hands-on experience without the
need for physical hardware.

Features of Cisco Packet Tracer


• Device Simulation: Packet Tracer supports a wide range of Cisco devices, including routers,
switches, firewalls, and end devices like PCs, servers, and phones. Users can drag and drop
these devices into the workspace and interconnect them to form networks.
• Multi-User Collaboration: Packet Tracer allows multiple users to collaborate on a single
network topology in real time, making it a valuable tool for group projects and remote learning.
• Simulation Mode: The tool provides a simulation mode where users can visually track the flow
of data packets through the network, understand protocol operations, and diagnose issues.
• Real-Time Mode: In real-time mode, the network operates as if it were live, providing a
realistic environment for configuring and testing network setups.
• Support for IoT: Packet Tracer includes Internet of Things (IoT) capabilities, allowing users
to design and simulate smart home or industrial IoT networks using various IoT devices.
• Integrated Help and Tutorials: It offers built-in tutorials and activities to help users learn
networking concepts and gain practical experience.
• Cross-Platform Support: Cisco Packet Tracer is available on Windows, macOS, and Linux,
making it accessible to a broad range of users.

Installation Steps for Cisco Packet Tracer


1. Download Cisco Packet Tracer:
o Visit the Cisco Networking Academy website at [Link].
o Sign up for a free account or log in if you already have one.
o Navigate to the "Resources" section and find the download link for Cisco Packet Tracer.
o Choose the appropriate version for your operating system (Windows, macOS, or Linux) and
download the installer.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

2. Install on Windows:
o Locate the downloaded .exe file and double-click to launch the installer.
o Follow the on-screen prompts, accepting the license agreement and selecting the installation
directory.
o Choose whether to install for "All Users" or "Just for Me" depending on your needs.
o After the installation is complete, click "Finish" to exit the installer.

3. First-Time Setup:
• Upon the first launch, you may be prompted to log in with your Cisco NetAcad credentials.
• After logging in, you'll have full access to the software and can start building network topologies.

4. Update and Maintenance:


• Cisco periodically releases updates for Packet Tracer. You can check for updates within the application
or download the latest version from the NetAcad website.
• It's advisable to regularly update Packet Tracer to benefit from new features and security enhancements.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 1
1. Study of different types of network cables, and connectors using a crimping tool (CO1)
Network Cables:
1. Coaxial Cable:
o Description: A single copper conductor at the center, surrounded by a plastic layer,
braided metal shield, and an outer plastic covering.
o Use: Commonly used for cable television and early Ethernet networks.
o Connectors: BNC (Bayonet Neill-Concelman), F-Type.
2. Twisted Pair Cable:
o Description: Consists of pairs of wires twisted together to reduce electromagnetic
interference (EMI).
o Types:
▪ Unshielded Twisted Pair (UTP): Most common in modern networking (e.g.,
Cat5e, Cat6).
▪ Shielded Twisted Pair (STP): Includes a shield to protect from EMI.
o Use: Commonly used in Ethernet networks.
o Connectors: RJ45 (for Ethernet), RJ11 (for telephone).
3. Fiber Optic Cable:
o Description: Uses light to transmit data, providing high-speed transmission over long
distances.
o Types:
▪ Single-mode fiber (SMF): For long-distance communication.
▪ Multi-mode fiber (MMF): For shorter distances.
o Connectors: SC (Subscriber Connector), LC (Lucent Connector), ST (Straight Tip).

Connectors:
1. RJ45:
o Description: An 8-pin connector used primarily for Ethernet networking.
o Use: Terminates twisted-pair Ethernet cables (Cat5e, Cat6).
2. RJ11:
o Description: A 4-pin connector used for telephone lines.
o Use: Connects telephones and modems to the phone network.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

3. BNC:
o Description: A connector used with coaxial cables.
o Use: Often found in older networks, radio, and television.
Crimping Tool:
• Purpose: A crimping tool is used to attach connectors (e.g., RJ45) to the end of network cables.
• Parts:
o Crimping Die: The part that presses the pins into the cable.
o Wire Cutter: For cutting the cable to the desired length.
o Wire Stripper: For removing the insulation from the wires.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

2. Implement the cross-wired cable and straight-through cable using the crimping tool (CO1)
1. Straight-Through Cable:
• Use: Connects different types of devices, such as a computer to a switch or router.
• Wiring Standards: T568A or T568B on both ends.
Steps:
1. Prepare the Cable:
o Cut the cable to the desired length.
o Strip about 1 inch of the outer jacket from both ends of the cable.
2. Arrange the Wires:
o Untwist the pairs and arrange them according to the T568A or T568B standard.
3. Insert Wires into the RJ45 Connector:
o Insert the arranged wires into the RJ45 connector, ensuring each wire is in the
correct slot.
o The flat side of the connector should face upwards.
4. Crimp the Connector:
o Place the RJ45 connector into the crimping tool.
o Squeeze the crimping tool firmly to press the connector pins into the wires.
5. Test the Cable:
o Use a cable tester to ensure all connections are correct and functioning.
2. Cross-Wired Cable:
• Use: Connects similar devices, such as a computer to another computer or a switch to another
switch.
• Wiring Standards: T568A on one end and T568B on the other.
Steps:
1. Prepare the Cable:
o Cut the cable to the desired length.
o Strip about 1 inch of the outer jacket from both ends of the cable.
2. Arrange the Wires:
o On one end, arrange the wires according to the T568A standard.
o On the other end, arrange the wires according to the T568B standard.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

3. Insert Wires into the RJ45 Connector:


o Insert the arranged wires into the RJ45 connector, ensuring each wire is in the correct
slot.
4. Crimp the Connector:
o Place the RJ45 connector into the crimping tool.
o Squeeze the crimping tool firmly to press the connector pins into the wires.
5. Test the Cable:
o Use a cable tester to ensure all connections are correct and functioning.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 2

3. Networking commands (CO1)


Objective: To understand and utilize basic networking commands (ipconfig, ipconfig/all, nslookup,
ping, tracert, resmon,) to monitor, diagnose, and troubleshoot network issues.

Software Required:
• A computer with Windows OS
• Command Prompt

Theory:
Networking commands are essential tools for managing and troubleshooting network connectivity and
performance. These commands help in gathering information about network configurations, testing
network paths, and analyzing network traffic.

Procedure:
1. ipconfig Command
Description: The ‘ipconfig’ command displays the IP address, subnet mask, and default
gateway for all adapters.
Syntax: ipconfig

Example Usage:
• Open the Command Prompt.
• Type ipconfig and press Enter.
• Observe the network configuration details like IP address and default gateway.

Output: Displays a summary of the IP configuration. (Write your output here)

2. ipconfig/all Command
Description: The ipconfig/all command provides a detailed view of the IP configuration,
including the MAC address, DNS servers, and DHCP information.
Syntax: ipconfig/all
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

Example Usage:
• In the Command Prompt, type ipconfig /all and press Enter.
• Review detailed information about each network adapter.

Output: Provides detailed IP configuration for all network adapters. (Write your output here)

3. nslookup Command
Description: The nslookup command queries the DNS to obtain the domain name or IP address
mapping.
Syntax: nslookup [hostname]

Example Usage:
• In the Command Prompt, type nslookup [Link] and press Enter.
• Observe the IP address corresponding to the domain name.

Output: Displays the IP address associated with the specified domain name. (Write your output
here)

4. ping Command
Description: The ping command tests the reachability of a host on an IP network and measures
the round-trip time for messages sent from the originating host.
Syntax: ping [hostname or IP address]

Example Usage:
• In the Command Prompt, type ping [Link] and press Enter.
• Observe the reply from the host, including the time taken and packet loss.

Output: Shows whether the target is reachable and provides response times. (Write your output
here)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

5. tracert Command
Description: The tracert command traces the path packets take to reach a network host, showing
each hop along the way.
Syntax: tracert [hostname or IP address]

Example Usage:
• In the Command Prompt, type tracert [Link] and press Enter.
• View the list of routers the packets pass through to reach the destination.

Output: Lists all intermediary routers between the source and destination. (Write your output
here)

6. resmon Command
Description: The resmon command opens the Resource Monitor tool, which displays detailed
information about resource usage, including network activity.
Syntax: resmon

Example Usage:
• In the Command Prompt, type resmon and press Enter.
• In the Resource Monitor window, navigate to the Network tab to view current activity.
Output: Opens the Resource Monitor to monitor network usage in real-time.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 3

4. Hands-on Practice with the Packet Tracer tool with a sample Peer to Peer network connection
(CO1)
Objective:
To establish a peer-to-peer network using Cisco Packet Tracer and verify communication between two
PCs connected directly via a crossover cable.
Software Required:
• Cisco Packet Tracer software
• A computer with Cisco Packet Tracer installed
Theory:
Peer-to-peer (P2P) networking involves direct communication between two or more devices, without
the need for a central server. In this experiment, two PCs will be directly connected using a crossover
cable, allowing them to communicate and share resources.
Procedure:
Step 1: Launch Cisco Packet Tracer
Open the Cisco Packet Tracer application on your computer.
Step 2: Add Network Devices
Add PCs:
• In the bottom left-hand corner of the Packet Tracer interface, click on the “End Devices”
icon.
• Drag and drop two PCs (PC0 and PC1) onto the workspace.
Step 3: Connect the PCs with a Crossover Cable
1. Select a Crossover Cable:
• Click on the “Connections” icon (shaped like a lightning bolt).
• Choose the “Copper Cross-over” cable (represented by a red line).
2. Connect the PCs:
• Click on PC0, select FastEthernet0 port.
• Then click on PC1, and select the FastEthernet0 port to connect them using the crossover
cable.
Step 4: Configure IP Addresses
1. Configure PC0:
• Double-click on PC0 to open its configuration window.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

• Go to the Desktop tab and click on the IP Configuration icon.


o Set the IP Address to [Link] and the Subnet Mask to [Link].
o Close the configuration window.
2. Configure PC1:
o Double-click on PC1 to open its configuration window.
o Go to the Desktop tab and click on the IP Configuration icon.
o Set the IP Address to [Link] and the Subnet Mask to [Link].
o Close the configuration window.
Step 5: Test the Connection
1. Ping from PC0 to PC1:
o Open PC0 and go to the Desktop tab, then open the Command Prompt.
o Type ping [Link] and press Enter.
o Observe the ping results. A successful reply indicates that the connection is functioning.
2. Ping from PC1 to PC0:
o Repeat the process from PC1, typing ping [Link] in its Command Prompt.
o Ensure that PC1 can also communicate with PC0.
Step 6: Save the Project
Observation:
• Record the successful communication between the two PCs, demonstrated by the ping command
results showing successful replies.
• Note the IP configuration settings for each PC.
(Write the ping statistics of the PCs you connected, and the ip configurations of the systems taken)

Result:
The peer-to-peer network was successfully set up using Cisco Packet Tracer. Both PCs were able to
communicate with each other directly through a crossover cable.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 4
5. Hands-on Practise with Packet Tracer tool with a sample static routing (CO1)
Objective:
To configure static routing in a network using Cisco Packet Tracer, enabling routers to communicate
with each other and route traffic between different network segments.
Software Required:
• Cisco Packet Tracer software
• A computer with Cisco Packet Tracer installed
Theory:
Static routing is a process where the network administrator manually adds routes in the routing table.
Unlike dynamic routing, static routing does not require routing protocols and is more secure and less
resource-intensive, but it requires manual configuration and management.
Procedure:
1. Configure IP Addresses on PCs
• PC0:
o Click on PC0.
o Go to the Desktop tab, select IP Configuration.
o Set the IP address to [Link].
o Set the subnet mask to [Link].
o Set the default gateway to [Link].
• PC1:
o Click on PC1.
o Go to the Desktop tab, select IP Configuration.
o Set the IP address to [Link].
o Set the subnet mask to [Link].
o Set the default gateway to [Link].
2. Assign IP Addresses to Router Interfaces
• Router0:
o Click on Router0.
o Go to the Config tab.
o Click on the interface FastEthernet0/0 (connected to PC0).
o Assign IP address [Link] with subnet mask [Link] and turn the interface ON.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

o Click on the interface Serial0/0/0 (connected to Router1).


o Assign IP address [Link] with subnet mask [Link] and turn the interface ON.
• Router1:
o Click on Router1.
o Go to the Config tab.
o Click on the interface FastEthernet0/0 (connected to PC1).
o Assign IP address [Link] with subnet mask [Link] and turn the interface ON.
o Click on the interface Serial0/0/0 (connected to Router0).
o Assign IP address [Link] with subnet mask [Link] and turn the interface ON.
3. Setting Up Static Routes Using Packet Tracer GUI
• Router0:
o Click on Router0.
o Go to the Config tab and select Static under the Routing section.
o Add a new static route:
▪ Destination Network: [Link].
▪ Subnet Mask: [Link].
▪ Next Hop: [Link].
▪ Click Add.
• Router1:
o Click on Router1.
o Go to the Config tab and select Static under the Routing section.
o Add a new static route:
▪ Destination Network: [Link].
▪ Subnet Mask: [Link].
▪ Next Hop: [Link].
▪ Click Add.
4. Verify Connectivity
• Open a command prompt from PC0.
• Ping [Link] (PC1).
• If the static routes are configured correctly, you should receive replies from PC1.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

Observation:
• Record the successful communication between the two PCs using static routes configured on the
routers. (Write if ping is successful or not and whether the connection is established or not)
• Note the Type of connection used between Routers and Devices (Serial connection, Fast ethernet
connection, and why crossover cable used between two different devices).
Result:
The static routing was successfully configured, allowing both PCs on different networks to communicate
with each other through the routers.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 5
5. Create three LAN topologies: bus, star, and ring. Assign appropriate IP addresses to devices and
demonstrate basic connectivity.
Instructions:
1. Use Packet Tracer to build bus, star, and ring topologies.
2. Configure IP addresses on devices accordingly.
3. Verify basic connectivity within each topology.
4. Provide a short description of each topology and discuss its pros and cons. (CO1)

Objective:
Design and implement three different LAN topologies (Bus, Star, and Ring) using Cisco Packet Tracer,
assign appropriate IP addresses to devices, and verify basic connectivity within each topology.
Software Required:
• Cisco Packet Tracer software
• A computer with Cisco Packet Tracer installed
Theory:
LAN topologies define the physical and logical layout of a network. Common topologies include Bus,
Star, and Ring, each with distinct characteristics in terms of performance, scalability, and fault tolerance.
1. Bus Topology:
• Description: In a bus topology, all devices are connected to a single central cable (the bus). Data sent
by any device is broadcast to all devices on the network, but only the intended recipient accepts the
data.
Procedure: Build the Bus Topology
1. Set up the Devices:
o Open Packet Tracer and add four PCs (PC0, PC1, PC2, PC3).
o Connect all PCs using a single Coaxial Bus cable.
2. Assign IP Addresses:
o Configure IP addresses for each PC:
▪ PC0: [Link]
▪ PC1: [Link]
▪ PC2: [Link]
▪ PC3: [Link]
o Subnet Mask for all PCs: [Link]
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

3. Verify Connectivity:
o Ping from PC0 to PC1, PC2, and PC3 to check network connectivity.
o Record the results. (Write if ping is successful or not and whether the connection is
established or not)

2. Star Topology:
• Description: In a star topology, all devices are connected to a central hub or switch. The hub/switch
acts as a repeater for data, improving performance.
Procedure: Build the Star Topology
1. Set up the Devices:
o Add a switch/hub and connect four PCs (PC0, PC1, PC2, PC3) to the switch using Copper
Straight-through cables.
2. Assign IP Addresses:
o Configure IP addresses for each PC:
▪ PC0: [Link]
▪ PC1: [Link]
▪ PC2: [Link]
▪ PC3: [Link]
o Subnet Mask for all PCs: [Link]
3. Verify Connectivity:
o Ping from PC0 to PC1, PC2, and PC3 to check network connectivity.
o Record the results. (Write if ping is successful or not and whether the connection is
established or not)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

3. Ring Topology:
• Description: In a ring topology, each device is connected to exactly two other devices, forming a
circular pathway for signals. Data travels in one direction around the ring.
Procedure: Build the Ring Topology
1. Set up the Devices:
o Add four switches and connect four PCs (PC0, PC1, PC2, PC3) and circularly connect them
using Copper Cross-over cables and Copper Straight – through cables between PC and
switch.
2. Assign IP Addresses:
o Configure IP addresses for each PC:
▪ PC0: [Link]
▪ PC1: [Link]
▪ PC2: [Link]
▪ PC3: [Link]
o Subnet Mask for all PCs: [Link]
3. Verify Connectivity:
o Ping from PC0 to PC1, PC2, and PC3 to check network connectivity.
o Record the results. (Write if ping is successful or not and whether the connection is
established or not)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

Observation:
• Record the successful pings in each topology, demonstrating that devices can communicate with
each other. (Write ping statistics of each topology here)
• Note any connectivity issues and how they were resolved. (Write about what problem occurs in ring
topology)
Result:
All three topologies (Bus, Star, and Ring) were successfully implemented using Cisco Packet Tracer.
Basic connectivity was verified by successfully pinging between the devices in each topology.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 6
6. Design and implement a CRC algorithm in C language. Conduct laboratory experiments to test
the CRC implementation with various data strings and polynomials, recording and analyzing the
calculated CRC remainders for each scenario. (CO2)
Objective:
To design and implement a CRC algorithm in the C programming language. The experiment will test
the algorithm with various data strings and polynomial values, recording and analyzing the calculated
CRC remainders.
Introduction:
Cyclic Redundancy Check (CRC) is a widely used error-detecting code that can detect accidental
changes to raw data. It involves treating the data as a polynomial and performing division by a generator
polynomial. This record details the implementation process and the results of testing various scenarios.

Resource Required:
• C compiler (e.g., GCC, Dev C++)
• Text editor/IDE (e.g., Code::Blocks, Visual Studio Code)
• Sample data strings and polynomial values
Methodology:
1. CRC Algorithm Design:
o Implement the CRC algorithm in C by defining functions for:
▪ Generating the CRC polynomial.
▪ Performing binary division to calculate the CRC remainder.
▪ Appending the CRC remainder to the original data.
2. Code Implementation:
#include <stdio.h>
#include <string.h>
void xorOperation(char *dividend, const char *divisor) {
for (int i = 0; i < 4; i++) { // XOR the first 4 bits
dividend[i] = dividend[i] == divisor[i] ? '0' : '1';
}
}
void crcCalculation(char *data) {
char poly[] = "1001"; // Polynomial x^3 + 1 in binary
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

int dataLen = strlen(data);


for (int i = 0; i <= dataLen - 4; i++) {
if (data[i] == '1') {
xorOperation(&data[i], poly);
}
}

// CRC is the last 3 bits of the modified data


printf("Calculated CRC: %s\n", &data[dataLen - 3]);
}

int main() {
char data[20];

// Input binary data


printf("Enter binary data: ");
scanf("%s", data);

// Append 3 zeros to the data


strcat(data, "000");

// Perform CRC calculation


crcCalculation(data);

return 0;
}
3. Testing Scenarios:
• Prepare different data strings and polynomials to test the algorithm.
• Example data strings: "1101011011", "1011001", "011111", etc.
• Example polynomials: "10011", "1101", "1011", etc.
4. Execution:
• Compile and run the C program for each data string and polynomial.
• Record the CRC remainder obtained from each execution.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

Results:
• Create a table to record the data strings, polynomials, and calculated CRC remainders:
Data String Polynomial CRC Remainder
1101011011 10011 1010
1011001 1101 011
011111 1011 101
(Give your data strings, polynomials, and CRC remainders in the table. Do not copy the same)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 7

8. Create a network topology with three routers (Router A, Router B, and Router C) and connect
each to its respective department subnet. Implement a distance vector routing protocol such as RIP
on all routers to ensure connectivity between the Sales, Marketing, and HR departments.

Instructions:
1. Assign IP addresses to each router interface and department subnet.
2. Configure RIP on all routers to advertise connected networks.
3. Verify routing table entries on each router to ensure interdepartmental communication.
4. Document the configuration steps and provide evidence of successful communication between
departments. (CO3)

Objective:
To configure and implement dynamic routing using RIP in Cisco Packet Tracer, enabling automatic
route sharing between routers for seamless inter-network communication.

Introduction:
RIP (Routing Information Protocol) is a dynamic routing protocol that automatically updates routing
tables between routers in a network.

Resources Required:
• Cisco Packet Tracer software
• Three routers (e.g., Router-PT in Packet Tracer)
• Three PCs (PC-PT in Packet Tracer)
• Ethernet cables for LAN connections (Copper Straight-Through)
• Serial cables for router-to-router connections (Serial DCE)

Methodology:

Step 1: Set Up the Network Topology


• Use Packet Tracer to add at least 3 routers, 3 PCs, and necessary Serial/DCE cables for
router interconnections.
• Assign IP addresses to router interfaces and PCs as per your network design. Ensure each router has
at least two interfaces connected to different networks.

Step 2: Assign IP Addresses to Router Interfaces


• Router0:
o Click on Router0.
o Go to the Config tab.
▪ Select FastEthernet0/0 (connected to PC0) and assign an IP address (e.g., [Link]).
o Select Serial0/0/0 (connected to Router1) and assign an IP address (e.g., [Link]).
o Turn both interfaces ON.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

• Router1:
o Go to Router1, and configure interfaces FastEthernet0/0 and Serial0/0/0 (connected to
Router0) with appropriate IP addresses (e.g., [Link] for LAN, [Link] for Serial).
o Configure Serial0/0/1 (connected to Router2) with another IP (e.g., [Link]).
• Router2:
▪ On Router2, assign IPs to FastEthernet0/0 (e.g., [Link]), and Serial0/0/0 (e.g.,
[Link] connected to Router1).

Step 3: Configure RIP on Each Router


Router0:
1. Click on Router0.
2. Go to the Config tab.
3. Under the Routing section, select RIP.
4. Click Add to add the networks connected to this router. Add:
o [Link] (the network connected to the PC via FastEthernet0/0).
o [Link] (the network connected via Serial0/0/0 to Router1).
5. Save the configuration.
Router1:
1. Click on Router1.
2. Go to the Config tab.
3. Under Routing, select RIP.
4. Click Add and enter the networks:
o [Link] (connected to the PC on FastEthernet0/0).
o [Link] (connected to Router0 via Serial0/0/0).
o [Link] (connected to Router2 via Serial0/0/1).
5. Save the configuration.
Router2:
1. Click on Router2.
2. Go to the Config tab.
3. Under Routing, select RIP.
4. Add the networks:
o [Link] (connected to the PC on FastEthernet0/0).
o [Link] (connected to Router1 via Serial0/0/0).
5. Save the configuration.

Step 4: Verify RIP Configuration


• Once RIP is configured on all routers, you can check the routing table to ensure RIP has
successfully propagated routes to the neighboring routers.
• To do this, go to the Desktop tab of each PC and open the Command Prompt.
• Ping from one PC to another (e.g., ping from PC0 to PC2). If RIP is configured correctly, you
should be able to communicate across routers.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

Step 5: View RIP Routing Table


To verify that the routers have learned routes dynamically:
1. Click on each Router.
2. Go to the Config tab.
3. Under Routing, select RIP to see the networks RIP has learned and shared with other routers.

On each router, go to CLI and type:

Router# show ip route

Displays the RIP routes with an R next to them, indicating that these are routes learned via RIP.

Observation:
1. After configuring RIP on each router, the routing tables automatically update to include networks
connected to neighboring routers.
2. Successful pings between PCs on different networks verify that RIP is correctly propagating
routes across routers. (Write ping statistics of any one connection)
3. RIP dynamically adjusts routes, showing route entries marked with "R" in the routing table,
confirming successful communication across the network without manual static routes. (Write
the routes updated in CLI mode)

Result:
Dynamic routing using RIP was successfully configured, allowing automatic route sharing and enabling
seamless inter-network communication between devices across different networks.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 8

9. Design a network topology representing a university campus with multiple buildings and
routers connecting them. Implement a link-state routing protocol such as OSPF on all routers to
facilitate communication between different buildings.

Instructions:
1. Design the network topology with routers representing each building and appropriate
subnetting for each building.
2. Configure OSPF on all routers to advertise their connected networks and form adjacencies.
3. Verify OSPF neighbor relationships and routing table entries on each router to ensure proper
communication between buildings.
4. Document the OSPF configuration steps and provide evidence of successful routing between
different buildings. (CO3)

Objective:
To configure the OSPF routing protocol in a university campus network to ensure seamless
communication between buildings.

Resources Required:
• Cisco Packet Tracer software
• Routers to represent each building (e.g., Router-PT)
• PCs for testing connectivity
• Switches (if required for LAN connections within buildings)
• Ethernet and Serial cables for connections

Procedure:
1. Design the Topology:
Arrange routers and assign each building a separate subnet:

• Building A (Router0): Subnet [Link]/24


• Building B (Router1): Subnet [Link]/24
• Router0-Router1 link: Subnet [Link]/30

2. Configure IP Addresses:
o Assign IP addresses to each router’s interface based on the chosen subnet scheme.
o Ensure each PC in the network has an IP address within the assigned subnet.

3. CLI Configuration Steps:


• Router 0 Configuration:
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

• Router 1 Configuration:
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

4. Verify OSPF Neighbor Relationships:


• On each router, check OSPF neighbor status
Router# show ip ospf neighbor

5. Verify Routing Table Entries:


• Confirm that each router has learned about the other networks through OSPF
Router# show ip route

Observation and Results:


• OSPF Neighbor Adjacencies: Verified that OSPF neighbors were successfully formed
between routers.
• Dynamic Routing Table Updates: Routers dynamically learned routes to other subnets in the
network. (Write the routes updated in CLI mode)
• Connectivity: Successful pings between different buildings confirmed OSPF-enabled
communication. (Write ping statistics from PC0 to PC1)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 9
10. Design a network topology with a router, a switch, and at least three PCs connected to the switch.
Configure the router to act as a DHCP server and assign IP addresses dynamically to the PCs. Ensure
that the PCs can obtain IP addresses from the DHCP server successfully.

Instructions:
1. Set up the network topology with appropriate connections between the router, switch, and PCs.
2. Configure the router to act as a DHCP server, defining the IP address range, subnet mask, default
gateway, and DNS server (if applicable).
3. Configure the PCs to obtain IP addresses automatically via DHCP.
4. Verify that each PC has been assigned an IP address from the DHCP server and can communicate
with other devices on the network.
5. Document the DHCP configuration steps and provide evidence of successful IP address assignments
to the PCs. (CO3)

Objective
To set up a network topology with a router, switch, and three PCs where the router acts as a DHCP
server to dynamically assign IP addresses to the PCs.
Resources Required
• Cisco Packet Tracer software
• 1 Router
• 1 Switch
• 3 PCs
• Ethernet cables for connections
Procedure
1. Network Topology Setup:
o Connect Router0 to Switch0 using an Ethernet cable.
o Connect PC0, PC1, and PC2 to Switch0 using Ethernet cables.
2. Configuring the Router as a DHCP Server:
o On Router0, go to the Config tab.
o Select FastEthernet0/0 (or the interface connected to the switch), set the IP address to
[Link] and Subnet Mask to [Link], and enable the interface.
o Go to DHCP settings on Router0 and create a DHCP pool with the following settings:
▪ Network Address: [Link]
▪ Subnet Mask: [Link]
▪ Default Gateway: [Link]
▪ DNS Server: Set as required (optional)
CLI commands for configuring the router as a DHCP server:
1. Enter Global Configuration Mode:
enable
configure terminal
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

2. Configure the Interface Connected to the Switch (assuming FastEthernet0/0):


interface FastEthernet0/0
ip address [Link] [Link]
no shutdown
exit

3. Configure the DHCP Pool:


ip dhcp pool LAN
network [Link] [Link]
default-router [Link]
dns-server [Link] [Link] # Optional: Set DNS server
exit

4. Exclude the Router's IP from the DHCP Pool (so it doesn’t assign [Link] to another
device)

ip dhcp excluded-address [Link]

5. Exit Configuration Mode: end

Explanation of Commands:
• ip dhcp pool LAN: Creates a DHCP pool named "LAN" for assigning IP addresses.

• network [Link] [Link]: Defines the network and subnet mask for the DHCP pool.
• default-router [Link]: Sets the default gateway for DHCP clients (router’s IP).
• dns-server [Link] [Link]: Sets the DNS servers (optional).
This configuration enables the router to act as a DHCP server for the connected PCs.

3. Configuring the PCs to Obtain IP Addresses Automatically:


o For each PC (PC0, PC1, PC2):
▪ Go to the Desktop tab.
▪ Select IP Configuration.
▪ Set IP Configuration to DHCP.
4. Verification:
o On each PC, verify that it has received an IP address from the router’s DHCP server.
o Check that each PC has an IP address in the range 192.168.1.x and that the Default Gateway is
[Link].
o Test connectivity by pinging Router0 ([Link]) and other PCs on the network.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

Observation and Results


• All PCs successfully obtained IP addresses from the DHCP server configured on Router0. (Write the
IP addresses of PC’s assigned by DHCP server dynamically)
• PCs were able to communicate with the router and each other, confirming successful DHCP setup and
IP address allocation. (Write ping statistics of any one PC)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

Introduction to Wireshark Tool

Wireshark is a popular, open-source network protocol analyzer that enables users to capture and analyze
network traffic in real time. It's widely used by network administrators, security analysts, and IT
professionals for troubleshooting, monitoring network performance, and identifying security issues.

Purpose of Wireshark
• Network Troubleshooting: Helps identify network issues, such as packet loss, latency, and network
congestion.
• Security Analysis: Detects potential security threats by analyzing suspicious network traffic.
• Protocol Development: Useful for developers creating or testing network protocols.
• Educational Tool: Allows students and professionals to learn about network protocols and
communication.

Key Features of Wireshark


1. Packet Capture and Analysis: Captures real-time data from Ethernet, Wi-Fi, Bluetooth, and other
network types.
2. Deep Inspection: Analyzes packets down to each layer (from physical to application layer),
providing detailed information on protocols, headers, payloads, and errors.
3. Display Filters: Allows filtering of captured data based on IP addresses, protocols, ports, and other
parameters to focus on specific data.
4. Color Coding: Uses color coding to highlight different protocols and types of traffic, making it easier
to identify and analyze packets.
5. Statistics and Graphing: Provides insights into network performance and traffic patterns through
various statistical tools and visualizations.
6. Cross-Platform Compatibility: Available on Windows, macOS, and Linux.
7. Export Options: Supports exporting captured data in various formats for sharing or further analysis.

Installation Steps for Wireshark on Windows


1. Download Wireshark:
o Go to the official Wireshark website: [Link]
o Click on "Download" and select the Windows installer.
2. Run the Installer:
o Locate the downloaded file (typically Wireshark-win64-*.exe for 64-bit Windows).
o Double-click the installer to begin installation.
3. Accept License Agreement:
o Follow the prompts and accept the License Agreement.
4. Select Components:
o Choose the components to install. By default, all necessary components, including TShark
and plugins, are selected. For most users, the default options are recommended.
5. Install Npcap:
o Wireshark requires Npcap, a packet capture driver, to capture network traffic on Windows.
o During installation, you’ll be prompted to install Npcap. Follow the prompts to install it.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

o Note: You may see an option to install USBPcap if you need to capture USB traffic. This is
usually optional.
6. Choose Installation Location:
o Choose the destination folder or leave it at the default location.
7. Start Installation:
o Click “Install” to begin installing Wireshark and Npcap.
o Wait for the installation to complete.
8. Launch Wireshark:
o Once installation is complete, you can choose to launch Wireshark immediately.
o Click “Finish” to complete the installation process.

Running Wireshark
• Start Wireshark: Open Wireshark from the Start menu or desktop shortcut.
• Select Network Interface: Choose the network interface to capture packets (e.g., Wi-Fi, Ethernet).
• Capture and Analyze: Click on "Start Capturing" to begin and view captured packets in real-time.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

WEEK 10
11. Capture network traffic using Wireshark and analyze the performance of TCP and UDP in terms
of reliability, packet overhead, and throughput.

Instructions:
1. Simulate various network conditions (e.g., low bandwidth, high latency, and packet loss) using the
simulation tool.
2. Capture network traffic using Wireshark during data transmission.
3. Analyze the captured packets to evaluate the performance of TCP and UDP under different
network conditions.
4. Prepare a report summarizing your findings, including comparisons of reliability, packet
overhead, and throughput between TCP and UDP in each network condition.
5. Provide insights into the advantages and disadvantages of TCP and UDP based on your
observations. (CO4)

Objective
To capture and analyze the performance of TCP and UDP protocols in terms of reliability, packet
overhead, and throughput under real network conditions.
Resources Required
• Wireshark (Network Protocol Analyzer)
• TCP and UDP Applications for generating network traffic (e.g., web browsers for HTTP traffic,
iperf for specific TCP/UDP tests)
• A Computer or Virtual Machine running Wireshark

Theory
TCP (Transmission Control Protocol) is a connection-oriented protocol that ensures reliable data
transmission through acknowledgments and retransmissions. UDP (User Datagram Protocol) is
connectionless and faster, but it does not guarantee delivery. Analyzing these protocols under real-world
conditions helps identify their strengths and weaknesses.

Procedure
1. Set Up the Environment:
o Ensure you have Wireshark installed on your computer.
o Choose applications that utilize TCP and UDP. For instance:
▪ TCP: Web browsers, file transfer applications.
▪ UDP: Streaming applications, online games, or use iperf to generate UDP traffic.
2. Start Wireshark:
o Open Wireshark and select the network interface to capture traffic (e.g., Ethernet, Wi-Fi).
o Click on the "Start Capturing Packets" button.
3. Capture Traffic:
o Run the applications that generate TCP and UDP traffic. For example, open a web page (for
TCP) or stream a video (for UDP).
o Allow some time for traffic to be generated while Wireshark captures the packets.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

4. Stop Capture:
o Once sufficient data has been captured, stop the packet capture in Wireshark.
5. Apply Filters:
o Use display filters in Wireshark to focus on TCP and UDP traffic:
▪ For TCP: tcp
▪ For UDP: udp
o This helps in analyzing only the relevant packets.
6. Analyze Captured Data:
o TCP Analysis:
▪ Examine TCP packets for key details:
▪ Sequence and acknowledgment numbers
▪ Retransmissions (look for duplicate ACKs)
▪ TCP window size
▪ Packet overhead (header size)
o UDP Analysis:
▪ Observe UDP packets for:
▪ Packet loss (missing packets)
▪ Packet overhead (header size)
o Throughput Measurement:
▪ Measure the amount of data successfully delivered over time for both TCP and UDP:
▪ Use the "Statistics" menu in Wireshark to generate graphs and charts.
▪ Consider using "I/O Graphs" for visual throughput comparisons.
7. Document Findings:
o Record your observations on:
▪ Reliability: Note how TCP handles lost packets versus UDP.
▪ Packet Overhead: Compare the header sizes of both protocols.
▪ Throughput: Summarize the measured throughput for both protocols.

Observations and Results


• Reliability: TCP shows higher reliability due to its acknowledgment and retransmission
mechanisms, while UDP does not handle lost packets.
• Packet Overhead: TCP has higher overhead because of its connection-oriented nature. UDP has
minimal overhead.
• Throughput: UDP may exhibit higher throughput in less reliable networks due to its lack of
acknowledgment requirements.

Conclusion
• TCP: More reliable and suitable for applications where accurate data delivery is essential.
• UDP: Better suited for real-time applications where speed is critical and some data loss is acceptable.
ANITS | COMPUTER NETWORKS LAB | CSE (AI &ML, DS)

You might also like