Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Data Bases > Pgsql Hackers > Re: odd output ...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 19 of 24 Topic 9349 of 10966
Post > Topic >>

Re: odd output in restore mode

by andrew@[EMAIL PROTECTED] (Andrew Dunstan) May 13, 2008 at 08:00 AM

Simon Riggs wrote:
> On Tue, 2008-05-13 at 08:42 +0100, Dave Page wrote:
>   
>> On Tue, May 13, 2008 at 2:38 AM, Tom Lane <tgl@[EMAIL PROTECTED]
> wrote:
>>     
>>> Andrew Dunstan <andrew@[EMAIL PROTECTED]
> writes:
>>>
>>>       
>>>> Simon Riggs wrote:
>>>>         
>>>  >> Well, the patch was rejected long ago, not sure why its in this
>>>  >> commitfest. But its an open issue on the Windows ****t.
>>>
>>>  > Surely the right fix is to use the recently implemented
>>>  > pgwin32_safestat() (if we aren't already - I suspect we probably
are)
>>>  > and remove the kluge in pg_standby.c.
>>>
>>>  I think the open issue is how to know whether pgwin32_safestat fixes
the
>>>  problem that the kluge tried to work around.
>>>       
>> Per the comments on the commitfest page, I don't believe it is.
>> pgwin32_safestat fixes a bug in which stat() returns stale information
>> (if memory serves). The hack in pg_standby was added because copy in
>> Windows appears to preallocate the required space for the file it's
>> copying, thus checking the file size to verify that the copy has
>> completed is not a valid test.
>>     
>
> Could somebody suggest and test an improvement to the Windows code, to
> fix the kluge?
>
>   

Given what Dave says, I'm not sure there is an easy one, at least 
without a lot of testing. Greg Stark's suggestion might or might not work.

However, we should probably make the behaviour switchable. If the 
archive_command populating the archive_directory were rsync, for 
example, this problem should not occur, because it copies to a temp 
file, and then renames it, so we should never see an incomplete file 
even though rsync also apparently preallocates space.

We should also do***ent it better in the code, along the lines of Dave's 
comment above.

cheers

andrew

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@[EMAIL PROTECTED]
)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
 




 24 Posts in Topic:
odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-12 16:57:01 
Re: odd output in restore mode
simon@[EMAIL PROTECTED]   2008-05-12 23:14:00 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-12 18:58:37 
Re: odd output in restore mode
dpage@[EMAIL PROTECTED]   2008-05-18 22:16:17 
Re: odd output in restore mode
bruce@[EMAIL PROTECTED]   2008-06-30 18:13:12 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-06-30 19:29:03 
Re: odd output in restore mode
simon@[EMAIL PROTECTED]   2008-05-13 00:37:53 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-12 21:15:55 
Re: odd output in restore mode
tgl@[EMAIL PROTECTED] (T  2008-05-12 21:38:58 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-12 23:03:25 
Re: odd output in restore mode
dpage@[EMAIL PROTECTED]   2008-05-13 17:15:12 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-18 08:38:12 
Re: odd output in restore mode
xzilla@[EMAIL PROTECTED]   2008-05-12 21:06:26 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-12 22:40:38 
Re: odd output in restore mode
simon@[EMAIL PROTECTED]   2008-05-13 06:44:35 
Re: odd output in restore mode
simon@[EMAIL PROTECTED]   2008-05-13 06:37:24 
Re: odd output in restore mode
dpage@[EMAIL PROTECTED]   2008-05-13 08:42:26 
Re: odd output in restore mode
simon@[EMAIL PROTECTED]   2008-05-13 09:32:55 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-13 08:00:29 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-13 08:26:35 
Re: odd output in restore mode
alvherre@[EMAIL PROTECTED  2008-05-13 11:08:52 
Re: odd output in restore mode
andrew@[EMAIL PROTECTED]   2008-05-13 12:05:58 
Re: odd output in restore mode
alvherre@[EMAIL PROTECTED  2008-05-13 12:11:30 
Re: odd output in restore mode
bruce@[EMAIL PROTECTED]   2008-06-30 18:11:02 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Mon Dec 1 14:34:40 CST 2008.