Skip to content

Commit d43ff3c

Browse files
committed
Add description of --jobs to the docs. Also, add missing newline in --help output.
1 parent 4f25c26 commit d43ff3c

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

bin/pg_repack.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1430,7 +1430,7 @@ pgut_help(bool details)
14301430

14311431
printf("Options:\n");
14321432
printf(" -a, --all repack all databases\n");
1433-
printf(" -j --jobs Use this many parallel jobs");
1433+
printf(" -j --jobs Use this many parallel jobs for each table\n");
14341434
printf(" -n, --no-order do vacuum full instead of cluster\n");
14351435
printf(" -o, --order-by=COLUMNS order by columns instead of cluster keys\n");
14361436
printf(" -t, --table=TABLE repack specific table only\n");

doc/pg_repack.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,7 @@ The following options can be specified in ``OPTIONS``.
117117

118118
Options:
119119
-a, --all repack all databases
120+
-j, --jobs Use this many parallel jobs for each table
120121
-n, --no-order do vacuum full instead of cluster
121122
-o, --order-by=COLUMNS order by columns instead of cluster keys
122123
-t, --table=TABLE repack specific table only
@@ -145,6 +146,12 @@ Options to order rows. If not specified, pg_repack performs an online CLUSTER
145146
using cluster indexes. Only one option can be specified. You may also specify
146147
target tables or databases.
147148

149+
``-j``, ``--jobs``
150+
Create the specified number of extra connections to PostgreSQL, and
151+
use these extra connections to parallelize the rebuild of indexes
152+
on each table. If your PostgreSQL server has extra cores and disk
153+
I/O available, this can be a useful way to speed up pg_repack.
154+
148155
``-n``, ``--no-order``
149156
Perform an online VACUUM FULL.
150157

0 commit comments

Comments
 (0)