I'm using a Debian 9 image on a virtual machine. The ping command is not installed. When I run:

sudo apt-get install ping

It asks me:

Package ping is a virtual package provided by:
  iputils-ping 3:20161105-1
  inetutils-ping 2:1.9.4-2+b1
You should explicitly select one to install.

Why is there two ping utilities? What are the differences between them? Is there some guidelines to choose one version over the other? What are the implications of this choice? Will all scripts and programs be compatible with both versions?

4 Answers 4


iputils’s ping supports quite a few more features than inetutilsping, e.g. IPv6 (which inetutils implements in a separate binary, ping6), broadcast pings, quality of service bits... The linked manpages provide details.

iputilsping supports all the options available on inetutilsping, so scripts written for the latter will work fine with the former. The reverse is not true: scripts using iputils-specific options won’t work with inetutils.

As far as why both exist, inetutils is the GNU networking utilities, targeting a variety of operating systems and providing lots of different networking tools; iputils is Linux-specific and includes fewer utilities. So typically you’d combine both to obtain complete coverage and support for Linux-specific features, on Linux, and only use inetutils on non-Linux systems.

  • Thank you for your answer. You say that typically you combine both to obtain complete coverage but as both implement the virtual package ping, If I install one the other is removed. How do you combine them? Commented Oct 25, 2017 at 14:09
  • @Ortomala I meant that you combine both sets of utilities: for example, ftp from inetutils, ping from iputils, etc. (That part of my answer wasn’t focused on ping specifically.) Commented Oct 25, 2017 at 14:18

inetutils-ping is the portable GNU implementation, which is used on non-Linux Debian systems (such as Debian GNU/kFreeBSD).

iputils-ping is Linux only, but does have more features. If you are using Linux, you probably want iputils version of ping.

  • 1
    I learned from @StephenKitt's answer that iputils-ping supports ipv6 with same binary (ipv6 is a symlink), while inetutils-ping provides a separate ping6 binary. Both support ipv6, but the symbolic links aren't visible from packages.debian.org file listings.
    – sebasth
    Commented Oct 25, 2017 at 13:02
  • i have tested the ping from both packages . ping6 seems to work only when installing the inetutils-ping thx again
    – GAD3R
    Commented Oct 25, 2017 at 13:08
  • @GAD3R What do you need the ping6 command for, if ping from iputils-ping supports both protocols? You can force it to use only either protocol with the -4 and -6 switches, should the need arise. Commented Oct 25, 2017 at 13:35
  • 1
    @GAD3R that’s weird, iputils-ping installs a ping6 symlink, so you should be able to ping6 :: without installing inetutils-ping at all (and I can, on the systems I’ve checked this on). Commented Oct 25, 2017 at 14:20

iputils-ping performs DNS reverse lookup via PTR query. You will have to wait for a timeout if there is no response from your DNS server.

inetutils-ping performs way more better in this situation.

  • Both implementations by default try to resolve IP addresses into names using reverse DNS lookups and require the -n option to disable this behavior. Would you explain, how exactly inetutils-ping performs better? Commented Mar 13, 2022 at 0:26
  • 1
    @SebastianSchrader For iputils-ping, -n sets opt_numeric, which determines whether pr_addr will call getnameinfo without NI_NUMERICHOST, where a PTR query may happen. For inetutils-ping, it always calls inet_ntoa to convert sockaddr to string, a PTR resolution never happens. The interpretation of the -n flag and implementation of name resolution is rather complex behind the scene. It depends on what option you are using, what kind of response you are receiving, and even more. In general, iputils-ping may stuck when your DNS resolver doesn't respond to a PTR query in time.
    – youfu
    Commented Mar 14, 2022 at 16:04
  • Thanks for the details. getnameinfo with NI_NUMERICHOST (on glibc at least) is basically just a wrapper for inet_ntop (for IPv6 link-local addresses, it also tries to resolve the scope_id to an interface name using if_indextoname). With -n iputils-ping should therefore perform well too. Commented Mar 14, 2022 at 19:46
  • 1
    I'm iputils maintainer, I wonder if we should really stop doing DNS reverse lookup via PTR query by default (it can be avoided with -n, as mentioned). That would be a backward incompatibility change.
    – pevik
    Commented Mar 14 at 10:19
  • @pevik, I would welcome such a change. Per my past experience, I only need PTR lookup for mailing/mtr/mDNS. When I ping a target, I really don't care about what it says in its PTR record.
    – youfu
    Commented Mar 14 at 13:56

You can install one of them , the tow package provide the ping binary , the inetutils-ping will provide an additional tool ping6


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .