0% found this document useful (0 votes)
106 views15 pages

CMD and Port Number

The document provides information about common port numbers and the services they are associated with. Some key port numbers listed include: - Port 20 and 21 are used for File Transfer Protocol (FTP) for data transfer and command control respectively. - Port 22 is used for Secure Shell (SSH) for secure login. - Port 25 is used for Simple Mail Transfer Protocol (SMTP) for email routing. - Port 80 is used for Hypertext Transfer Protocol (HTTP) and is commonly used on the World Wide Web. - Port 443 is used for HTTP Secure (HTTPS) which uses HTTP over TLS/SSL for secure connections.

Uploaded by

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

CMD and Port Number

The document provides information about common port numbers and the services they are associated with. Some key port numbers listed include: - Port 20 and 21 are used for File Transfer Protocol (FTP) for data transfer and command control respectively. - Port 22 is used for Secure Shell (SSH) for secure login. - Port 25 is used for Simple Mail Transfer Protocol (SMTP) for email routing. - Port 80 is used for Hypertext Transfer Protocol (HTTP) and is commonly used on the World Wide Web. - Port 443 is used for HTTP Secure (HTTPS) which uses HTTP over TLS/SSL for secure connections.

Uploaded by

yami adi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 15

Port number Assignment

20 File Transfer Protocol (FTP) Data Transfer


21 File Transfer Protocol (FTP) Command Control
22 Secure Shell (SSH) Secure Login
23 Telnet remote login service, unencrypted text messages
25 Simple Mail Transfer Protocol (SMTP) E-mail routing
53 Domain Name System (DNS) service
80 Hypertext Transfer Protocol (HTTP) used in the World Wide Web
110 Post Office Protocol (POP3)
119 Network News Transfer Protocol (NNTP)
123 Network Time Protocol (NTP)
143 Internet Message Access Protocol (IMAP) Management of digital mail
161 Simple Network Management Protocol (SNMP)
194 Internet Relay Chat (IRC)
443 HTTP Secure (HTTPS) HTTP over TLS/SSL

Well known ones are:

Port Service name Transport protocol


 20, 21  File Transfer Protocol (FTP)  TCP
 22  Secure Shell (SSH)  TCP and UDP
 23  Telnet  TCP
 25  Simple Mail Transfer Protocol (SMTP)  TCP
 50, 51  IPSec
 53  Domain Name System (DNS)  TCP and UDP
 67, 68  Dynamic Host Configuration Protocol (DHCP)  UDP
 69  Trivial File Transfer Protocol (TFTP)  UDP
 80  HyperText Transfer Protocol (HTTP)  TCP
 110  Post Office Protocol (POP3)  TCP
 119  Network News Transport Protocol (NNTP)  TCP
 123  Network Time Protocol (NTP)  UDP
 135-139  NetBIOS  TCP and UDP
 143  Internet Message Access Protocol (IMAP4)  TCP and UDP
 161, 162  Simple Network Management Protocol (SNMP)  TCP and UDP
 389  Lightweight Directory Access Protocol  TCP and UDP
 443  HTTP with Secure Sockets Layer (SSL)  TCP and UDP
 3389  Remote Desktop Protocol  TCP and UDP

1. Ping Command

The ping command is one of the most often used networking utilities for detecting devices on a
network and for troubleshooting network problems.

When you ping a device you send that device a short message, which it then sends back (the
echo).

The general format is ping hostname or ping IPaddress.

Example

ping www.google.com or ping 216.58.208.68

This article covers the ping command in more detail

2. ipconfig Command

Another indispensable and frequently used utility that is used for finding network information
about your local machine like IP addresses, DNS addresses etc

Basic Use: Finding Your IP Address and Default Gateway

Type the command ipconfig at the prompt.

The following is displayed

The following are 21 of the best CMD commands you should know if you want to have more
control over your Windows PC.
1. ASSOC: Fix File Associations

One of the most powerful tools in the CMD command library is the ASSOC command.

Your computer associates certain file extensions with certain programs. This is how your
computer knows to open Adobe when you double click a PDF file, or Microsoft Word when you
double click a DOC file.

You can view all the file associations your computer knows about by typing ASSOC in the
command window. You’ll see the file extension and the program it’s associated with.

You can set the association by typing something like assoc .doc=Word.Document.8.
2. FC: File Compare

Sometimes when files are changed over time, it’s hard to remember what the differences were
between versions. You may not know that a CMD command offers the ability to compare files
and see all differences, but it’s true.

The FC command performs either an ascii or a binary file comparison and will list all of the
differences that it finds.

Fc /a File1.txt File2.txt will compare two ascii files.

Fc /b Picture1.jpg Picture2.jpg will do a binary compare on two images.

3. IPCONFIG: IP Configuration
Network troubleshooting is never simple, but one command that makes it much easier is
IPCONFIG.

Using this command in the CMD command prompt returns detailed information about your
current network adapter connection including:

 Current IP Address
 Subnet Mask
 Default Gateway IP
 Current domain

This information can help you troubleshoot router issues and other connection issues you could
be having with your network adapter.

4. NETSTAT: Network Statistics

Concerned that you could have malware running on your computer that’s connecting to internet
locations without you knowing about it?

If you run a NETSTAT command in the command prompt, you can get a list of all active TCP
connections from your computer.
5. PING: Send Test Packets

An IT Analyst’s best friend is the PING command.  Running this command sends test packets
over the network to the target system.

You can use the PING command to test whether your computer can access another computer, a
server, or even a website. It can help with revealing network disconnections. It also provides
transit time for the packets in milliseconds, so it also reveals a bad network connection as well.

6. TRACERT: Trace Route


TRACERT is a fascinating Windows Command to use. If you’re ever curious to see the path
your internet traffic takes to get from your browser to a remote system like Google servers, you
can use TRACERT to see it.

The command stands for “Trace Route”, which sends packets out to a remote destination (server
or website), and provides you with all of the following information:

 Number of hops (intermediate servers) before getting to the destination


 Time it takes to get to each hop
 The IP and sometimes the name of each hop

TRACERT can reveal how the routes of your internet requests change depending where you’re
accessing the web. It also helps with troubleshooting a router or switch on a local network that
may be problematic.

7. POWERCFG: Power Configuration

Are you frustrated with how quickly your laptop seems to run out of power? It could be that your
power settings are configured as efficiently as possible. There’s a windows CMD command
called POWERCFG (power configuration) that can help. Run the command prompt as an
administrator and type powercfg – energy to get a full power efficiency report.
The process can take up to about a minute, but when it’s done, you’ll see whether there are any
warnings or errors that might help you improve the power efficiency of your system.

View the energy-report.html file to see the details of those errors and warnings.

8. SHUTDOWN: Turn Off Computer

The SHUTDOWN command is a pretty versatile command that lets you shutdown the computer
but control the behavior of that shutdown. It’s commonly used as a scheduled task or part of an
IT batch job after patches have been applied to a computer system.
Typing shutdown /i from the command prompt will initiate a shutdown, but it’ll upon a GUI to
give the user an option on whether to restart or do a full shutdown. If you don’t want to have any
GUI pop up, you can just issue a shutdown /s command.

There is a long list of other parameters you can use to do a log off, hibernate, restart, and more.
Just type shutdown without any arguments to see them all.

9. SYSTEMINFO: System Information

If you need to know what brand of network card you have, processor details, or the exact version
of your Windows OS, the SYSTEMINFO command can help.

This command polls your system and pulls the most important information about your system. It
lists the information in a clean format that’s easy to read.
10. SFC: System File Checker

If you’re ever concerned that a virus or some other software might have corrupted your core
system files, there’s a Windows command that can scan those files and ensure their integrity.

You need to launch CMD as administrator (right click and choose Run as Administrator).
Typing SFC /SCANNOW will check the integrity of all protected system files. If a problem is
found, the files will be repaired with backed-up system files.

The SFC command also lets you:

 /VERIFYONLY: Check the integrity but don’t repair the files.


 /SCANFILE: Scan the integrity of specific files and fix if corrupted.
 /VERIFYFILE: Verify the integrity of specific files but don’t repair them.
 /OFFBOOTDIR: Use this to do repairs on an offline boot directory.
 /OFFWINDIR: Use this to do repairs on an offline Windows directory.
 /OFFLOGFILE: Specify a path to save a log file with scan results.

The scan can take up to 10 or 15 minutes, so give it time.

11. NET USE: Map drives

If you want to map a new drive, you could always open File Explorer, right click on This PC,
and go through the Map Network Drive wizard. However, using the NET USE command, you
can do the same thing with one command string.

For example, if you have a share folder on a computer on your network called \\OTHER-
COMPUTER\SHARE\, you can map this as your own Z: drive by typing the command:

Net use Z: “\\OTHER-COMPUTER\SHARE” /persistent:yes

The persistent switch tells your computer that you want this drive remapped every time you log
back into your computer.
12. CHKDSK: Check Disk

While the SFC command only checks the integrity of core system files, you can use the
CHKDSK command to scan an entire drive.

The command to check the C: drive and repair any problems, launch the command window as an
administrator and type CHKDSK /f C:.

This command checks for things like:

 File fragmentation
 Disk errors
 Bad sectors

The command can fix any disk errors (if possible). When the command is finished, you’ll see a
status of the scan and what actions were taken.

13. SCHTASKS: Schedule Tasks

Windows comes with a wizard for creating scheduled tasks. For example, maybe you have a
BAT file stored on C:\temp that you want to run every day at noon.

You’d have to click through the Scheduled Task wizard to configure this. Or you can type a
single SCHTASKS command to set it up.

SCHTASKS /Create /SC HOURLY /MO 12 /TR Example /TN c:\temp\File1.bat

The scheduled switch accepts arguments like minute, hourly, daily, and monthly. Then you
specify the frequency with the /MO command.

If you typed the command correctly, you’ll see the response, SUCCESS: The scheduled task
“Example” has successfully been created.
14. ATTRIB: Change File Attributes

In Windows, you can change file attributes by right clicking on a file and finding the right
property to change. However, instead of hunting around for the file attribute, you can use the
ATTRIB command to set the file attributes.

For example, if you type: ATTRIB +R +H C:\temp\File1.bat, it’ll set File1.bat as a hidden,
read-only file.

There is no response when it’s successful, so unless you see an error message, the command
worked.

Other Windows CMD Commands

As you can see, there are some powerful and useful things you can do with the Windows
command prompt, if you know the right commands.

Believe it or not, there are even more commands that will give you the ability to do some things
you probably never realized just by typing a simple command.

 BITSADMIN: Initiate upload or download jobs over the network or internet and monitor the
current state of those file transfers.
 COLOR: Change the background color of the command prompt window.
 COMP: Compare the contents of any two files to see the differences.
 FIND/FINDSTR: Search for strings inside of any ASCII files.
 PROMPT: Change the command prompt from C:\> to something else.
 TITLE: Change the title of the command prompt window.
 REGEDIT: Edit keys in the Windows registry (use with caution).
 ROBOCOPY: A powerful file copy utility built right into Windows

Ip config has a number of switches the most common are:

ipconfig /all – displays more information about the network setup on your systems including the
MAC address.
ipconfig /release – release the current IP address

ipconfig /renew – renew IP address

ipconfig /? -shows help

ipconfig/flushdns – flush the dns cache

3. Hostname Command

A very simple command that displays the host name of your machine. This is much quicker than
going to the control panel>system route.

4. getmac Command

Another very simple command that shows the MAC address of your network interfaces

5. arp Command

This is used for showing the address resolution cache. This command must be used with a
command line switch arp -a is the most common.

Type arp at the command line to see all available options.

See using arp in the basic networking course

6. NSlookup
Used for checking DNS record entries. See Using NSlookup for more details

7. Nbtstat

Diagnostic tool for troubleshooting netBIOS problems. See This technet article.

8 Net Command

Used for managing users,service,shares etc see here

9. Netstat Command

Used for displaying information about tcp and udp connections and ports. See tcp and udp ports
and sockets and how to use the netstat command

10. TaskKill Command

View a list of running tasks using the tasklist command and kill them by name or processor ID
using the taskKill command- See this tutorial.

Notable IEEE Standards committees and formats


IEEE 260 Standard Letter Symbols for Units of Measurement, IEEE-260-1978 (now 260.1-2004)
IEEE 488 Standard Digital Interface for Programmable Instrumentation, IEEE-488-1978 (now
488.1)
IEEE 610 Standard Glossary of Software Engineering Terminology
IEEE 754 Floating point arithmetic specifications
IEEE 802 LAN/MAN
IEEE 802.1 Standards for LAN/MAN bridging and management and remote media access control
(MAC) bridging
IEEE 802.2 Standards for Logical Link Control (LLC) standards for connectivity
IEEE 802.3 Ethernet Standards for Carrier Sense Multiple Access with Collision Detection
(CSMA/CD)
IEEE 802.4 Standards for token passing bus access
IEEE 802.5 Standards for token ring access and for communications between LANs and MANs
IEEE 802.6 Standards for information exchange between systems
IEEE 802.7 Standards for broadband LAN cabling
IEEE 802.8 Fiber-optic connection
IEEE 802.9 Standards for integrated services, like voice and data
IEEE 802.10 Standards for LAN/MAN security implementations
IEEE 802.11 Wireless Networking – "WiFi"
IEEE 802.12 Standards for demand priority access method
IEEE 802.14 Standards for cable television broadband communications
IEEE Bluetooth and Wi-Fi coexistence mechanism
802.15.2
IEEE Wireless Sensor/Control Networks – "ZigBee"
802.15.4
IEEE Wireless Body Area Network[15] (BAN) – (e.g. Bluetooth low energy)
802.15.6
IEEE 802.16 Wireless Networking – "WiMAX"
IEEE 802.24 Standards for Logical Link Control (LLC) standards for connectivity
IEEE 828 Configuration Management in Systems and Software Engineering
IEEE 829 Software Test Documentation
IEEE 830 Software Requirements Specifications
IEEE 896 Futurebus
IEEE 1003 Unix compatibility programming standard – POSIX
IEEE 1016 Software Design Description
IEEE 1028 Standard for Software Reviews and Audits
IEEE 1044.1 Standard Classification for Software Anomalies
IEEE 1059 Software Verification And Validation Plan
IEEE 1073 Point of Care Medical Device Communication Standards
IEEE 1074 Software Development Life Cycle
IEEE 1076 VHDL – VHSIC Hardware Description Language
IEEE 1149.1 JTAG
IEEE 1149.6 AC-JTAG
IEEE 1180 Discrete cosine transform accuracy
IEEE 1233 System Requirements Specification
IEEE 1275 Open Firmware
IEEE 1284 Parallel port
IEEE P1363 Public key cryptography
IEEE 1364 Verilog
IEEE 1394 Serial bus – "FireWire", "i.Link"
IEEE 1471 software architecture / system architecture
IEEE 1541 Prefixes for Binary Multiples
IEEE 1584 Guide for Performing Arc Flash Hazard Calculations
IEEE 1588 Precision Time Protocol
IEEE P1619 Security in Storage Working Group (SISWG)
IEEE 1666 IEEE Standard for Standard SystemC Language Reference Manual
IEEE 1667 Standard Protocol for Authentication in Host Attachments of Transient Storage Devices
IEEE 1800 SystemVerilog
IEEE 1801 Unified Power Format
IEEE 1849 IEEE Standard for eXtensible Event Stream (XES) for Achieving Interoperability in Event
Logs and Event Streams
IEEE 1855 IEEE Standard for Fuzzy Markup Language
IEEE 1901 Broadband over Power Line Networks
IEEE 1906.1 Recommended Practice for Nanoscale and Molecular Communication Framework
IEEE 1914 Next Generation Fronthaul Interface Working Group
IEEE 1914.1 Standard for Packet-based Fronthaul Transport Networks
IEEE 1914.3 Standard for Radio Over Ethernet Encapsulations and Mappings
IEEE 2050 RTOS for embedded systems standard

You might also like