Professional Documents
Culture Documents
LAB SHEET
Submitted to:
Department of Computer Science and information Technology
Objective
i. To study the basic commands of computer networking.
ii. To learn how to configure, monitor and troubleshoot the network.
Theory
In computing, a command is a directive to a computer program to perform a specific task. It may
be issued via a command-line interface, such as a shell, or as input to a network service as part of
a network protocol, or as an event in a graphical user interface triggered by the user selecting an
option in a menu.
The network infrastructure is a very complex structure of cables, routers, access points, data
packets and a million other small components that together make the entire network work
seamlessly. Any issue in any of these smaller components may lead to an overall collapse of the
network infrastructure. This may lead to disruption of Wi-Fi, cellular and wired (Ethernet)
infrastructure. This is the reason why it is very important to have an access to how the network is
performing and know troubleshooting techniques.
The operating system acts as an intermediate platform between the user and the underlying
network infrastructure. To use the below commands in Windows operating system, one needs to
click on Start, go to Run and type cmd. This will open up the command prompt. In Mac OS, you
can use the terminal application.
Some of the frequently used networking commands are listed below:-
1. Hostname
To communicate with each and other, the computer needs a unique address. A hostname can be
alphabetic or alphanumeric, and contain specific symbols used specifically to define a specific
node or device in the network. For example, a hostname should have a domain name (TLD) of
the top-level and a distance of between one and 63 characters, when it is used in a domain name
system (DNS) or on the Internet.
2. Ipconfig
The command IP config will display basic details about the device’s IP address configuration.
Just type IP config in the Windows prompt and the IP, subnet mask and default gateway that the
current device will be presented. If you have to see full information then type on command
prompt config-all and then you will see full information. There are also choices to assist you to
resolve DNS and DHCP issues.
2|Page
3. Ping
The command ping verifies IP-level connectivity to another TCP/IP computer by sending
Internet Control Message Protocol (ICMP) Echo Request messages. The receipt of
corresponding Echo Reply messages are displayed, along with round-trip times. Ping is the
primary TCP/IP command used to troubleshoot connectivity, reachability, and name resolution.
Ping can be used to test both the computer name and the IP address of the computer. If pinging
the IP address is successful, but pinging the computer name is not, you might have a name
resolution problem. In this case, ensure that the computer name you are specifying can be
resolved through the local Hosts file, by using Domain Name System (DNS) queries, or through
NetBIOS name resolution techniques.
4. Netstat
Netstat is a Common TCP – IP networking command-line method present in most Windows,
Linux, UNIX, and other operating systems. About the protocol, the netstat provides the statistics
and information in the use of the current TCP-IP Connection network.
There are various options a user can use with the Netstat command.
Options are as follows-
• -a: This will display all connection and ports
• -b: Shows the executable involved in each connection or hearing port
• -e: This protocol will combine with the -sand display the Ethernet statistics
• -n: This will display the address and the port number in the form of numerical
3|Page
• -o: It will display the ID of each connection for the ownership process.
• -r: It will display the routing table
• -v: When used in combination with -b, the link or hearing port sequence for every
executable is shown.
5. Nslookup
The Nslookup which stands for name server lookup command is a network utility command used
to obtain information about internet servers. It provides name server information for the DNS
(Domain Name System) i.e. the name and IP Address of the default DNS server.
4|Page
Lab work Output
5|Page
6|Page
7|Page
Conclusion
Hence, basic computer network commands can be run through the command prompt to monitor
the network status and troubleshoot the errors in the network.
8|Page