• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
Source Digit

Source Digit

Linux, Ubuntu Tutorials & News, Technology, Gadgets & Gizmos

  • Home
  • How To
  • Ubuntu
  • Instagram
  • Blogging
  • Android
  • WordPress
  • +More
    • Cloud Computing
    • Gadgets
    • Social Media
    • Technology
  • Write for Us
Home / How To / How To Use Ping Command In Linux Ubuntu

How To Use Ping Command In Linux Ubuntu

By Sourabh / August 16, 2020 Category: How To, Ubuntu

Learn how to use ping command in Linux Ubuntu. See ping command examples in Linux.

Ping

Ping is a computer network administration software utility used to test the reachability of a host on an Internet Protocol network. It sends ICMP ECHO_REQUEST to network hosts

Ping Syntax

ping [-aAbBdDfhLnOqrRUvV6] [-c count] [-F flowlabel] [-i interval] [-I interface] [-l preload] [-m mark] [-M pmtudisc_option] [-N nodeinfo_option] [-w deadline] [-W timeout] [-p pattern] [-Q tos] [-s packetsize] [-S sndbuf] [-t ttl] [-T timestamp option] [hop ...] destination

When we execute ping command, the command {ping} uses the ICMP protocol’s mandatory ECHO_REQUEST datagram to elicit an ICMP ECHO_RESPONSE from a host or gateway. ECHO_REQUEST datagrams (”pings”) have an IP and ICMP header, followed by a struct timeval and then an arbitrary number of ”pad” bytes used to fill out the packet.

Ping Command Examples for Linux

Basic ping command

To use ping command:
ping www.google.com
Press ctrl+c to stop.

Limit Number of Packets

The ping command -c option is used to limit the number of packets. One can specify any number of packets to send to the destination server. It will automatically stop after completing sending the given number of packets. For example, run below command to send only 4 packets to the destination server www.google.com and stop it:
ping -c 4 www.google.com

Ping With Sound

You can use ping command with sound. Ping command can play a beep when a packet is received, by using -a option. This option plays a beep each a packet is successfully received. To run ping with beep sound, execute the command:
ping -a www.google.com

You will have to use Ctrl+c to stop ping command from sending packets.

Primary Sidebar

Latest Posts

How To Run Fsck Manually In Linux To Fix Unexpected Inconsistency

How To Fix Broken Packages On Ubuntu From Terminal

Re Execute The Previous Command In Linux Ubuntu Command Line

How Much RAM Is Needed For Ubuntu PC

How To Find Large Files And Directories In Linux Command Line

How To Use Clear Command History In Linux Terminal

Linux Command To Check RAM Size In Ubuntu Terminal In GB

How To Install Proprietary Drivers In Linux Ubuntu Using Terminal

How To Shutdown Linux With A 15 Minute Delay And Message

Free AI Courses With Certificate For Beginners In India

© 2026 Source Digit • Linux, Ubuntu Tutorials & News, Technology, Gadgets & Gizmos

  • Home
  • About
  • Privacy Policy
  • Terms & Conditions
  • Contact Us
  • Sitemap