0% found this document useful (0 votes)
5 views

CN_LAB_Assignment1

The document outlines a lab assignment for configuring network devices and establishing connectivity between PCs using Cisco Packet Tracer. It includes tasks such as assigning static IP addresses, creating various network topologies, configuring routers and switches, and implementing dynamic routing protocols like RIP. Additionally, it covers subnetting concepts and provides detailed steps for testing connectivity and securing remote access to routers.

Uploaded by

harshdub22
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

CN_LAB_Assignment1

The document outlines a lab assignment for configuring network devices and establishing connectivity between PCs using Cisco Packet Tracer. It includes tasks such as assigning static IP addresses, creating various network topologies, configuring routers and switches, and implementing dynamic routing protocols like RIP. Additionally, it covers subnetting concepts and provides detailed steps for testing connectivity and securing remote access to routers.

Uploaded by

harshdub22
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 61

CN LAB Assignment

Kartik Gupta
2200291520096
Connect two PCs using Packet Tracer.

Assign IP address using Ip configuration.


Ip address for PC0 is 192.168.1.1 and for PC1 is 192.168.1.2.
After Assigning IP addresses, open Comand Prompt and Ping the IP address of PC1 from PC0.
Connect Three PCs using Hub.
Assign IP addresses to each PC.
PC0: 192.168.1.1
PC1: 192.168.1.2
PC3: 192.168.1.3

Ping all PCs.


Connect Three PCs using Switch.

Assign IP addresses to all PCs.


Ping all the PCs.
2. Task: Create following topologies using Cisco Packet Tracer.
Bus Topology

Ring Topology

Start Topology
Mesh Topology

3. Static IP Configuration in Routers


Connecting Two Computers using Routers
Establish the following scenario given in figure below:

Double click on router and open CLI.


Enter the following commands:

Enter these Commands for Serial Port 0/0 as well.


Do the same process for Router 1 as well.

Check the connection by message passing.

Scenario # 2

Assign given IP addresses to PCs


Add IPs to Router 0’s Interface
Add IPs to Router 1’s Interface

Check Connectivity by message passing.


3. Configuration of Network Devices : Demonstrate the
configuration of Router, Hub, and Switch.

Step 1:

●​ Connect R1 G0/0/1 to any port on S1.


●​ Connect PCA to any port on S1.
●​ Connect PCB to R1 G0/0/0.

●​ PCA uses (FastEthernet0) to connect with Switch 1


●​ We can connect the PCA to any FastEthernet interface on Switch 1 (from
FastEthernet0/2 to FastEthernet 0/10/24)
●​ Switch 1 uses the FastEthernet 0/1 to connect with Router 1.

Step 2:

In this step, you will assign static IPv4 addressing information to the PC interfaces. Use
the information in the Addressing Table to complete the task.

●​ Configure the IPv4 address, subnet mask, and default gateway settings on
PCA .
●​ Configure the IPv4 address, subnet mask, and default gateway settings on
PCB .

Click on PCA computer icon, on the PCA desktop click on IP Configuration

PCA Desktop

Hint: The following values are found in the Addressing Table. Enter them in the IP
Configuration for PCA .

●​ IP Address: 192.168.1.3
●​ Subnet Mask: 255.255.255.0
●​ Default Gateway: 192.168.1.1

PCA IP Configuration

Click on PCB computer icon, on the PCB desktop click on IP Configuration


PCB Desktop

The following values are found in the Addressing Table. Enter them in the IP
Configuration for PCB .

●​ IP Address: 192.168.0.3
●​ Subnet Mask: 255.255.255.0
●​ Default Gateway: 192.168.0.1
PCB IP Configuration

Step 3:

In this step, you will Test connectivity between PCA and PCB.

●​ Ping between PCA and PCB.


Hint: In the PCA Command Prompt, enter the ping 192.168.0.3 command. You can also
open the PCB Command Prompt, and then enter the ping 192.168.1.3 command.

Why were the pings not successful?

●​ Yes

The router interfaces, which are the default gateways for each PC, have not been
configured yet; therefore, the ping traffic is not being routed between the PCA and PCB
networks. Note that link lights on the connections from the router are red. This
indicates that the links are not functioning.

Router links are down


Step 4:

In this step, you will use the CLI tab for R1 to configure basic settings. You can connect a
Console cable and access the CLI from PCA or PCB, if you wish. However, in this
activity, you can also just click R1 to open it.
R1 Configuration

●​ Assign a hostname according to the Addressing Table.

Hint: If necessary, click R1. Then enter the following command:


Router>enable

Router# configure terminal

Router(config)# hostname R1

●​ Assign class as the privileged EXEC encrypted password.

Configure the privileged EXEC mode password in global configuration mode with the
following command:

R1(config)# enable secret class

●​ Assign cisco as the console password and enable login.

Enter line configuration mode in global configuration mode with the following
command:

R1(config)# line con 0

Configure the console password with the following command:

R1(config-line)# password cisco

Configure the console line to require login:

R1(config-line)# login
●​ Encrypt the plaintext passwords.

Encrypt plaintext passwords with the following command in global configuration mode:

R1(config)# service password-encryption

●​ Create a banner that warns anyone accessing the device that unauthorized
access is prohibited.

Configure a banner with the following command:

R1(config)# banner motd $Authorized Access Only!$

In this example, $ is the delimiter.

●​ For G0/0/0, configure IP addressing according to the Addressing Table and


activate the interface.

Enter interface configuration mode with the following command:

R1(config)# interface g0/0/0

Configure the G0/0/0 interface with the following command with the following
command:

R1(config-if)# ip address 192.168.0.1 255.255.255.0


●​ For G0/0/1, configure IP addressing according to the Addressing Table and
activate the interface.

Enter interface configuration mode with the following command:

R1(config)# interface g0/0/1

R1(config-if)# ip address 192.168.1.1 255.255.255.0

R1(config-if)# no shutdown

●​ Save the running configuration to the startup configuration file.

R1(config)# exit

R1# copy running-config startup-config

Destination filename [startup-config]?

Building configuration...

[OK]

You can also use the abbreviated copy run start or the write mem command

Step 5:
Now, let’s test connectivity between PCA and PCB again.

●​ Ping between PCA and PCB.

Hint: In the PCA Command Prompt, Enter the ping 192.168.0.3 command. You can also
open the PCB Command Prompt, and then enter the ping 192.168.1.3 command.

Why were the pings between PCA and PCB successful?

●​ Yes

The router is routing the ping traffic across the two networks. The default settings for
the 2960 switch will automatically enable the interfaces that are connected to devices.
Route Links are UP

Step 6:

In this step, you will use the CLI tab for S1 to configure basic settings. You can connect a
console cable and access the CLI from PCA or PCB, if you wish. However, in this activity,
you can also just click S1 to open it.
S1 Configuration

●​ Assign a hostname according to the Addressing Table

If necessary, click S1. Then enter the following command:


Switch> enable

Switch# configure terminal

Switch(config)# hostname S1

●​ Assign class as the privileged EXEC encrypted password.

Configure the privileged EXEC mode password in global configuration mode with the
following command:

S1(config)# enable secret class

●​ Assign cisco as the console password and enable login.

Enter line configuration mode in global configuration mode with the following
commands:

S1(config)# line con 0

S1(config-line)# password cisco

S1(config-line)# login

●​ Encrypt the plaintext passwords.

Encrypt plaintext passwords with the following command in global configuration mode:
S1(config)# service password-encryption

●​ Create a banner that warns anyone accessing the device that unauthorized
access is prohibited.

Configure a banner with the following command:

S1(config)# banner motd $Authorized Access Only!$

In this example, $ is the delimiter.

●​ For VLAN 1, configure IP addressing according to the Addressing Table and


activate the interface.

Enter interface configuration mode with the following commands:

S1(config)# interface vlan 1

S1(config-if)# ip address 192.168.1.2 255.255.255.0

S1(config-if)# no shutdown

●​ Configure the default gateway according to the Addressing Table

Configure the default gateway with the following command:

S1(config)# ip default-gateway 192.168.1.1


●​ Save the running configuration to the startup configuration file.

Save the configuration with the following command:

S1(config)# exit

S1# copy running-config startup-config

You can also use the abbreviated copy run start or the write mem command

Step 7:

In this step, you will Secure remote access to R1.

Hint: If necessary, log back in to R1 with the password cisco, enter privileged EXEC
mode with the password class.
●​ On R1, configure the domain name as academy.net.

Enter the following command:

R1(config)# ip domain-name academy.net


●​ Generate RSA keys with a 1024 key length

Enter the following command:

R1(config)# crypto key generate rsa

Enter 1024 for How many bits in the modulus [512] question.

●​ Create a user with SSHuser as the username and cisco as the secret
password.

Enter the following command:

R1(config)# username SSHuser secret cisco

●​ Configure the VTY lines to use the local username database for login
credentials. The VTY lines should only allow SSH for remote access.

Enter the following command:

Enter the following command:

R1(config)# line vty 0 4

R1(config-line)# login local

R1(config-line)# transport input ssh


Step 8:

Now, let’s verify SSH remote access.

●​ From PCA or PCB, use the Command Prompt to establish a secure session
with R1. At the prompt, use the ssh

4 . Dynamic IP using RIP configuration


What is Routing Information Protocol (RIP)?

▪​ RIP is an open source routing protocol, what it means RIP is compatible with all routers
more than Cisco.

▪​ RIP is Distance vector based Interior Gateway Routing Protocol (IGP).

– What is an IGP? An Interior Gateway Protocol (IGP) is a kind of protocol used for
interchanging routing information between gateways (commonly routers) within an
Autonomous System
– What is Distance vector? Distance vector protocols use a distance calculation together
with outgoing network interface (a vector) to choose the best path to a destination network.

▪​ RIP is the simplest and easiest routing protocol to configure. Every routing protocol has
its own metric to calculate best path available.

▪​ RIP utilizes ‘hop count’ as metric to decide the best path among two locations (Here hop
count is calculated by Distance Vector Algorithm).
(I will be posting separate article covering Metric, Administrative Distance, Distance Vector, etc.)
– Hop count: Which is the number of routers the packet need go through until it reaches the
destination network.

▪​ The extreme acceptable number of hops in RIP network is 15 hops. Means the packet
will not be able to reach at the target if the destination is apart from 15 hops.

▪​ Two variations of RIP are RIP Version 1 and RIP Version 2.

▪​ RIP Applied in small networks having less than 15 hops.


▪​ In a RIP enabled network, every router broadcasts its entire RIP table to its adjacent
routers in each 30 seconds.

▪​ When a router receives a neighbor’s RIP table, it updates its own routing table from the
received information and then broadcast updated routing table to the adjacent router
RIP Configuration
Create a practice lab as shown in following figure or download this pre-created practice lab and
load in packet tracer.

Scenario 1
Consider the following network.

Configure IP address on PC0


Configure IP address on PC1
Configure Serial port 2/0 of router 0

Configure Serial port 2/0 of router 1


You can see all green.
Now Configure RIP protocol on Router0 and add all networks attached to it.
Add Second Network i.e. 10.0.0.0
Now go on the settings of Router0 and click on NVRAM’s save button
Do the whole process for Router1
6. SUBNETTING

o Demonstrate subnetting by dividing a network into sub-networks and assigning


appropriate IP ranges. ​

The main IP address is 192.168.1.0/24, which refers to the 24 subnet masks you
see here. The first subnet mask is therefore 3 octets filled with 1’s and 1 octet
filled with 0's.

For example, I want to split this network into 4 subnets so I have to calculate the
bits I will borrow in the subnet mask. For this, there is a formula called
2^m=subnet.
Replacing it, the number of bits I need is 2. If we take these two bits from the
subnet mask, you will see that the two bits of the last octet are one. This is my
new subnet mask. If we convert the subnet mask from binary to base decimal by
using the places of one bits, 2⁷ +2⁶= 192. So my new subnet mask is
255.255.255.192.

-​ use the remaining 6 host bits to determine the number of IPs that will fall on
each subnet. 2⁶-2=62 units. The reason we do minus 2 is that one of these IPs
is for Subnet IP and the other is for broadcast IP.

-​ created a topology. These are routers and these networks are subnet

The figure below is an improved version of the topology. computers their IP


addresses and the IP addresses that fall into the router interfaces.
-​ connected a copper pass-thru between the computer switch and the router
switch. And I connected serial DCE cable to establish a serial connection
between the two routers.
Then go to IP configuration and set the computer’s IP address, subnet mask and
default gateway. The default gateways here are the IP addresses of the router
interfaces facing the PCs. This is how the IP settings of all computers are made.
It’s time for the routers to connect. CLI section of the router and I activate it by
typing “enable”

“configure terminal” to put it in configuration mode


Router 2.
the subnet mask and

-IP route command.

İmprovement

An improvement can be made to prevent excessive IP usage.


8. Dynamic Routing Across Multiple Networks o Configure and
demonstrate dynamic routing among three different networks using
suitable routing protocols.
Step 1: First, open the Cisco packet tracer desktop and select the devices
given below:

S.NO Device Model Name Qty.

1. PC PC 6

2. Switch PT-Switch 3

3. Router PT-router 3

IP Addressing Table:

IPv4 Default
S.NO Device Subnet mask
Address Gateway
1. PC0 192.168.10.2 255.255.255.0 192.168.10.1

2. PC1 192.168.10.3 255.255.255.0 192.168.10.1

3. PC2 192.168.20.2 255.255.255.0 192.168.20.1

4. PC3 192.168.20.3 255.255.255.0 192.168.20.1

5. PC4 192.168.30.2 255.255.255.0 192.168.30.1

6. PC5 192.168.30.3 255.255.255.0 192.168.30.1

●​ Then, create a network topology as shown below the image.

●​ Use an Automatic connecting cable to connect the devices with

others.
Step 2: Configure the PCs (hosts) with IPv4 address and Subnet Mask
according to the IP addressing table given above.
●​ To assign an IP address in PC0, click on PC0.

●​ Then, go to desktop and then IP configuration and there you will

IPv4 configuration.

●​ Fill IPv4 address and subnet mask.


●​ Assigning an IP address using the ipconfig command, or we can

also assign an IP address with the help of a command.

●​ Go to the command terminal of the PC.


●​ Then, type iPConfig <IPv4 address><subnet mask><default

gateway>(if needed)

Example: iPConfig 192.168.10.2 255.255.255.0 192.168.10.1


●​ Repeat the same procedure with other PCs to configure them

thoroughly.

●​ To assign an IP address in router0, click on router0.

●​ Then, go to config and then Interfaces.

●​ Make sure to turn on the ports.

●​ Then, configure the IP address in FastEthernet and serial ports

according to IP addressing Table.

●​ Fill IPv4 address and subnet mask.


●​ Repeat the same procedure with other routers to configure them

thoroughly.

Step 4: After configuring all of the devices we need to assign the routes to
the routers.
To assign RIP routes to the particular router:
●​ First, click on router0 then Go to CLI.

●​ Then type the commands and IP information given below.

CLI command : router rip


CLI command : network <network id>

RIP Routes for Router0 are given below:


Router(config)#router rip
Router(config-router)#network 192.168.10.0
Router(config-router)#network 10.0.0.0

RIP Routes for Router1 are given below:


Router(config)#router rip
Router(config-router)#network 192.168.20.0
Router(config-router)#network 10.0.0.0
Router(config-router)#network 11.0.0.0

RIP Routes for Router2 are given below:


Router(config)#router rip
Router(config-router)#network 192.168.30.0
Router(config-router)#network 11.0.0.0

Step 5: Verifying the network by pinging the IP address of any PC.


●​ We will use the ping command to do so.

●​ First, click on PC0 then Go to the command prompt.

●​ Then type ping <IP address of targeted node>.

●​ As we can see in the below image we are getting replies which

means the connection is working properly.

You might also like