Re: [bug fix] PostgreSQL fails to start on Windows if it crashes after tablespace creation - Mailing list pgsql-hackers

From MauMau
Subject Re: [bug fix] PostgreSQL fails to start on Windows if it crashes after tablespace creation
Date
Msg-id E98B469BA1D74D66A69103C6392335F0@maumau
Whole thread Raw
In response to Re: [bug fix] PostgreSQL fails to start on Windows if it crashes after tablespace creation  (Amit Kapila <amit.kapila16@gmail.com>)
Responses Re: [bug fix] PostgreSQL fails to start on Windows if it crashes after tablespace creation
Re: [bug fix] PostgreSQL fails to start on Windows if it crashes after tablespace creation
List pgsql-hackers
From: "Amit Kapila" <amit.kapila16@gmail.com>
> On Wed, Jan 15, 2014 at 8:12 PM, MauMau <maumau307@gmail.com> wrote:
>> Thanks for reviewing and testing the patch.  Yes, at first I did what you
>> mentioned, but modified the patch according to some advice in the mail
>> thread.  During redo, create_tablespace_directories() needs to handle the
>> case where the $PGDATA/pg_tblspc/xxx is not a symlink but a directory 
>> even
>> on UNIX/Linux.  Please see TablespaceCreateDbspace is().
>> destroy_tablespace_directories() doesn't have to handle such situation.
>
> If create_tablespace_directories() needs to handle with directory both on
> Windows/Linux, then shouldn't it be a runtime check as in your first
> version rather than compile time check?
> Also isn't that the reason why destroy_tablespace_directories() have 
> similar
> check?

I see..., and you are correct.  The first version of my patch should be the 
right fix.  It seems that my head went somewhere when I submitted the second 
revision.

What should I do?  Should I re-submit the first revision as the latest fifth 
revision and link the email from the CommitFest newest entry?

Regards
MauMau







pgsql-hackers by date:

Previous
From: Atri Sharma
Date:
Subject: Re: Optimized out tags
Next
From: Peter Geoghegan
Date:
Subject: Re: jsonb and nested hstore