tripleo-ci-centos-7-containerized-undercloud-upgrades fails with error InternalError: pymysql.err.InternalError - Table scheduled_jobs_v2 already exists

Bug #1844111 reported by Sagi (Sergey) Shnaidman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
Critical
Mike Fedosin

Bug Description

tripleo-ci-centos-7-containerized-undercloud-upgrades job fails with error when running undercloud upgrade:

2019-09-16 05:07:09 | "InternalError: (pymysql.err.InternalError) (1050, u\"Table 'scheduled_jobs_v2' already exists\") [SQL: u'\\nCREATE TABLE scheduled_jobs_v2 (\\n\\tcreated_at DATETIME, \\n\\tupdated_at DATETIME, \\n\\tid VARCHAR(36) NOT NULL, \\n\\trun_after INTEGER, \\n\\ttarget_factory_func_name VARCHAR(200), \\n\\tfunc_name VARCHAR(80), \\n\\tfunc_args TEXT, \\n\\tfunc_arg_serializers TEXT, \\n\\tauth_ctx TEXT, \\n\\texecute_at DATETIME NOT NULL, \\n\\tcaptured_at DATETIME, \\n\\t`key` VARCHAR(250), \\n\\tPRIMARY KEY (id)\\n)\\n\\n'] (Background on this error at: http://sqlalche.me/e/2j85)",

https://eea42911c698b78df1c8-f843b77276d6aeb0869490db64537ade.ssl.cf1.rackcdn.com/682265/2/check/tripleo-ci-centos-7-containerized-undercloud-upgrades/1cf789a/logs/undercloud/home/zuul/undercloud_upgrade.log.txt.gz

Tags: upgrade
Changed in tripleo:
milestone: train-3 → train-rc1
Revision history for this message
Jose Luis Franco (jfrancoa) wrote :

So, I can see that a new alembic migration was recently added which matches with the error logs -> https://github.com/openstack/mistral/blob/master/mistral/db/sqlalchemy/migration/alembic_migrations/versions/034_add_scheduled_jobs_table.py

@Mike, could you give us a hand debugging this issue? It seems to be mostly mistral db migration, isn't it? Should we perform any task during the upgrade to ensure this does not occur?

Changed in tripleo:
assignee: nobody → Mike Fedosin (mfedosin)
Revision history for this message
Jose Luis Franco (jfrancoa) wrote :

The patch https://review.opendev.org/#/c/685036/1 should fix it. Adding a DNM patch with a Depends-On to test it.

Changed in tripleo:
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.