Skip to content

Instantly share code, notes, and snippets.

@dsouzajude
Created October 23, 2022 12:21
Show Gist options
  • Save dsouzajude/17605fff2a92297f3458d243d025a9ec to your computer and use it in GitHub Desktop.
Save dsouzajude/17605fff2a92297f3458d243d025a9ec to your computer and use it in GitHub Desktop.
Apply indexes via pg_restore in tmux
# Start a tmux session
tmux new -s replication
# Apply indexes from the schema taken before (https://gist.github.com/dsouzajude/ac6cc637665e6f7c418edea351b6e3fc)
pg_restore -h $RDS_ENDPOINT -p 5432 --user postgres --dbname $DB_NAME -v -Fc -j 35 -L indexes-etc.list schema-post-data.dump
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment