0

When i try to Upgrade 9.4 to 13 using pg_upgrade , the Upgrade stops in between with authentication failure using the password from pgpass.conf file .

The same approach works from 9.4 to 9.6

Here is the pg_upgrade command that i used

C:\postgresql\13\bin\pg_upgrade --old-datadir C:/PostgreSQL/9.4/data --new-datadir C:/PostgreSQL/13/data --old-bindir C:/PostgreSQL/9.4/bin --new-bindir C:/PostgreSQL/13/bin --old-port=5433 --new-port=5435 --username <superusername> --verbose

I am running this command from %temp%

  • I doubt that this is your real command line. You didn't specify a username for the `--username` option. Well you do, but it is accidently the very odd username "--verbose". And why are you specifying port numbers? – jjanes Aug 05 '21 at 18:53
  • i have specified a superusername . . . i just didnt post it here. when i dont specify the port numbers , the pg_upgrade is considering 5432 as old port. So i had to specify the port – Manoj Kumaar S Aug 05 '21 at 19:30
  • pg_upgrade should default to port 50432, not 5432. Do you have environment variables such as PGPORTNEW from some previous work left over polluting your environment ? – jjanes Aug 05 '21 at 19:38

1 Answers1

0

To do the migration, I used logical replication using the server with version 9.4 to replicate to a server with version 13. Another option would be to migrate using pg_dumpall and pg_restore.

Eric Aya
  • 69,473
  • 35
  • 181
  • 253