@@ -2401,7 +2401,9 @@ END;
2401
2401
format is used for the log files:
2402
2402
2403
2403
<synopsis>
2404
- <replaceable>interval_start</replaceable> <replaceable>num_transactions</replaceable> <replaceable>sum_latency</replaceable> <replaceable>sum_latency_2</replaceable> <replaceable>min_latency</replaceable> <replaceable>max_latency</replaceable> { <replaceable>failures</replaceable> | <replaceable>serialization_failures</replaceable> <replaceable>deadlock_failures</replaceable> } <optional> <replaceable>sum_lag</replaceable> <replaceable>sum_lag_2</replaceable> <replaceable>min_lag</replaceable> <replaceable>max_lag</replaceable> <optional> <replaceable>skipped</replaceable> </optional> </optional> <optional> <replaceable>retried</replaceable> <replaceable>retries</replaceable> </optional>
2404
+ <replaceable>interval_start</replaceable> <replaceable>num_transactions</replaceable> <replaceable>sum_latency</replaceable> <replaceable>sum_latency_2</replaceable> <replaceable>min_latency</replaceable> <replaceable>max_latency</replaceable>
2405
+ <replaceable>sum_lag</replaceable> <replaceable>sum_lag_2</replaceable> <replaceable>min_lag</replaceable> <replaceable>max_lag</replaceable> <replaceable>skipped</replaceable>
2406
+ <replaceable>retried</replaceable> <replaceable>retries</replaceable> <replaceable>failures</replaceable> <replaceable>serialization_failures</replaceable> <replaceable>deadlock_failures</replaceable>
2405
2407
</synopsis>
2406
2408
2407
2409
where
@@ -2417,41 +2419,55 @@ END;
2417
2419
and
2418
2420
<replaceable>max_latency</replaceable> is the maximum latency within the interval,
2419
2421
<replaceable>failures</replaceable> is the number of transactions that ended
2420
- with a failed SQL command within the interval. If you use option
2421
- <option>--failures-detailed</option>, instead of the sum of all failed
2422
- transactions you will get more detailed statistics for the failed
2423
- transactions grouped by the following types:
2424
- <replaceable>serialization_failures</replaceable> is the number of
2425
- transactions that got a serialization error and were not retried after this,
2426
- <replaceable>deadlock_failures</replaceable> is the number of transactions
2427
- that got a deadlock error and were not retried after this.
2422
+ with a failed SQL command within the interval.
2423
+ </para>
2424
+ <para>
2428
2425
The next fields,
2429
2426
<replaceable>sum_lag</replaceable>, <replaceable>sum_lag_2</replaceable>, <replaceable>min_lag</replaceable>,
2430
- and <replaceable>max_lag</replaceable>, are only present if the <option>--rate</option>
2431
- option is used.
2427
+ and <replaceable>max_lag</replaceable>, only meaningful if the <option>--rate</option>
2428
+ option is used. Otherwise, they are all 0.0.
2432
2429
They provide statistics about the time each transaction had to wait for the
2433
2430
previous one to finish, i.e., the difference between each transaction's
2434
2431
scheduled start time and the time it actually started.
2435
2432
The next field, <replaceable>skipped</replaceable>,
2436
- is only present if the <option>--latency-limit</option> option is used, too.
2433
+ is only meaningful if the <option>--latency-limit</option> option is used, too. Otherwise it is 0 .
2437
2434
It counts the number of transactions skipped because they would have
2438
2435
started too late.
2439
- The <replaceable>retried</replaceable> and <replaceable>retries</replaceable>
2440
- fields are present only if the <option>--max-tries</option> option is not
2441
- equal to 1. They report the number of retried transactions and the sum of all
2442
- retries after serialization or deadlock errors within the interval.
2443
- Each transaction is counted in the interval when it was committed.
2436
+ </para>
2437
+ <para>
2438
+ The <replaceable>retried</replaceable>
2439
+ and <replaceable>retries</replaceable> fields are only meaningful if
2440
+ the <option>--max-tries</option> option is not equal to 1. Otherwise they
2441
+ are 0. They report the number of retried transactions and the sum of all
2442
+ retries after serialization or deadlock errors within the interval. Each
2443
+ transaction is counted in the interval when it was committed.
2444
+ </para>
2445
+ <para>
2446
+ <replaceable>failures</replaceable> is the sum of all failed transactions.
2447
+ If <option>--failures-detailed</option> is specified, instead of the sum of
2448
+ all failed transactions you will get more detailed statistics for the
2449
+ failed transactions grouped by the following types:
2450
+ <replaceable>serialization_failures</replaceable> is the number of
2451
+ transactions that got a serialization error and were not retried after this,
2452
+ <replaceable>deadlock_failures</replaceable> is the number of transactions
2453
+ that got a deadlock error and were not retried after this.
2454
+ If <option>--failures-detailed</option> is not
2455
+ specified, <replaceable>serialization_failures</replaceable>
2456
+ and <replaceable>deadlock_failures</replaceable> are always 0.
2444
2457
</para>
2445
2458
2446
2459
<para>
2447
- Here is some example output:
2460
+ Here is some example output with following options :
2448
2461
<screen>
2449
- 1345828501 5601 1542744 483552416 61 2573 0
2450
- 1345828503 7884 1979812 565806736 60 1479 0
2451
- 1345828505 7208 1979422 567277552 59 1391 0
2452
- 1345828507 7685 1980268 569784714 60 1398 0
2453
- 1345828509 7073 1979779 573489941 236 1411 0
2454
- </screen></para>
2462
+ pgbench --aggregate-interval=10 --time=20 --client=10 --log --rate=1000
2463
+ --latency-limit=10 --failures-detailed --max-tries=10 test
2464
+ </screen>
2465
+
2466
+ <screen>
2467
+ 1649114136 5815 27552565 177846919143 1078 21716 2756787 7264696105 0 9661 0 7854 31472 4022 4022 0
2468
+ 1649114146 5958 28460110 182785513108 1083 20391 2539395 6411761497 0 7268 0 8127 32595 4101 4101 0
2469
+ </screen>
2470
+ </para>
2455
2471
2456
2472
<para>
2457
2473
Notice that while the plain (unaggregated) log file shows which script
0 commit comments