Hi team, could we have some guidances on how to ro...
# flyte-support
h
Hi team, could we have some guidances on how to roll back the db changes when upgrading to v1.14.0? We are originally at v1.11.0, when upgrading to v1.14.0, we run
flyteadmin migrate
which likely hit the migration of db in here. By rolling back to v1.11.0, this db change is breaking our service since the db schema changed. What would be the recommendation from Flyte to rollback the db schema? error logs:
Copy code
2025/01/08 18:38:33 [31;1m/go/src/github.com/flyteorg/flyteadmin/pkg/repositories/gormimpl/execution_repo.go:27 [35;1mERROR: relation "admin_tags" does not exist (SQLSTATE 42P01); ERROR: relation "admin_tags" does not exist (SQLSTATE 42P01)
a
Hey Gilbert This is tricky but the migrate logic include rollbacks. You should have a backup of your db. You can try rolling back either with
gorm
or manually running the SQL commands defined on each rollback
h
Thanks for the reply David!
You should have a backup of your db
That's how to resolve this issue yesterday. For the
admin_tags
table, I saw in v1.14.0's migration code that it doesn't provide the rollback method to rollback that table. What is the proper way to restore it? Is it rolling back this table will grantee v1.11.0 will work? Moreover, regarding the process of our upgrade, I think it is difficult to execute the SQL command. 1. We pull the container of
flyte-admin
. 2. We spin up a pod and run
flyteadmin migrate
and
flyteadmin serve
. a. While
migrate
can run successfully, but the
flyteadmin serve
will fail at finding the
10254
port is in use. (more context in here) b. The pod will close afterwards. With the process above, we don't have a way to actually login the pod and run the rollback command (at least as of now). The
serve
cmd ran perfectly on v1.11.0, but it breaks at v1.14.0. What direction you think we can try to troubleshoot this issue?