Introduction
Input/Output Operations Per Second (IOPS) is a key metric for server storage performance, measuring the number of read and write operations per second. For a Terraform Enterprise instance, low IOPS can cause significant performance degradation, including slow or stalled runs. Monitoring IOPS helps identify storage bottlenecks that may impact your instance's efficiency and responsiveness, especially in high-transaction environments.
This guide provides two methods for monitoring IOPS on the Linux server hosting your Terraform Enterprise instance.
Procedure
You should run these commands on the Linux server during an active Terraform Enterprise run to accurately measure performance under load.
Method 1: Monitor System-Wide IOPS with iostat
The iostat command is a standard tool for monitoring system input/output statistics on Linux systems.
Execute the following command to monitor IOPS in real-time.
$ iostat -zx 2
- The
-zflag displays statistics in megabytes. - The
-xflag displays extended I/O statistics, including IOPS. - The
2parameter specifies a two-second interval between updates.
This command allows you to monitor the IOPS of each individual disk on the system to identify bottlenecks.
- The
Method 2: Monitor Container IOPS with Docker
The docker stats command provides real-time performance statistics for running Docker containers, including I/O usage.
Execute the
docker statscommand to view container metrics.$ docker stats
This command displays a live stream of container usage statistics, including CPU, memory, network, and I/O. This helps you correlate high I/O on the host with specific Terraform Enterprise containers.
By running these commands while Terraform Enterprise is under load, you can effectively diagnose performance issues related to storage bottlenecks.
Additional Information
- For more details on Terraform Enterprise operational requirements, please refer to the official documentation on infrastructure recommendations.