diff options
| author | Bruce Momjian <bruce@momjian.us> | 2011-04-19 21:00:29 -0400 |
|---|---|---|
| committer | Bruce Momjian <bruce@momjian.us> | 2011-04-19 21:00:29 -0400 |
| commit | 7228d02989afd3858ce6eb4de845c56f4c0188a6 (patch) | |
| tree | 5d426003d718469270cba5877ddc40740cdd7fee /contrib/pg_upgrade/relfilenode.c | |
| parent | 034194470647b3de206fb42464d49a438853fa5e (diff) | |
Throw error for mismatched pg_upgrade clusters
If someone removes the 'postgres' database from the old cluster and the
new cluster has a 'postgres' database, the number of databases will not
match. We actually could upgrade such a setup, but it would violate the
1-to-1 mapping of database counts, so we throw an error instead.
Previously they got an error during the upgrade, and not at the check
stage; PG 9.0.4 does the same.
Diffstat (limited to 'contrib/pg_upgrade/relfilenode.c')
| -rw-r--r-- | contrib/pg_upgrade/relfilenode.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/contrib/pg_upgrade/relfilenode.c b/contrib/pg_upgrade/relfilenode.c index 6fb336cfc53..9a0a3ac18d9 100644 --- a/contrib/pg_upgrade/relfilenode.c +++ b/contrib/pg_upgrade/relfilenode.c @@ -37,12 +37,6 @@ transfer_all_new_dbs(DbInfoArr *old_db_arr, prep_status("Restoring user relation files\n"); - /* - * If the user removed the 'postgres' database from the old cluster, - * this will cause the database counts to not match and throw an error. - * We could allow this to work because the new database is empty (we - * checked), but we don't. - */ if (old_db_arr->ndbs != new_db_arr->ndbs) pg_log(PG_FATAL, "old and new clusters have a different number of databases\n"); |
