Having trouble with `fly pg import`

I’m having trouble with fly pg import today when migrating my heroku db to fly. I’m getting this output:

? Select VM size: shared-cpu-2x - CPU Kind: Shared, vCPUs: 2, Memory: 4GB
Waiting for machine e148e03b2d7089 to start...
Connecting to fdaa:2:8629:a7b:ab3:a252:bd6:2... complete
[info] Running pre-checks...
[info] Source Postgres version: 14.8 (Ubuntu 14.8-1.pgdg20.04+1)
[info] Target Postgres version: 15.3 (Debian 15.3-1.pgdg110+1)
[info] Pre-checks completed without issue
[info] Starting import process... (This could take a while)
[error] failed to import database: exit status 2
Error: failed to run ssh: ssh shell: Process exited with status 1

If it matters, the region is ewr. It created the database with the same tables and columns, but there’s no rows Is anyone else having problems with it?

I just tried it again and it said it failed, same error as before, but I double checked the database and all the data is there. No idea what happened.

Ok, turns out the import was actually not completely successful. All of my db indexes are gone, and so are the constraints.

I was able to get it to work with these steps:

  1. manually create the destination database
  2. run database migrations
  3. run the importer

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.