Fping is a program similar to ping, but has additional functions that allows it to quickly ping multiple hosts. Similar to ping, fping uses ICMP echo requests to determine the status of a host. Fping can be a handy tool to use that can allow you quickly perform checks on multiple host to determine if they are reachable or alive. In the example below, you that that I have a list of host in a text file called target.txt on my Desktop. Rather than using the ping tool to ping each individual host, I will create a text file with the hosts that I would like to ping.
In order use the list in the text file, I will open a terminal prompt and type the following command :
fping -f Desktop/targets.txt
fping = This activates the application
-f = This is the option to use a file.
Desktop/target.txt = This is the location of my file.
As you can see from the results below, all of the host except one are up or "alive". However, it would be nice to get some additional information that we typically see in a standard ping command. I will run the previous command and add the additional flags/options of -A, -n, -e. (note that these options are case sensitive)
As you can see from the screenshot below I now have the IP address, hostname and the elapsed time.
fping is a great tool to use if you have a list of hostnames and want to check the status of all of the hosts or if you want to quickly resolve to IP addresses to hostnames and vice versa.
Leave a Comment