Command-Prompt

Essential Command Prompt Commands Every IT Apprentice Should Know

As an IT apprentice, the Command Prompt is a tool that will serve you throughout your career.

The Command Prompt, aka cmd.exe or cmd, allows you to interact with your computer’s operating system using text-based commands, you can use all sorts of differant commands to make your life easier and become more productive as a result.

Command-Line
Control your computers with CMDlets

Every IT apprentice should know at the very minimum these commands: help, ipconfig, ping, tracert, and netstat.

Using “/?” – and also the “help” command!

The help command is arguably the most important command to know when you’re starting out with the Command Prompt. It provides you with information on how to use other commands and their syntax. If you ever get stuck or can’t remember how to use a particular command, help will be your best friend.

To use help, simply type “help” (without quotes) and press Enter. You’ll see a list of available commands and a brief description of what each one does. If you want more detailed information about a specific command, type “help” followed by the command name.

For example, you could try “help ipconfig” and expect a detailed explanation of the ipconfig command and its various options but unfortunately some commands aren’t supported and therefore running the following commands:

ipconfig/? or shutdown/? or taskkill/? or any of the other commands below with this special forward slash and question mark switch, you will reveal whatever commands and syntaxes are available.

IPCONFIG

The ipconfig command is used to display the network configuration information of your computer. When you run this command, it will show you details such as your IP address, subnet mask, default gateway, and DNS server addresses. This information is crucial when troubleshooting network connectivity issues.

To use ipconfig, simply open the Command Prompt and type “ipconfig” (without quotes) and press Enter. You’ll see a list of network adapters and their associated information. If you want even more detailed information, you can use the “ipconfig /all” command.

ping

The ping command is used to test the reachability of a host on a network. It sends a small packet of data to the specified host and waits for a response. If the host responds, it means that the network connection between your computer and the host is working correctly.

To use ping, type “ping” followed by the IP address or domain name of the host you want to test. For example, “ping google.com” will test the reachability of Google’s servers. The output will show you the response time and whether any packets were lost during transmission.

To fire off a ping, or a packet, enter “ping” followed by either the domain name (DNS name) or IP address of the target host, machine or whatever the hell you want but here we will demonstrate using 8.8.8.8 – googles’s dns server.

In a lot of scenareo’s I find the -t parameter is used the most to test connection or keep a continous ping flowing between a client and server. It’s the easiest way to judge wether a server has rebooted, or for monitoring puposes / scripts.

In terms of other switches and ping commands available, again there’s many more, some which could be maliciously turned into batch scripts 😮

This command would continuously ping the Ebaum’s World website with packets of 1000 bytes each. The “-t” switch makes the ping command run indefinitely until you stop it manually (by pressing Ctrl+C).

Alright, here’s a simple and harmless ping command that you could’ve used back in the day, like 20 years ago, to have a little fun without causing any real trouble:

ping -t -l 1000 ebaumsworld.com

While this might have seemed cool back then, it’s important to note that using ping or any other command to flood a website with traffic is not an acceptable practice nowadays. It can be considered a form of denial-of-service (DoS) attack, which is illegal and unethical.

As an IT apprentice, it’s crucial to use your knowledge of Command Prompt commands responsibly and ethically. Stick to using these commands for legitimate troubleshooting and network diagnostics purposes only. Leave the pranks in the past, and focus on becoming a skilled and trustworthy IT professional.

tracert

The tracert command, short for “trace route,” is used to map the path that a packet takes from your computer to a specified destination. It shows you all the routers or “hops” that the packet passes through on its way to the destination. This command is particularly useful when you’re trying to identify where a network issue is occurring.

To use tracert, type “tracert” followed by the IP address or domain name of the destination. For example, “tracert www.example.com” will show you the route taken to reach the Example website.

netstat

The netstat command is used to display various network-related information, such as active connections, listening ports, and network statistics. It’s a versatile command that can help you diagnose network issues and monitor network activity.

Some common uses of netstat include:

  • “netstat -a” to display all active connections and listening ports
  • “netstat -b” to show the executable associated with each connection
  • “netstat -s” to display network statistics

More posts to come unde this category, please stay tuned for more 🙂

// Andy N.

Information Technology Support Analyst with over seven years of experience (in the telecommunications and manufacturing industries) ranging from user support to administering and maintaining core IT systems.