"standby clone": rsync mode does of course accept -c/--fast-checkpoint

This commit is contained in:
Ian Barwick
2017-05-05 19:03:33 +09:00
parent 22c2f01d87
commit bb0aac8912
2 changed files with 8 additions and 11 deletions

View File

@@ -293,10 +293,6 @@ do_standby_clone(void)
break; break;
case pg_basebackup: case pg_basebackup:
log_notice(_("starting backup (using pg_basebackup)...")); log_notice(_("starting backup (using pg_basebackup)..."));
if (runtime_options.fast_checkpoint == false)
{
log_hint(_("this may take some time; consider using the -c/--fast-checkpoint option"));
}
break; break;
case barman: case barman:
log_notice(_("getting backup from Barman...")); log_notice(_("getting backup from Barman..."));
@@ -306,6 +302,14 @@ do_standby_clone(void)
log_error(_("unknown clone mode")); log_error(_("unknown clone mode"));
} }
if (mode == pg_basebackup || mode == rsync)
{
if (runtime_options.fast_checkpoint == false)
{
log_hint(_("this may take some time; consider using the -c/--fast-checkpoint option"));
}
}
if (mode == pg_basebackup) if (mode == pg_basebackup)
{ {
r = run_basebackup(); r = run_basebackup();

View File

@@ -907,13 +907,6 @@ check_cli_parameters(const int action)
item_list_append(&cli_warnings, item_list_append(&cli_warnings,
_("--no-upstream-connection only effective in Barman mode")); _("--no-upstream-connection only effective in Barman mode"));
} }
if (runtime_options.fast_checkpoint && runtime_options.rsync_only)
{
item_list_append(&cli_warnings,
_("-c/--fast-checkpoint has no effect when using -r/--rsync-only"));
}
} }
} }
break; break;