Failing to restore a 1.9.3 backup to any newer version, user_auth_token doesn't exist

So we’ve got a couple elderly 1.9.3 installs that we’re working to moving to current installs, I originally tried a straight upgrade that blew up in my face with a migration error, since then I’ve tried exporting backups from the UI and then importing them into clean, current installs and each time it fails with some variation on this error if I tail the production.log:

Unexpected error in Message Bus : PG::UndefinedTable: ERROR: relation “user_auth_tokens” does not exist

On the console in the web UI we don’t get much more:

[2019-10-08 15:41:33] invalid command \N
[2019-10-08 15:41:33] EXCEPTION: psql failed
[2019-10-08 15:41:33] /srv/discourse/2.0.5/lib/backup_restore/restorer.rb:327:in restore_dump' /srv/discourse/2.0.5/lib/backup_restore/restorer.rb:68:in run’

Then a giant traceback that more or less appears to boil down to “psql failed”, so I’m assuming it’s related to the SQL errors in the production log.

This isn’t running inside the standard Docker container so it’s possible I’ve missed something stupid during setup but I can’t find any errors that would point me in that direction. I’ve tried restoring into a 2.4 beta install and (the version the log lines above are from) a 2.0.5 install, just in case I was trying to jump too many versions. Any thoughts?

Please try restoring in a Docker based install. That’s the only supported way of running Discourse.

4 Likes

That looks like a postgres version error, but I’m not entirely sure.

I’ve done some pretty ancient upgrades that I was sure would fail and worked just fine. They were standard installs, however.

If you’d like to switch to a standard installation (or at least something docker-based) and have a budget, you’re welcome to post in #marketplace or contact me directly.

1 Like