| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Vijaykumar Jain <vijaykumarjain(dot)github(at)gmail(dot)com> |
| Cc: | Karsten Hilbert <Karsten(dot)Hilbert(at)gmx(dot)net>, pgsql-general <pgsql-general(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: pg_dump/pg_restore vs default_transaction_read_only under PG 13.2 |
| Date: | 2021-06-20 18:14:30 |
| Message-ID: | 1513081.1624212870@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Vijaykumar Jain <vijaykumarjain(dot)github(at)gmail(dot)com> writes:
> i have db example which i want to migrate from one version to another.
> to do that i disable writes on the db by setting the tx flag, so that i can
> be sure it is still serving reads, but no additional data is written.
> i can take a pg_dump, the db is still serving the reads.
What is the point of that? pg_dump will capture a consistent data
snapshot in any case. AFAICS, all you accomplish by disabling
writes on the source server is a self-inflicted DOS.
(Also, the fact that default_transaction_read_only is so easy to
override means it's not that useful as a means of disabling writes.)
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Karsten Hilbert | 2021-06-20 19:34:45 | Re: pg_dump/pg_restore vs default_transaction_read_only under PG 13.2 |
| Previous Message | Vijaykumar Jain | 2021-06-20 18:03:50 | Re: pg_dump/pg_restore vs default_transaction_read_only under PG 13.2 |