Lab Manual
Lab Manual
Laboratory Manual
NAME
ENROLLMENT NUMBER
BATCH
YEAR
Ahmedabad Institute of Technology
Computer Engineering Department
CERTIFICATE
This is to certify that Mr. / Ms._________________________________ Of
Enrolment No ___________________________has Satisfactorily
completed the course in ____________________________________as by
the Gujarat Technological University for ____ Year (B.E.) semester___ of
Computer Engineering in the Academic year ______.
Date of Submission:-
INDEX
210020107076 CN(3150710) 2
Sr. EXPERIMENT PAGE DATE SIGN
No NO
210020107076 CN(3150710) 3
EXPERIMENT 1 DATE:
THEORY
Packet Tracer:
Packet Tracer is a protocol simulator developed by Dennis Frezzo and his team at Cisco
Systems. Packet Tracer (PT) is a powerful and dynamic tool that displays the various protocols
used in networking, in either Real Time or Simulation mode. This includes layer 2 protocols
such as Ethernet and PPP, layer 3 protocols such as IP, ICMP, and ARP, and layer 4 protocols
such as TCP and UDP. Routing protocols can also be traced.
The layout of Packet Tracer is divided into several components similar to a photo editor.
Match the numbering in the following screenshot with the explanations given after it:
● Area 1: Menu bar – This is a common menu found in all software applications; it is used to open,
save, print, change preferences, and so on.
210020107076 CN(3150710) 4
● Area 2: Main toolbar – This bar provides shortcut icons to menu options that are commonly
accessed, such as open, save, zoom, undo, and redo, and on the right-hand side is an icon for
entering network information for the current network.
● Area 3: Logical/Physical workspace tabs – These tabs allow you to toggle between the Logical and
Physical work areas.
● Area 4: Workspace – This is the area where topologies are created and simulations are displayed.
● Area 5: Common tools bar – This toolbar provides controls for manipulating topologies, such as
select, move layout, place note, delete, inspect, resize shape, and add simple/complex PDU.
● Area 6: Realtime/Simulation tabs – These tabs are used to toggle between the real and simulation
modes. Buttons are also provided to control the time, and to capture the packets.
● Area 7: Network component box – This component contains all of the network and end devices
available with Packet Tracer, and is further divided into two areas:
● Area 7a: Device-type selection box – This area contains device categories
● Area 7b: Device-specific selection box – When a device category is selected, this selection
box displays the different device models within that category
● Area 8: User-created packet box – Users can create highly-customized packets to test their topology
from this area, and the results are displayed as a list.
Make sure you are familiar with these names, because moving forward we will be referring to them
frequently.
Packet Tracer has two workspaces (Logical and Physical) and two modes (Realtime and Simulation). Upon
startup, you are in the Logical Workspace in Realtime Mode. You can build your network and see it run in
real time in this configuration. You can switch to Simulation Mode to run controlled networking scenarios.
You can also switch to the Physical Workspace to arrange the physical aspects (such as the location) of your
devices. Note that you view a simulation while you are in the Physical Workspace. You should return to the
Logical Workspace after you are done in the Physical Workspace.
STEP 1: First, add two computers, by going to the [End device] menu and dragging the PC icon until it looks
like this:
STEP 2: Then, connect the two PC using a cross-over cable or you can directly use an automatic cable so
that it will look like this:
210020107076 CN(3150710) 5
STEP 3: Then after the two PC are physically connected, the next step is to provide IP addresses to
the two PCs. In this way, “click PC0 – Desktop – IP Configuration” and adjust the ip address for
example:
○ Ip address : 192.168.2.1
○ subnet mask : 255.255.255.0
STEP 4: Do the same on another PC (PC1) with a different host ip address but on the same network for
example (192.168.1.3) and subnet mask 255.255.255.0
210020107076 CN(3150710) 6
STEP 5: So if indeed the two computers are connected and can communicate with each other then PC1 will
send a response back with the message “reply from 192.168.1.3 …” which is a sign of success. However, if
the process does not occur (timed out) on your display, pay attention to the IP addresses of the two
computers (PC0 and PC1) must be in one segment, namely 192.168.1…..you can change the host number as
long as the two hosts are different then the range of numbers that can be used is 1-255.
STEP 6: To do a ping test we can use the Command Prompt on virtual computers (PC0 and PC1), by
clicking on one of the computers (PC0) then go to “Command Prompt” and type:
EXERCISES:
i)Implement Peer to Peer network connection using CPT
ii)Implement network connection more than two nodes using hubs and Switch in CPT
EVALUATION:
_________________
210020107076 CN(3150710) 7
EXPERIMENT 2 DATE:
THEORY
There are two types of transmission media
• Guided – copper wires, fiber optic cable
• Unguided – Wireless (Radio Frequency / Microwave)
Information is transmitted over:
• Copper wire by varying the voltage or current time
• Fiber optic cable by pulsing light on / off in a fiber optic cable over time
• Radio waves or Microwaves by varying the frequency or amplitude over time
Guided transmission basics
• To transmit a single bit down a copper wire, we must send some electrical signal having two
discrete states to represent 0 and 1
• Examples: Voltage +5v = 1 0V = 0 Frequency 980 Hz =1 1180 Hz = 0
210020107076 CN(3150710) 8
Guided transmission media
• Guided transmission is where the signal (information or data) is sent through some sort of cable,
usually copper or optical fiber.
• There are many different types of cabling:
▪ Twisted Pair:
▪ Coaxial Cable (Coax)
▪ Fiber Optic Cable
Twisted Pair:
• This consists of two or more insulated wires twisted together in a shape similar to a helix.
• Use metallic conductor , The cables are twisted around each other to reduce the amount of
external interference
• It consists of two conductors (copper), each with its colored plastic insulation.
• This cable can be used at speeds of several Mb/s for a few kilometers.
• Used for telephone lines and lab networks.
Advantages of UTP
210020107076 CN(3150710) 10
T-connectors and terminators are used in bus topology.
Advantages:-
• Easy to Install.
• Inexpensive installation.
• It is better for Higher Distance at Higher speed than twisted pair.
• Excellent noise immunity.
Disadvantage:-
• High Cost
• Harder to work
o Light Source
o Transmission Medium
o Light Detector
This consists of a central glass core, surrounded by a glass cladding of lower refractive index, so
that the light stays in the core (using Total Internal Reflection)
• outside is covered with plastic jacket
• Many fibers may be bundled together surrounded by another plastic cover
210020107076 CN(3150710) 11
Refraction:- When Light travels from one medium to another medium changes occurs in its speed
and direction, this change is called refraction.
I - Angle of Incidence.
R- Angle of Refraction.
● Critical Angle:- At some points, the changes in the incident angle results in the refracted
angle of 90 degrees, with the refracted beam lying along the Horizontal. The incident angle at
this point is known as Critical Angle.
● Reflection:- When the angle of incidence becomes greater than the critical angle, a new
phenomenon is Occurs is called reflection.
● Light traveling of fiber optic cable
● The source of light is usually a Light Emitting Diode (LED) or a LASER. The light source is
placed at one end of the optical fiber.
● The detector, which is placed at the other end of the fiber, is usually a Photo Diode and it
generates an electrical pulse when light falls on it.
● Hence by attaching a light source on one end of an optical fiber and a detector at the other
end, we have a unidirectional data transmission system (Simplex)
● The light source would accepts an electrical signal, converts and transmits it as light pulses
● The detector at the far end reconverts the light pulses into an electrical signal to be then
interpreted as 1 or a 0.
Propagations Mode:
210020107076 CN(3150710) 12
● Fiber optic cables and network interface cards to connect a computer to the fiber are an order
of magnitude more expensive than their corresponding copper cable equivalents
● Cost is high
● Installation and maintenance is difficult.
● Higher Bandwidth.
1. Radio Transmission:
● Radio waves are easy to generate and can travel long distances and penetrate
buildings.
● Radio waves are omni-directional which basically means that they can transmit both
ways.
● The transmitter and receiver do not have to be in direct line of sight
2. Microwave Transmission:
● Different types of Propagation
● Surface Propagation (Ground Propagation)
● Sky Propagation.(Tropospheric Propagation, Ionospheric Propagation, Space
Propagation)
● Line-of-sight Propagation.
210020107076 CN(3150710) 13
● Unlike radio waves, microwaves typically do not pass through solid objects.
● Some Waves can be refracted due to atmospheric conditions and may take longer to arrive
than direct waves. These delayed waves can arrive out of phase with the direct wave, causing
destructive interference and corrupting the received signal This effect is called multipath
fading.
● Because of increased demand for more spectrum (range of frequencies used to transmit),
transmitters are using higher and higher frequencies.
● Microwave communication is widely used for long distance telephone communication and
cell phones.
● Microwave signals propagates in one direction at a time which means two different
frequencies are necessary for two way communication.
3. Infrared:
● Infrared signals can be used for short-range communication in a closed area using line-of-
sight propagation.
● Transceivers must be within line of sight of each other or via reflection.
● Does not penetrate walls like microwave.
● No frequency allocation or licensing.
EXERCISES:
i)Compare different types of light source which we can use in optical fiber.
ii)List out different types of wired media used in computer labs with their specification.
EVALUATION:
210020107076 CN(3150710) 14
Involvement(4) Understanding/ Timely Completion(3) Total(10)
Problem Solving(3)
________________
EXPERIMENT 3 DATE:
THEORY:
210020107076 CN(3150710) 15
NAME FUNCTION
210020107076 CN(3150710) 16
digital data into analog data when the
data is being sent by the computer.
The demodulator converts analog data
signals into digital data when it is
being received by the computer.
210020107076 CN(3150710) 17
Repeater A repeater operates at the physical layer. Its
job is to regenerate the signal over the same
network before the signal becomes too weak
or corrupted so as to extend the length to
which the signal can be transmitted over the
same network. An important point to be
noted about repeaters is that they do not
amplify the signal. When the signal becomes
weak, they copy the signal bit by bit and
regenerate it at the original strength. It is a 2
port device.
210020107076 CN(3150710) 18
Switch is a network device that connects other
Switch devices to Ethernet networks through twisted
pair cables. It uses packet switching technique to
receive, store and forward data packets on the
network. The switch maintains a list of network
addresses of all the devices connected to it.
On receiving a packet, it checks the destination
address and transmits the packet to the correct
port. Before forwarding, the packets are checked
for collision and other network errors. The data
is transmitted in full duplex mode
210020107076 CN(3150710) 19
Wi-Fi is the acronym for wireless fidelity. Wi-Fi
Wi-Fi technology is used to achieve wireless
Card connection to any network. Wi-Fi card is a card
used to connect any device to the local network
wirelessly. The physical area of the network
which provides internet access through Wi-Fi is
called Wi-Fi hotspot. Hotspots can be set up at
home, office or any public space. Hotspots
themselves are connected to the network through
wires.
A Wi-Fi card is used to add capabilities like
teleconferencing, downloading digital camera
images, video chat, etc. to old devices. Modern
devices come with their in-built wireless
network adapter.
EXERCISES:
EVALUATION:
________________
210020107076 CN(3150710) 20
EXPERIMENT 4 DATE:
THEORY:
1) BUS Topology
Bus topology is a network type in which every computer and network device is connected to single
cable. When it has exactly two endpoints, then it is called Linear Bus topology.
210020107076 CN(3150710) 21
● Cable required is least compared to other network topology.
● Used in small networks.
● It is easy to understand.
Advantage:-
● Easy to Construct
● Cost is Low
Disadvantage:-
● Traffic is High
● If Link is Break Then no one can communicate with others.
● Difficult to add new add Devices.
● If Link is Break Then no one can communicate with others.
2) STAR TOPOLOGY
In this type of topology all the computers are connected to a single hub through a cable. This hub is
the central node and all others nodes are connected to the central node.
210020107076 CN(3150710) 22
● Easy to setup and modify.
● Only that node is affected which has failed, rest of the nodes can work smoothly.
3) RING TOPOLOGY
It is called ring topology because it forms a ring as each computer is connected to another computer,
with the last one connected to the first. Exactly two neighbours for each device.
210020107076 CN(3150710) 23
● Transmitting network is not affected by high traffic or by adding more nodes, as only the
nodes having tokens can transmit data.
● Cheap to install and expand
4) MESH TOPOLOGY
It is a point-to-point connection to other nodes or devices. All the network nodes are connected to
each other. Mesh has n(n-1)/2 physical channels to link n devices.All the node has multiple paths to
reach at Particular any one location.
Advantage:-
● Reachability is high.
● Provide much Protection.
● Used at a nuclear power plant
Disadvantage:-
● Cost is high.
● Very Complex to Build.
● Maintenance is also high.
210020107076 CN(3150710) 24
5) HYBRID TOPOLOGY
It is two different types of topologies which is a mixture of two or more topologies. For example if in
an office in one department ring topology is used and in another star topology is used, connecting
these topologies will result in Hybrid Topology (ring topology and star topology).
EXERCISES:
iii)What are the advantage of ring topology over the star topology
iv) Write the difference between ring topology and mesh topology
EVALUATION:
210020107076 CN(3150710) 25
Signature with date
________________
EXPERIMENT 5 DATE:
know more different types of static and dynamic routing and how to
configure DHCP using CPT
THEORY:
210020107076 CN(3150710) 26
destination. The metric used might be number of hops, time delay in milliseconds, total number of
packets queued along the path, or something similar.
Router configuration:
Router-1 Configuration
Router>
Router>enable
Router#configure terminal
Router(config)#hostname Router1
Router1(config)#interface fastethernet 0/0
Router1(config-if)#ip address 10.1.1.100 255.0.0.0
Router1(config-if)#no shutdown
Router1(config-if)#exit
Router1(config)#interface fastethernet 1/0
Router1(config-if)#ip address 20.1.1.100 255.0.0.0
Router1(config-if)#no shutdown
Router1(config-if)#exit
Router1(config)#router rip
Router1(config-router)#network 10.0.0.0
Router1(config-router)#network 20.0.0.0
Router-2 Configuration
Router>
Router>enable
Router#configure terminal
Router(config)#hostname Router2
Router2(config)#interface fastethernet 0/0
Router2(config-if)#ip address 20.1.1.200 255.0.0.0
Router2(config-if)#no shutdown
Router2(config-if)#exit
Router2(config)#interface fastethernet 1/0
Router2(config-if)#ip address 30.1.1.100 255.0.0.0
Router2(config-if)#no shutdown
Router2(config-if)#exit
Router2(config)#router rip
Router2(config-router)#network 20.0.0.0
210020107076 CN(3150710) 27
Router2(config-router)#network 30.0.0.0
Router-3 Configuration
Router>
Router>enable
Router#configure terminal
Router(config)#hostname Router3
Router3(config)#interface fastethernet 0/0
Router3(config-if)#ip address 30.1.1.200 255.0.0.0
Router3(config-if)#no shutdown
Router3(config-if)#exit
Router3(config)#interface fastethernet 1/0
Router3(config-if)#ip address 40.1.1.100 255.0.0.0
Router3(config-if)#no shutdown
Router3(config-if)#exit
Router3(config)#router rip
Router3(config-router)#network 30.0.0.0
Router3(config-router)#network 40.0.0.0
210020107076 CN(3150710) 28
and renews these addresses as devices leave and re-join the network. Internet Service Providers
(ISPs) usually use DHCP to allow customers to join the Internet with minimum effort. The DHCP
server maintains a database of available IP addresses and configuration information. When it receives
a request from a client, the DHCP server determines the network to which the DHCP client is
connected, and then allocates an IP address. DHCP servers typically grant IP addresses to clients
only for a limited interval. Let's apply DHCP on a packet tracer.
First, let us make a topology with one router on which we will apply DHCP and several client PCs.
More like this one,
Now, we will apply DHCP on the router. The commands in sequence are as follows.
In the following command “ip dhcp pool cisco”, we are creating a pool for DHCP called cisco. cisco
is the name here and we can name it whatever we want. Similarly, in the command “default-router “
we are telling the DHCP about the default route to follow.
Notice, after we exit from DHCP mode, we are excluding some IP addresses by applying this
command “ip dhcp excluded-addresses x-x”, where x is the starting and ending IP address
respectively. We are basically reserving some IPs for our use. It can be used to attach printers, or
assign it to some specific users for security purposes. You can also give
dns address in dhcp by using the following command. dns- server 192.168.1.15.
210020107076 CN(3150710) 29
Click on IP Configuration
And after DHCP request is completed you will see the following screen.
Now, after applying some IPs in sequence, DHCP will skip the IPs that we have excluded from our
DHCP pool.
EXERCISE:
210020107076 CN(3150710) 30
1) Connect different networks using two routers and configure them using RIP protocols. (Write the
steps for each Routing Configuration.)
2) Connect different networks using three routers and configure them using RIP protocols. (Write the
steps for each Routing Configuration.)
EVALUATION:
________________
EXPERIMENT 6 DATE:
OBJECTIVES: After completing study of this practical the students will be familiarized
with...
➢ Concept of VLAN
THEORY:
VLAN:
● VLAN refers to Virtual Local Area Network
● VLAN extends its functionalities beyond a single LAN through VLAN a network is divided
into different logical segments which are known as broadcast domains.
210020107076 CN(3150710) 31
● All devices, by default, are in VLAN 1.
● For devices in different VLANs to communicate, you must use a router or Layer 3 switch.
We are creating a simple VLAN. We will take Four PC & one switch. We will create two VLAN
name “VLAN8” and “VLAN9”.Then we put ports 1 & 2 into VLAN 8 and ports 3 & 4 into
VLAN9.Then we will check how the communication is done between different nodes.
Switch>enable
Switch#configure terminal
Switch(config)#hostname Vlan_Switch
Vlan_Switch(config)#vlan 8
Vlan_Switch(config)#interface fastethernet0/1
Vlan_Switch(config-if)#exit
Vlan_Switch(config)#interface fastethernet0/2
210020107076 CN(3150710) 32
Vlan_Switch(config-if)#switchport mode access
Vlan_Switch(config-if)#exit
Vlan_Switch(config)#interface fastethernet0/3
Vlan_Switch(config-if)#exit
Vlan_Switch(config)#interface fastethernet0/4
Vlan_Switch(config-if)#exit
PC1
IP Address....................... : 10.1.1.1
PC2
IP Address....................... : 10.1.1.1
IP Address....................... : 10.1.1.2
PC3
IP Address....................... : 10.1.1.3
PC4
210020107076 CN(3150710) 33
IP Address....................... : 10.1.1.4
PC1:>ping 10.1.1.2
Ping statistics for 10.1.1.2: Packets: Sent = 5, Received = 5, Lost = 0 (0% loss),
PC1:>ping 10.1.1.3
PC1:>ping 10.1.1.4
210020107076 CN(3150710) 34
Request timed out.
Vlan_Switch#
Vlan_Switch#show vlan
EXERCISES:
i) Create the Two VLAN from one LAN and write the configuration steps.
210020107076 CN(3150710) 35
EVALUATION:
________________
EXPERIMENT 7 DATE:
OBJECTIVES: After completing study of this practical the students will be able to
Practically implement the cross- wired cable and straight through cable
using crimping tool.
THEORY:
210020107076 CN(3150710) 36
careful at this point, as to not nick or cut into the wires, which are inside. Doing so could
alter the characteristics of your cable, or even worse render is useless. Check the wires, one
more time for nicks or cuts. If there are any, just whack the whole end off, and start over.
2. Spread the wires apart, but be sure to hold onto the base of the jacket with your other hand. You do
not want the wires to become untwisted down inside the jacket. Category 5 cable must only have 1/2
of an inch of 'untwisted#39; wire at the end; otherwise it will be 'out of spec v#39;. At
this point, you obviously have A LOT more than 1/2 of an inch of un-twisted wire.
3. You have 2 end jacks, which must be installed on your cable. If you are using a pre- made cable,
with one of the ends whacked off, you only have one end to install - the crossed over end. Below are
two diagrams, which show how you need to arrange the cables for each type of cable end. Decide at
this point which end you are making and examine the associated picture below.
210020107076 CN(3150710) 37
Diagram shows you how to prepare straight through wired connection
4. Align the untwisted wires in the order necessary for your needs. For this scenario, you'll be
making a straight-through cable, which has both ends of the cable with the same alignment of
wires, so it's easy enough to do. Since this is your first cable, we'll consult the cheat sheet to
know what order we're aligning in!
5. Cut the extra wire. Once you've untwisted the wires, you'll have a superfluous amount of copper
wiring left; we don't need this much, but it's good to have it in the previous step to help in aligning
the colors properly. Use the wire-cutting scissors to cut these off.
6. Push the remaining wires into the RJ45 head. Be careful not to bend the wires while pushing them
in or you run the risk of creating a bad cable. You also don't want too little or too much wire left in
the head; there's no definite length necessary, but it's pretty obvious to tell if there's too much cable
210020107076 CN(3150710) 38
or not enough. A short length of the jacket should be up the RJ45 head; use this knowledge as a
reference.
7. Push the head into the open space of the crimping tool and squeeze it closed, hard. If you don't
crimp the cable all the way, the head may come off.
EVALUATION:
Involvement(4) Understanding/Problem Timely Total(10)
Solving(3) Completion(3)
________________
EXPERIMENT 8 DATE:
OBJECTIVES: After completing study of this practical the students will be familiarized
with...
210020107076 CN(3150710) 39
various operating systems.
THEORY:
1) Ping
ping: ping(8) sends an ICMP ECHO_REQUEST packet to the specified host. If the host
responds, you get an ICMP packet back. Sound strange? Well, you can “ping” an IP address
to see if a machine is alive. If there is no response, you know something is wrong.
2) ipconfig
shows the IP address, subnet mask, and default gateway. The IP address and the default
gateway should be in the same network or subnet, otherwise this host would not be able to
communicate outside the network. In the figure the subnet mask tells us tha the first three
octets must be the same to be in the same network.
210020107076 CN(3150710) 40
3) ipconfig /all
The host name, including the computer name and NetBIOS name should be displayed. Also,
the DHCP server address, if used, and the date the IP lease starts and ends should be
displayed. Look over the information. Entries for the DNS, used in name resolution servers,
may also be present. The previous figure reveals that the router is performing DHCP services
for this network. This would likely be a small office or home office (SOHO) or small branch
office implementation.
4) Traceroute:
Tracert is a command which can show you the path a packet of information takes from your
computer to one you specify. It will list all the routers it passes through until it reaches its
destination, or fails to and is discarded. In addition to this, it will tell you how long each hop
from router to router takes.
5) nslookup
Displays information from Domain Name System (DNS) name servers.
NOTE :If you write the command as above it shows as default your pc server name firstly.
6) pathping
210020107076 CN(3150710) 41
A better version of tracert that gives you statics about packet lost and latency.
7) Getting help
In any command mode, you can get a list of available commands by entering a question mark
(?).
Router>?- To obtain a list of commands that begin with a particular character sequence, type
in those characters followed immediately by the question mark (?).
Configuration Files
Any time you make changes to the router configuration, you must save the changes to
memory because if you do not they will be lost if there is a system reload or power outage.
There are two types of configuration files: the running (current operating) configuration and
the startup configuration.
Use the following privileged mode commands to work with configuration files.
• configure terminal – modify the running configuration manually from the terminal.
210020107076 CN(3150710) 42
• erase startup-config – erase the startup-configuration in NVRAM. • copy tftp running-
config – load a configuration file stored on a Trivial File Transfer Protocol (TFTP) server into
the running configuration.
EXERCISES:
EVALUATION:
_________________
210020107076 CN(3150710) 43