Bonnie++ - Disk I/O Performance Benchmarking Tool

Benchmark disk and file system I/O performance with Bonnie++. Measure read/write speeds, metadata operations, and more. Free online tool for developers.

Bonnie++

Bonnie++ is a powerful disk and file system benchmarking tool designed to measure I/O performance. It helps developers and system administrators understand the read and write capabilities of their storage devices and file systems.

Disk I/O Performance Testing

This section demonstrates how to use Bonnie++ to benchmark disk I/O. The example command below configures a test to measure various aspects of disk performance.

Example Bonnie++ Command

The following command benchmarks the disk mounted at /tmp/, utilizing user-space operations and disabling write buffering for a more direct performance measurement. It specifies a test file size of 16000MB and skips per-character I/O tests.

# Bonnie++
# disk and file system benchmarking tool for measuring I/O performance

# benchmark disk mounted at /tmp/; use `user` for that
# skip per char IO test (-f)
# no write buffering (-b)
bonnie++ -d /tmp -s 16000M -n 0 -m TEST -f -b -u user

Understanding Bonnie++ Options

Key options used in the example include:

  • -d /tmp: Specifies the directory where the test files will be created.
  • -s 16000M: Sets the size of the test file to 16000 Megabytes.
  • -n 0: Disables the creation of multiple test files.
  • -m TEST: Assigns a machine name to the test results.
  • -f: Skips the per-character I/O test, focusing on block I/O.
  • -b: Disables write buffering, performing direct I/O.
  • -u user: Specifies the user under which the tests will be run.

File System Benchmarking

Bonnie++ is invaluable for assessing the performance of different file systems, such as ext4, XFS, or ZFS, under various workloads. By running benchmarks, you can compare their efficiency in handling sequential and random read/write operations, as well as metadata-intensive tasks like file creation and deletion.

Further Resources

For more in-depth information on disk performance and file systems, consider exploring resources like: