ioping: command not found

The ioping command generates a report of device I/O latency in real-time. It will continuously “ping” the specified device with requests and print information about each request at the command-line. By default, this information tracks how long it took an I/O request to finish. Aside from specifying a device to test, you can also specify a path name to test whatever device is associated with that path.

Consider using ioping to troubleshoot latency issues with a storage devices, especially if you believe your read and/or write speeds are slower than they should be.

Note: This is similar to the standard ping command, which tests network latency.

Syntax

The syntax of the ioping command is:

# ioping [options] {file/ directory/device name}

If you encounter below error while running the ioping command:

ioping: command not found

you may try installing the below package as per your choice of distribution:

Distribution Command
OS X brew install ioping
Debian apt-get install ioping
Ubuntu apt-get install ioping
Alpine apk add ioping
Arch Linux pacman -S ioping
Kali Linux apt-get install ioping
Fedora dnf install ioping
Raspbian apt-get install ioping

ioping Command Options

The following table lists some options you can use with the ioping command.

Option Description
-c {count} Specify the number of I/O requests to perform before stopping.
-i {time} Set the time (interval) between I/O requests.
-t {time} Set the minimum valid request time. Requests faster than this are ignored.
-T {time} Set the maximum valid request time. Requests slower than this are ignored.
-s {size} Set the size of requests.

ioping Command Examples

1. Show disk I/O latency using the default values and the current directory:

# ioping .

2. Measure latency on /tmp using 10 requests of 1 megabyte each:

# ioping -c 10 -s 1M /tmp

3. Measure disk seek rate on `/dev/sdX`:

# ioping -R /dev/sdX

4. Measure disk sequential speed on `/dev/sdX`:

# ioping -RL /dev/sdX

5. To get the average seek time of a device, we need to run the following ioping command:

# ioping -R /dev/sda

Conclusion

The ioping command can be used to perform simple latency tests on a disk. Latency is a measure of the delay in data transfer. The primary speed calculation of a storage devices is the IOPS, which stands for input/output operations per second. You need to take this value into consideration when choosing which underlying storage type you want to use for a storage resource. As you might expect, the IOPS for HDD devices is less than for SDD devices.

Related Post