Skip to content

Locking issue while creating indexes #430

Description

@yusufnar

We use pg_repack to reorganize some large tables(between 100GB and 1TB). We don't have any locking issues while creating the triggers on the source table and swapping tables at the end. But every index creation on the shadow table causes locking issues. The lock waits start to happen just after the CREATE INDEX command starts on the shadow table. It does not last along the whole creation process. The locking disappears after a while, i.e it happens in the first 30 seconds of index creation, but the index creation takes 10 minutes.

Here is the command we are using:

pg_repack -k -e -h <host_name> -d <db_name> -U <user_name> -t <table_name> -o  <column_list>

We are on pg_repack-1.4.6 and PostgreSQL 13.13.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions