Information Gatheringpingicmpnetworkscanninghosts

fping

fping sends ICMP ECHO_REQUEST packets to network hosts to determine if they are responding. It differs from ping by allowing multiple targets on the command line or from a file and uses a round-robin fashion to ping them.

Description

fping is a ping-like program that uses the Internet Control Message Protocol (ICMP) echo request to check if target hosts are responding. Unlike standard ping, which sends packets to one target until it times out or replies, fping supports specifying any number of targets on the command line or reading them from a file. It sends a ping packet to each target and moves to the next in a round-robin fashion for efficient scanning of multiple hosts.

Use cases include network discovery, host availability testing, and monitoring multiple devices simultaneously. It is particularly useful in scripting and automation for checking ranges of IP addresses or lists of hosts quickly. The tool provides various output options to filter alive hosts, show addresses or names, and control verbosity.

fping6 provides backwards compatibility with fping versions below 4.0, supporting similar functionality for IPv6 targets.

How It Works

fping operates by sending ICMP ECHO_REQUEST packets to specified network hosts. It processes targets in a round-robin manner, sending one ping packet per target before cycling back, rather than waiting for responses from a single host. This enables concurrent probing of multiple hosts with configurable intervals, data sizes, backoff factors, and counts. Reverse DNS lookups can be forced, and outputs can include timestamps, elapsed times, or filtered results for alive targets.

Installation

bash
sudo apt install fping

Flags

-4, --ipv4only ping IPv4 addresses
-6, --ipv6only ping IPv6 addresses
-b, --size=BYTESamount of ping data to send, in bytes (default: 56)
-B, --backoff=Nset exponential backoff factor to N (default: 1.5)
-c, --count=Ncount mode: send N pings to each target
-f, --file=FILEread list of targets from a file ( - means stdin)
-g, --generategenerate target list (only if no -f specified) (give start and end IP in the target list, or a CIDR address)
-a, --aliveshow targets that are alive
-A, --addrshow targets by address
-C, --vcount=Nsame as -c, report results in verbose format
-d, --rdnsshow targets by name (force reverse-DNS lookup)
-D, --timestampprint timestamp before each output line
-e, --elapsedshow elapsed time on return packets
-i, --interval=MSECinterval between sending ping packets (default: 10 ms)
-n, --nameshow targets by name (reverse-DNS lookup for target IPs)

Examples

Display the help/usage information for fping
fping -h
Display the help/usage information for fping6
fping6 -h
Generate and ping a range of IPv4 addresses from 192.168.1.0 to 192.168.1.255
fping -g 192.168.1.0 192.168.1.255
Generate and ping targets using CIDR notation for a /24 network
fping -g 192.168.1.0/24
Using fping6 to generate and ping a range (example from page)
fping6 -g 192.168.1.0 192.168.1.255
Using fping6 to generate and ping a CIDR range (example from page)
fping6 -g 192.168.1.0/24
Read list of targets from a file and ping them
fping -f targets.txt
Updated 2026-04-16kali.org ↗