Re: pg_basebackup vs. Windows and tablespaces

From: Dilip kumar <dilip(dot)kumar(at)huawei(dot)com>
To: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Magnus Hagander <magnus(at)hagander(dot)net>, Noah Misch <noah(at)leadboat(dot)com>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_basebackup vs. Windows and tablespaces
Date: 2014-08-20 06:42:04
Message-ID: 4205E661176A124FAF891E0A6BA913526634BF56@szxeml509-mbs.china.huawei.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

15 July 2014 19:29 Amit Kapila Wrote,

>Implementation details:
-----------------------------------
>1. This feature is implemented only for tar format in windows
>as native windows utilites are not able to create symlinks while
>extracting files from tar (It might be possible to create symlinks
>if cygwin is installed on your system, however I feel we need this
>feature to work for native windows as well). Another reason to not
>create it for non-tar (plain) format is that plain format can update the
>symlinks via -T option and backing up symlink file during that
>operation can lead to spurious symlinks after archive recovery.

I have reviewed the patch and did not find any major comments.

There are some comments I would like to share with you

1. Rebase the patch to current GIT head.

2. + * Construct symlink file

+ */

+ initStringInfo(&symlinkfbuf);
I think declaration and initialization of symlinkfbuf string can be moved under #ifdef WIN32 compile time macro,
for other platform it’s simply allocated and freed which can be avoided.

3. + /*

+ * native windows utilites are not able create symlinks while

+ * extracting files from tar.

+ */

Rephrase the above sentence and fix spelling mistake (utilities are not able to create)

I haven’t done the testing yet, once I finish with testing i will share the result with you.

Regards,
Dilip

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2014-08-20 07:09:00 Re: KNN searches support for SP-GiST [GSOC'14]
Previous Message Mark Kirkwood 2014-08-20 06:11:57 Re: Trove with PostgreSQL-XC