Best way to migrate from self-hosted Redash v1.0.3 to v8

Issue Summary

I’d like to migrate a few self-hosted Redash instances from v1 to v8 - preferrably using a process which would be most bullet-proof (scripted, repeatable, minimize manual intervention).

Reading https://redash.io/help/open-source/admin-guide/how-to-upgrade-legacy it seems like running upgrade script should be enough. However some threads on this form (can’t paste the second link :confused: ) suggest that you can only upgrade from one major version to the next one.

There is also https://gist.github.com/arikfr/d29db3617df5a8d547b4709a631f5b6a by @arikfr which is looks quite nice. Setting up v8 separately and using the script to migrate from v1 to v8 would be the easiest but I don’t know if the script migrates everything.

What would be the recommended way of running the migration?

  1. upgrade script directly from v1 to v8?
  2. upgrade script running from v1 to v2, v2 to v3, …, up to v8?
  3. migrator script?

That’s because our documentation says so:

For best results you should upgrade Redash by one semantic version at a time. To move from V4 to V7, for example, you should upgrade V4 to V5 to V6 to V7.

It also talks about upgrading from earlier versions straight to V8: don’t do it

If you are currently running an instance of Redash prior to V7, do not upgrade directly to V8 . Upgrade semantically to V7 first . Read more about this on our forum here.

Upgrade ➞ Migrate ➞ Upgrade

You only need to migrate if moving from one kind of installation to another. Like legacy to Docker, open source to SaaS, or from one physical machine to another. And it’s best to migrate to and from the same version.

For you, I advise following the upgrade path to V7, then migrate to Docker V7, then upgrade your Docker V7 to Docker V8.

Since V8, we longer distribute binaries for the upgrade CLI. You can still do it but there’s some hassle involved. Changing to a Docker setup is your easiest route to an ongoing upgrade path that is “scripted, repeatable, [and] minimize[s] manual intervention”.

FYI, we’re adding the migration script to redash_toolbelt (should be finished next month). One less gist to keep track of :smiley:

Holy buckets! Nice to see a long-time user!

Thanks a lot for clarification!

Unfortunately, Docker is not an option at places we’re running Redash in. We do have Python expertise so I believe we can figure out running Redash without Docker (by looking at Dockerfile ;).
I guess our only route is scripting migrations from N to N+1.

Since V8, we longer distribute binaries for the upgrade CLI

Is migrate written in Python? If yes what do you mean by binaries?

1 Like

Definitely. Nothing Redash does is all that complicated. Most of us doing development work just develop in a local installation without Docker (due to the overhead when rebuilding assets).

I wrote the wrong word. Meant to say we don’t make tarballs anymore with the upgrade script.

1 Like