Skip to content

Instantly share code, notes, and snippets.

@Bobsans
Last active April 29, 2020 09:20
Show Gist options
  • Select an option

  • Save Bobsans/7e94cb0756015c042ff8e569a35ac8f7 to your computer and use it in GitHub Desktop.

Select an option

Save Bobsans/7e94cb0756015c042ff8e569a35ac8f7 to your computer and use it in GitHub Desktop.
Migration to new version of PostgreSQL on Windows

Run it in new postgres bin folder

pg_upgrade.exe 
  -b D:\database\PostgreSQL-9.5-x64\bin     -- old postgres bin folder without end slash
  -B D:\database\PostgreSQL-10.7-x64\bin    -- new postgres bin folder without end slash
  -d D:\cluster\PostgreSQL-9.5-x64          -- old postgres cluster data folder without end slash
  -D D:\cluster\PostgreSQL-10.7-x64         -- new postgres cluster data folder without end slash
  -U postgres
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment