UIT UNIVERSITY Computer Networks Lab 01 PDF
Document Details
Uploaded by ExultantJasper7367
UIT University
2024
UIT UNIVERSITY
Tags
Summary
This document is a lab for a computer networks course at UIT UNIVERSITY, covering the use of diagnostic network commands like tracert, ping, arp, and netstat during the Fall 2024 semester.
Full Transcript
UIT UNIVERSITY Department of Computer Science Course Code: CNS 301 Course Title: COMPUTER NETWORKS FALL 2024 Lab 01 Objective: This practical p...
UIT UNIVERSITY Department of Computer Science Course Code: CNS 301 Course Title: COMPUTER NETWORKS FALL 2024 Lab 01 Objective: This practical performance exposes the students to some of the diagnostic commands that are utilized to diagnose/troubleshoot the problems. Student Information Student Name Student ID Date Assessment Marks Obtained Remarks Signature Lab 01: TCP/IP Utilities UIT UNIVERSITY Department of Computer Science CNS301 – Computer Networks Lab 01 Instructions Come to the lab in time. Students who are late more than 20 minutes, will not be allowed to attend the lab. Students have to perform the examples and exercises by themselves. Lab work must be submitted on the same day it is performed. 1. Objective This practical performance exposes the students to some of the diagnostic commands that are utilized to diagnose/troubleshoot the problems. 2. Labs Descriptions 1. Tracert : It is a utility that can be used to determine the route and hop count to a destination n. Example of tracert is shown below: Page 2 of 9 Lab 01: TCP/IP Utilities Figure 1: Tracert command being used to depict the hops required to reach the destination Figure 2: Tracert command used with IP address instead of domain name 2. PING: PING stands for “Packet Internet Groper” and it is a diagnostic tool that is used to check whether a host is reachable or not. Target can be either a name or IP address. Syntax: Ping www.uit.edu Ping ip address (you can mention ip address instead of domain name) Ping ip address or Domain name –n number of packets you want to sent Ping –a ip address.(will first resolve ip to its domain name) Figure 3: PING using domain name Page 3 of 9 Lab 01: TCP/IP Utilities Figure 4: PING using IP Address Figure 5: PING using IP Address and specifying number of packets. Figure 6: PING using a variant -a will yield domain name associated with IP and rest is same as above. 3. ARP ARP is “Address Resolution Protocol”. It is used to resolve IP address to MAC address. arp –a (will show a list of relevant IP addresses and their corresponding MAC addresses) Figure 7: arp with -a variant can show IP and Corresponding MAC address 4. NETSTAT This command gives you information about transport protocols (TCP and UDP) and their present state like close or listening etc. Netstat –a Shows the status of port along with the devices local address and the address with which communication is being done. Netstat -e will yield Ethernet statistics that is number of bytes sent and received Page 4 of 9 Lab 01: TCP/IP Utilities Netstat -r To see routing table information and interface detail use following command Figure 8: netstat with -a variant can show IP and Corresponding MAC address Figure 9: Depicting the different status of ports Page 5 of 9 Lab 01: TCP/IP Utilities Figure 10: Showing Ethernet statistics that is number of bytes sent and received Figure 11: To see routing table information and interface detail use following command 5. Nslookup Nslookup utility is used to test and troubleshoot domain name servers. Nslookup has two modes. Interactive mode enables you to query name servers for information about hosts and domains, or to print a list of hosts in a domain. Non- interactive mode prints only the name and requested details for one host or domain. Non-interative mode is useful for a single query. To enter the interactive mode of Nslookup, type nslookup without any arguments at a command prompt, or use only a hypen as the first argument and specify a domain name server in the second. The default DNS name server will be used if you don't enter anything for the second argument. Page 6 of 9 Lab 01: TCP/IP Utilities Figure 12: nslookup command being used. To use non-interactive mode, in the first argument, enter the name or IP address of the computer you want to look up. In the second argument, enter the name or IP address of a domain name server. The default DNS name server will be used if you don't enter anything for the second argument. Figure 13: nslookup being used with domain name 6. Ftp Transfers files to and from a computer running a File Transfer Protocol (FTP) server service such as Internet Information Services. Ftp can be used interactively or in batch mode by processing ASCII text files. Syntax ftp [-v] [-d] [-i] [-n] [-g] [-s:FileName] [-a] [- w:WindowSize] [-A] [Host] Parameters Page 7 of 9 Lab 01: TCP/IP Utilities -v : Suppresses the display of FTP server responses. -d : Enables debugging, displaying all commands passed between the FTP client and FTP server. -i : Disables interactive prompting during multiple file transfers. -n : Suppresses the ability to log on automatically when the initial connection is made. -g : Disables file name globbing. Glob permits the use of the asterisk (*) and question mark (?) as wildcard characters in local file and path names. -s: FileName : Specifies a text file that contains ftp commands. These commands run automatically after ftp starts. This parameter allows no spaces. Use this parameter instead of redirection (