commands.sh

reindexdb

all

Rebuild indexes in a PostgreSQL database.

More info →

Options (9)

-h, --hostboolean

Reindex a specific database using connection options

Example: reindexdb {{database_name}} {{[-h|--host]}} {{hostname}} {{[-p|--port]}} {{port}} {{[-U|--username]}} {{username}}
-p, --portboolean

Reindex a specific database using connection options

Example: reindexdb {{database_name}} {{[-h|--host]}} {{hostname}} {{[-p|--port]}} {{port}} {{[-U|--username]}} {{username}}
-U, --usernameboolean

Reindex a specific database using connection options

Example: reindexdb {{database_name}} {{[-h|--host]}} {{hostname}} {{[-p|--port]}} {{port}} {{[-U|--username]}} {{username}}
-a, --allboolean

Reindex all databases

Example: reindexdb {{[-a|--all]}}
-t, --tableboolean

Reindex a specific table in a database

Example: reindexdb {{database_name}} {{[-t|--table]}} {{table_name}}
-i, --indexboolean

Reindex a specific index in a database

Example: reindexdb {{database_name}} {{[-i|--index]}} {{index_name}}
-S, --schemaboolean

Reindex a specific schema in a database

Example: reindexdb {{database_name}} {{[-S|--schema]}} {{schema_name}}
-v, --verboseboolean

Reindex with verbose output

Example: reindexdb {{database_name}} {{[-v|--verbose]}}
-j, --jobsboolean

Reindex a database using multiple parallel jobs

Example: reindexdb {{database_name}} {{[-j|--jobs]}} {{number_of_jobs}}

Examples (8)

Reindex a specific database

reindexdb database_name

Reindex a specific database using connection options

reindexdb database_name [-h|--host] hostname [-p|--port] port [-U|--username] username

Reindex all databases

reindexdb [-a|--all]

Reindex a specific table in a database

reindexdb database_name [-t|--table] table_name

Reindex a specific index in a database

reindexdb database_name [-i|--index] index_name

Reindex a specific schema in a database

reindexdb database_name [-S|--schema] schema_name

Reindex with verbose output

reindexdb database_name [-v|--verbose]

Reindex a database using multiple parallel jobs

reindexdb database_name [-j|--jobs] number_of_jobs
made by @shridhargupta | data from tldr-pages