I can't upgrade from v1.5.3

Hello. I would like to ask for help; I am in a difficult situation. Thank you.

1. What is the issue? Please be detailed.

I am trying to upgrade from version 1.5.3, but it's not working

2. What steps can we take to reproduce this issue?

As the central upgrade page states: I begin with the v2023.2 documentation. The issue arises when I perform the 'Upgrade your database.' When I run 'docker-compose up postgres,' an error message appears that says:

"Checking for existing upgrade marker file... ERROR: New data found, but upgrade not flagged as complete. Please email support@getodk.org for assistance."

I don't know what to do... Could you help me, please? Thank you

4. Upload any forms or screenshots you can share publicly below.

Do you have a full system backup?

Try re-running the migration and see if it helps. If it works, continue at Step 8 (Check the output...) in Upgrading to Central v2023.2.

docker compose stop
docker compose pull
docker compose build --pull
docker compose up postgres
1 Like

Thanks for the response.

Searching the forum I found that instead of installing Docker Compose postgres, I had to install Docker Compose postgres14. And now it is processing, but it has been stuck for more than 2 hours. The database is like 3 gigs, is that normal? Is there a way to see if it is working?

Thanks again!

postgres error 2

I don't know where on the forum you found those instructions, but unless they came from the core team, they are not correct.

You need to run docker compose up postgres to make sure the migration is actually complete, then you have to restart the server, then bring up all the containers.

What you've done now is just bring up the new database container and who knows what state it's in. Also, without seeing what the other containers are doing, it's hard to say if it's working or not.

Personally, I would restore from backup and try again.

Another user has reported a similar problem at Upgrade to Central v2023.2 fails at "Stopping postgres server"; that discussion might be relevant.

Thanks for the reponse.

But the process in postgres14 is stuck when I do: docker compose postgres

Postgres14 does not upgrade

The central service look like this:

I have done several things with the server backup (like updating programs, updating the operating system, building new containers with the new version of docker-compose). Trying to see if anything changes.

But, the result is the same.

I'm stuck on the upgrade-postgres.sh

I would greatly appreciate your help.

I want to be very precise because you didn't mention what I'd asked about. Did you have a full machine backup? Did you restore that machine backup to before the upgrade and try again?

Did you have a full machine backup?

Yes. I made a full backup of the machine as it is in production without touching anything.

Did you restore that machine backup to before the upgrade and try again?

Yes. But I have been making changes, first do the upgrade without changing anything. Then updating the programs, then the containers, then the operating system, and so on.
Also making variations in the order.

1 Like

There should be a ~/central/files/postgres14/upgrade/upgrade-postgres.log file. Can you upload it?

There is no log.

only check-available-space

I was able to investigate and fix this issue on a clone on the server.

Once I had access, I determined that there was a previous attempt to upgrade months ago that was not completed. That previous attempt left the install in an unexpected state.

After confirming the old Postgres v9.6 was indeed the currently active database, I removed the incomplete Postgres v14 Docker volume (and thus database) and re-ran the upgrade following the instructions at https://docs.getodk.org/central-upgrade.