RE: [bug fix] pg_rewind creates corrupt WAL files, and the standbycannot catch up the primary
От | Tsunakawa, Takayuki |
---|---|
Тема | RE: [bug fix] pg_rewind creates corrupt WAL files, and the standbycannot catch up the primary |
Дата | |
Msg-id | 0A3221C70F24FB45833433255569204D1F8ED14A@G01JPEXMBYT05 обсуждение исходный текст |
Ответ на | Re: [bug fix] pg_rewind creates corrupt WAL files, and the standbycannot catch up the primary (Michael Paquier <michael@paquier.xyz>) |
Ответы |
Re: [bug fix] pg_rewind creates corrupt WAL files, and the standbycannot catch up the primary
|
Список | pgsql-hackers |
From: Michael Paquier [mailto:michael@paquier.xyz] > Yes, it should not copy those WAL files. Most of the time they are going > to be meaningless. See this recent thread: > https://www.postgresql.org/message-id/20180126023609.GH17847%40paquier > .xyz > So I would rather go this way instead of having to worry about manipulating > those WAL segments as you do. Depending on the needs, I think that even > a backpatch could be considered. Thank you for information. I didn't notice those activities going around pg_rewind. It's a regret that Chen's patch, which limits the WAL to be copied, is not committed yet. It looks good to be ready forcommitter. > > Related to this, shouldn't pg_rewind avoid copying more files and > > directories like pg_basebackup? Currently, pg_rewind doesn't copy > > postmaster.pid, postmaster.opts, and temporary files/directories > > (pg_sql_tmp/). > > Yes, it should not copy those files. I have a patch in the current CF to > do that: > https://commitfest.postgresql.org/17/1507/ Wow, what a great patch. I think I should look at it. But I'm afraid it won't be backpatched because it's big... Even with your patch and Chen's one, my small patch is probably necessary to avoid leaving 0-byte or half-baked files. I'mnot sure whether those strangely sized files would cause actual trouble, but maybe it would be healthy to try to cleanthings up as much as possible. (files in pg_twophase/ might emit WARNING messages, garbage server log files might makethe DBA worried, etc.; yes, these may be just FUD.) Regards Takayuki Tsunakawa
В списке pgsql-hackers по дате отправления: