3 ms·
You need to use pg_dump from the new version, not from the old version.
by castorp 4y ago
You need to use pg_dump from the new version, not from the old version.
- jasfi 4y agoI think you found a common stumbling block. The tutorial people follow may say to run pg_dump and many people would assume you're running it from the old version.
- rapind 4y agoWait, what? Explain please. OK upon further thought, what you're saying is to use the pg_dump tool that comes with the pg version you are upgrading to. I read it as "use pg_dump instead of pg_restore"...
- mh- 4y agoYes. Put concisely: Use the client tools from the newest version involved for all steps.
- oblio 4y agoIsn't that impractical for most Linux distros? You'd need to manually install the new client.
- mh- 4y agoProbably? Certainly if you rely on distro packaging for it, yes. I was just trying to simplify the guidance here. :)
- BGZq7 4y agoOn Debian (and probably most of its derivatives), the package manager will not remove any running PostgreSQL versions and will let you have multiple versions side by side. It also has its own tool pg_upgradecluster, which can perform the upgrade using pg_dump+pg_restore or pg_upgrade (optionally with link or clone options).
- autra 4y agoYes, and usually, it means you need to use the full binary path unfortunately (because debian wrappers embedded in the package select the version from your 5432 cluster).