Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit51eeccd

Browse files
committed
Add removal of PG_VERSION to optional old cluster deletion script.
Backpatch to 9.0.X.
1 parentf75d6a1 commit51eeccd

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

‎contrib/pg_upgrade/check.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -416,6 +416,11 @@ create_script_for_old_cluster_deletion(migratorContext *ctx,
416416
intdbnum;
417417

418418
fprintf(script,"\n");
419+
/* remove PG_VERSION? */
420+
if (GET_MAJOR_VERSION(ctx->old.major_version) <=804)
421+
fprintf(script,RM_CMD" %s%s/PG_VERSION\n",
422+
ctx->tablespaces[tblnum],ctx->old.tablespace_suffix);
423+
419424
for (dbnum=0;dbnum<ctx->new.dbarr.ndbs;dbnum++)
420425
{
421426
fprintf(script,RMDIR_CMD" %s%s/%d\n",

‎contrib/pg_upgrade/pg_upgrade.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,15 @@
3838
#definepg_copy_filecopy_file
3939
#definepg_mv_filerename
4040
#definepg_link_filelink
41+
#defineRM_CMD"rm -f"
4142
#defineRMDIR_CMD"rm -rf"
4243
#defineSHELL_EXT"sh"
4344
#else
4445
#definepg_copy_fileCopyFile
4546
#definepg_mv_filepgrename
4647
#definepg_link_filewin32_pghardlink
4748
#definesleep(x)Sleep(x * 1000)
49+
#defineRM_CMD"DEL /q"
4850
#defineRMDIR_CMD"RMDIR /s/q"
4951
#defineSHELL_EXT"bat"
5052
#defineEXE_EXT".exe"

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp