Back to Basics: PING

As more and more IT Pros start their career as specialists, fewer and fewer come from a “in the trenches” IT background. I’ve found many that don’t know how to use or, in some cases, have never even heard of many of the basic diagnostic tools built into modern operating systems (e.g. ping & tracert). Case in point, this is a conversation I recently had with an Senior ASPX Web Developer:

Dev“Hi Mike. I cannot get my development server. Can you check it for me?”

Me“Lemme check…looks like it’s up and running. It’s responding to pings. What happens when you ping it?”

Dev“It’s not working when I try to ping it.”

Me“Okay. What error are you getting?”

Dev“It just says the page cannot be found.”

Me“Got that part. What do you get when you ping the server?”

Dev“Um…Isn’t that what I’m doing?”

I’ll spare you the rest of the conversation, but you can probably guess where it went from there. In short, the highly-skilled web developer had such a laser beam skill set that she had never used (or even heard of) of this mysterious diagnostic tool named “ping”. It may seem impossible for someone to get to that level in their career having zero knowledge of such a fundamental tool but, I am sad to say, it happens more often than many want to admit.

But never let it be said that I am unwilling to do my part to fix the problem! Here is a quick primer on what is arguably the single most common (and basic) tool for network diagnostics: PING. If you already know about it, go you! If not, just read the rest of this post. I promise I won’t tell anyone 🙂

A Brief History of PING

Way back in 1983, a man named Mike Muuss came up with a nifty utility for leveraging the existing Internet Control Message Protocol (ICMP) as a means of diagnosing IP networks. Since the general mechanism of sending a signal, waiting for it to bounce back, and measuring the result was similar to how sonar technology works, he named his brainchild “PING”.

When to Use PING

There are any number of reasons why one would use the ping tool. Here are a couple of common ones:

  • Monitoring Connectivity:It seems like my workstation is having intermittent network disconnects. How many packets are being dropped?
  • Scoping a ProblemOhnoes! The website is giving a 404 error! Is the server down or just my web service?

How to Use PING

PING with a Target

It’s a snap. Just open a command line (Windows) or terminal (Linux) and type “ping” and the IP address or DNS name for the target. In its most basic form, that is the only required parameter! The resulting process will send the default number of pings (Windows is generally five but Linux can vary). When it’s done, a report is delivered with a  calculation of the total “packet loss” (i.e. pings that failed to return).
ping [URL or IP address]

PING without a Target

Sometimes you want to run a more robust ping test. In that case you need to define parameters. There are many available. We won’t cover them all in this post, but you can see the full list by typing ping without a target:


PING with Advanced Parameters (and a Target)

Send more (or less) than the default number of pings:

ping -n [number of pings to send] [URL or IP]

Save the results to a file (to show your network guy):

ping [URL or IP] > [path]\ping-test.txt

NOTE: When sending output to a file, nothing is generally shown on the screen. But everything will be saved to the file and, since the file is named with the date, it will help you remember when you ran the test! If you want to stop the process before the define number of pings has finished, just use Ctrl + C to cancel (the pings already complete will still be in the file). Also, when using Linux the file path will be formatted differently.

Run a quick DNS query to get the URL (if any):

ping -a [URL or IP]

NOTE: This parameter is only available in Windows. To perform a similar action in Linux use NSLOOKUP (which we will discuss in a future post).

You can also combine parameters!

The below command will perform 100 pings against, force the results to IPv4, and save the output to a text file in Windows:

ping -n 100 -4 > C:\MyFile\ping-test.txt

So there you have it! You are now a certified ping engineer and are ready to wow all your sysadmin friends with your mad skillz. If they laugh at you, just tell yourself it’s because they are jealous.

Until next time!

~ Mike



Contact Us

On Key

More Posts

Mastering Azure AD Connect - A Comprehensive Guide by WME
Active Directory

Mastering Azure AD Connect – A Comprehensive Guide

Modern businesses are fast moving toward cloud-based infrastructure. In fact, cloud-based business is not just a trend anymore but a strategic necessity. Microsoft’s Azure Active Directory (Azure AD) has become a frontrunner in this domain. It

Read More »
Security Best Practices in SharePoint
Office 365

Security Best Practices in SharePoint

Microsoft SharePoint is an online collaboration platform that integrates with Microsoft Office. You can use it to store, organize, share, and access information online. SharePoint enables collaboration and content management and ultimately allows your teams to

Read More »
The Ultimate Guide to Microsoft Intune - Article by WME
Active Directory

The Ultimate Guide to Microsoft Intune

The corporate world is evolving fast. And with that, mobile devices are spreading everywhere. As we venture into the year 2024, they have already claimed a substantial 55% share of the total corporate device ecosystem. You

Read More »
Protecting Microsoft 365 from on-Premises Attacks
Cloud Security

How to Protect Microsoft 365 from On-Premises Attacks?

Microsoft 365 is diverse enough to enrich the capabilities of many types of private businesses. It complements users, applications, networks, devices, and whatnot. However, Microsoft 365 cybersecurity is often compromised and there are countless ways that

Read More »
Be assured of everything

Get WME Services

Stay ahead of the competition with our Professional IT offerings.