IPC:ArchiveCommand

ArchiveCommand is a PostgreSQL wait event that occurs when the WAL archiver process is waiting for an external archive_command script or program to complete. This happens during WAL archiving—typically on a primary server configured with archive_mode = on—when PostgreSQL executes the user-defined archive_command to copy completed WAL files to a safe archival location (e.g., for point-in-time recovery or backup). The wait reflects the time spent blocked while the operating system runs the command and waits for it to finish.

Detect Problems

This event appears briefly every time a WAL file is filled and archived successfully in a healthy system. However, if you observe prolonged or frequent waits on IPC:ArchiveCommand, it may indicate issues such as:

Troubleshooting Steps and Recommendations

To troubleshoot IPC:ArchiveCommand waits, consider the following steps: