Re: [PATCHES] odd output in restore mode
От | Heikki Linnakangas |
---|---|
Тема | Re: [PATCHES] odd output in restore mode |
Дата | |
Msg-id | 48877AC0.7070603@enterprisedb.com обсуждение исходный текст |
Ответ на | Re: [PATCHES] odd output in restore mode (Simon Riggs <simon@2ndquadrant.com>) |
Ответы |
Re: [PATCHES] odd output in restore mode
Re: [PATCHES] odd output in restore mode |
Список | pgsql-hackers |
Simon Riggs wrote: > On Tue, 2008-07-22 at 17:19 -0700, Martin Zaun wrote: >> 8. Unresolved question of implementing now/later a "cp" replacement > > The patch implements what's been agreed. > > I'm not rewriting "cp", for reasons already discussed. > > Not a comment to you Martin, but it's fairly clear that I'm not > maintaining this correctly for Windows. I've never claimed to have > tested this on Windows, and only included Windows related items as > requested by others. I need to make it clear that I'm not going to > maintain it at all, for Windows. If others wish to report Windows issues > then they can suggest appropriate fixes and test them also. Hmm. I just realized that replacing the "cp" command within pg_standby won't help at all. The problem is with the command that copies the files *to* the archivelocation that pg_standby polls, not with the copy pg_standby does from archivelocation to pg_xlog. And we don't have much control over that. We really need a more reliable way of detecting that a file has been fully copied. One simple improvement would be to check the xlp_magic field of the last page, though it still wouldn't be bullet-proof. Do the commands that preallocate the space keep the file exclusively locked during the copy? If they do, shouldn't we get an error in trying to run the restore copy command, and retry after the 1s sleep in RestoreWALFileForRecovery? Though if the archive location is a samba mount or something, I guess we can't rely on Windows-style exclusive locking. -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com
В списке pgsql-hackers по дате отправления: