From: | vignesh ravichandran <admin(at)viggy28(dot)dev> |
---|---|
To: | "pgsql-hackers" <pgsql-hackers(at)postgresql(dot)org> |
Cc: | "vignesh" <vignesh(at)cloudflare(dot)com>, "jkwan" <jkwan(at)cloudflare(dot)com> |
Subject: | Making pg_rewind faster |
Date: | 2022-06-30 13:22:28 |
Message-ID: | 181b4c6fa9c.b8b725681941212.7547232617810891479@viggy28.dev |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi Hackers,
I have been using pg_rewind in production for 2 years. One of the things that I noticed in pg_rewind is if it doesn't know what to do with a file "it copies". I understand it's the more safer option. After all, the alternative, pg_basebackup copies all the files from source to target.
However, this is making pg_rewind inefficient when we have a high number of WAL files. Majority of the data (in most of my cases 95%+) that it copies are WAL files which are anyway same between the source and target. Skipping those same WAL files from copying will improve the speed of pg_rewind a lot.
1. Does pg_rewind need to copy WAL files before the WAL that contains the last common check point?
Heikki's presentation https://pgsessions.com/assets/archives/pg_rewind-presentation-paris.pdf gave me a good overview and also explained the behavior what I mentioned.
Thanks,
Vignesh
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2022-06-30 13:42:11 | Re: replacing role-level NOINHERIT with a grant-level option |
Previous Message | Isaac Morland | 2022-06-30 12:57:04 | Re: pg_checkpointer is not a verb or verb phrase |