Thread: [GENERAL] PG96 pg_restore connecting to PG95 causes ERROR: unrecognizedconfiguration parameter "idle_in_transaction_session_timeout"
[GENERAL] PG96 pg_restore connecting to PG95 causes ERROR: unrecognizedconfiguration parameter "idle_in_transaction_session_timeout"
From
Justin Pryzby
Date:
When doing a dump+restore upgrade, it's commonly recommended to use the later version of pg_restore: https://www.postgresql.org/docs/current/static/upgrading.html "It is recommended that you use the pg_dump and pg_dumpall programs from the newer version of PostgreSQL, to take advantage of enhancements that might have been made in these programs. Current releases of the dump programs can read data from any server version back to 7.0." In the immediate case, I was loading data from PG95 dumps into PG95 server (not an upgrade), using P96 pg_restore, and getting: ERROR: unrecognized configuration parameter "idle_in_transaction_session_timeout" I can't see anybody has raised that issue before. Should pg_restore check the remote server version and avoid sending commands not expected to be understood? (Yes, I know and use pg_upgrade, however I'm currenting migrating a DB between servers and this procedure will allow doing so with ~30min downtime...pg_upgrade to 9.6 will be done afterwards, which is why PG96 pg_upgrade is installed). Thanks, Justin
Re: [GENERAL] PG96 pg_restore connecting to PG95 causes ERROR: unrecognized configuration parameter "idle_in_transaction_session_timeout"
From
Tom Lane
Date:
Justin Pryzby <pryzby@telsasoft.com> writes: > When doing a dump+restore upgrade, it's commonly recommended to use the later > version of pg_restore: > https://www.postgresql.org/docs/current/static/upgrading.html > "It is recommended that you use the pg_dump and pg_dumpall programs from the > newer version of PostgreSQL, to take advantage of enhancements that might have > been made in these programs. Current releases of the dump programs can read > data from any server version back to 7.0." That says to use the pg_dump version *corresponding to the destination server version*, not the latest version you can find anywhere. No version of pg_dump has ever promised that its output would load perfectly cleanly into lower-version destination servers, and that's not a set of new compatibility constraints that I'd want to take on. regards, tom lane