Skip to content

Commit 4c34dcf

Browse files
committed
Activate low-volume optional logging during regression test runs.
Elaborated from an idea by Andres Freund.
1 parent 525b84c commit 4c34dcf

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

src/test/regress/pg_regress.c

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2456,12 +2456,12 @@ regression_main(int argc, char *argv[], init_function ifunc, test_function tfunc
24562456
}
24572457

24582458
/*
2459-
* Adjust the default postgresql.conf as needed for regression
2460-
* testing. The user can specify a file to be appended; in any case we
2461-
* set max_prepared_transactions to enable testing of prepared xacts.
2462-
* (Note: to reduce the probability of unexpected shmmax failures,
2463-
* don't set max_prepared_transactions any higher than actually needed
2464-
* by the prepared_xacts regression test.)
2459+
* Adjust the default postgresql.conf for regression testing. The user
2460+
* can specify a file to be appended; in any case we expand logging
2461+
* and set max_prepared_transactions to enable testing of prepared
2462+
* xacts. (Note: to reduce the probability of unexpected shmmax
2463+
* failures, don't set max_prepared_transactions any higher than
2464+
* actually needed by the prepared_xacts regression test.)
24652465
*/
24662466
snprintf(buf, sizeof(buf), "%s/data/postgresql.conf", temp_install);
24672467
pg_conf = fopen(buf, "a");
@@ -2471,6 +2471,10 @@ regression_main(int argc, char *argv[], init_function ifunc, test_function tfunc
24712471
exit(2);
24722472
}
24732473
fputs("\n# Configuration added by pg_regress\n\n", pg_conf);
2474+
fputs("log_autovacuum_min_duration = 0\n", pg_conf);
2475+
fputs("log_checkpoints = on\n", pg_conf);
2476+
fputs("log_lock_waits = on\n", pg_conf);
2477+
fputs("log_temp_files = 128kB\n", pg_conf);
24742478
fputs("max_prepared_transactions = 2\n", pg_conf);
24752479

24762480
if (temp_config != NULL)

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy