| From: | Michael Paquier <michael(at)paquier(dot)xyz> |
|---|---|
| To: | Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> |
| Cc: | rob stone <floriparob(at)tpg(dot)com(dot)au>, Dominique Devienne <ddevienne(at)gmail(dot)com>, pgsql-general(at)lists(dot)postgresql(dot)org |
| Subject: | Re: How to force "re-TOAST" after changing STORAGE or COMPRESSION? |
| Date: | 2023-10-03 04:45:22 |
| Message-ID: | ZRucYsOTalCdlSzU@paquier.xyz |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
On Tue, Oct 03, 2023 at 06:31:27AM +0200, Laurenz Albe wrote:
> On Tue, 2023-10-03 at 12:33 +1100, rob stone wrote:
>> Would running CLUSTER on the table use the new parameters for the re-
>> write?
>
> No, as far as I know.
Note that under the hoods VACUUM FULL and CLUSTER use the same code
paths when doing their stuff.
> You'd need something like
>
> -- rewrite all tuples
> UPDATE tab SET id = id;
> -- get rid of the bloat
> VACUUM (FULL) tab;
I'm afraid so, and get ready for a burst of WAL that depends on the
size of your relation if you are too aggressive with the updates. You
could do that in periodic steps, as well.
--
Michael
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Dominique Devienne | 2023-10-03 07:08:49 | Re: How to force "re-TOAST" after changing STORAGE or COMPRESSION? |
| Previous Message | Laurenz Albe | 2023-10-03 04:31:27 | Re: How to force "re-TOAST" after changing STORAGE or COMPRESSION? |