speed up full table scan using psql

From: Lian Jiang <jiangok2006(at)gmail(dot)com>
To: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: speed up full table scan using psql
Date: 2023-05-31 04:25:53
Message-ID: CA+aY8X6E6qq-i_10G_wTjkorEtm3XYW+Ag+83xk7gmJUoAoing@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

hi,

I am using psql to periodically dump the postgres tables into json files
which are imported into snowflake. For large tables (e.g. 70M rows), it
takes hours for psql to complete. Using spark to read the postgres table
seems not to work as the postgres read only replication is the bottleneck
so spark cluster never uses >1 worker node and the working node timeout or
out of memory.

Will vertical scaling the postgres db speed up psql? Or any thread related
parameter of psql can help? Thanks for any hints.

Regards
Lian

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Rob Sargent 2023-05-31 04:36:40 Re: speed up full table scan using psql
Previous Message Bruce Momjian 2023-05-31 02:28:58 Re: Pg 16: will pg_dump & pg_restore be faster?