PG_TEST_FSYNC(1)
β¨ PG_TEST_FSYNC(1) β the pg_test_fsync(1) glow-up from the PostgreSQL 14.24 docs β¨
Okay bestie, welcome to the PG_TEST_FSYNC(1) page from the PostgreSQL 14.24 documentation β aka the manual for pg_test_fsync(1). Itβs giving βletβs benchmark some WAL sync methods togetherβ energy, and honestly? Iconic.
πΈ NAME πΈ
pg_test_fsync β determine fastest wal_sync_method for PostgreSQL. Thatβs the whole assignment, no cap.
π« SYNOPSIS π«
pg_test_fsync [option...]
π¦ DESCRIPTION π¦
Okay so pg_test_fsync is intended to give you a reasonable idea of what the fastest wal_sync_method is on your specific system, as well as supplying diagnostic information in the event of an identified I/O problem. So like, itβs both a speed check and a little detective. π΅οΈββοΈ
π¨ Real-talk caveat, bestie: the differences shown by pg_test_fsync might not make any significant difference in real database throughput, especially since many database servers are not speed-limited by their write-ahead logs. So donβt treat this like a magic wand, fr fr.
pg_test_fsync reports average file sync operation time in microseconds for each wal_sync_method, which can also be used to inform efforts to optimize the value of commit_delay. Numbers with β¨purposeβ¨? We love to see it.
π OPTIONS π
pg_test_fsync accepts the following command-line options:
-f,--filenameβ Specifies the file name to write test data in. This file should be in the same file system that thepg_waldirectory is or will be placed in. (pg_walcontains the WAL files.) The default ispg_test_fsync.outin the current directory. Put it where the WAL energy lives, iykyk.-s,--secs-per-testβ Specifies the number of seconds for each test. The more time per test, the greater the testβs accuracy, but the longer it takes to run. The default is5seconds, which allows the program to complete in under2minutes. More time = more accuracy, but also more waiting; choose your fighter. β³-V,--versionβ Print thepg_test_fsyncversion and exit. Short and sweet.-?,--helpβ Show help aboutpg_test_fsynccommand line arguments, and exit. Your little map, bestie. πΊοΈ
π ENVIRONMENT π
The environment variable PG_COLOR specifies whether to use color in diagnostic messages. Possible values are always, auto and never. Color-coded diagnostics? We love to see it. π¨
π₯ SEE ALSO π₯
postgres(1) β go say hi.
Thatβs the whole page, bestie. Cute sign-off: this one is from the PostgreSQL 14.24 documentation, dated 2026, and its manual tag is PG_TEST_FSYNC(1) π
π¦ where this page comes from
- opensuse-leap 16.0: postgresql14-contrib 14.24-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql14-contrib 14.24-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql14-contrib 14.24-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql14-contrib 14.24-160000.1.1 Β· PostgreSQL
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms