Discovery switching to mysql 5.7

Hello folks! Discovery is the latest service to switch to mysql 5.7 (5.6 is going EOL in February).

The next time you update your devstack checkout or pull new discovery images, you might notice that you no longer have any data in course-discovery. Have no fear! These devstack commands will copy your data from your 5.6 database to the new shiny (and empty) 5.7 database:

If you haven’t reprovisioned lately, you’ll want to update code & images and initialize the mysql57 container. Heads up that this part might take a bit (maybe an hour?)

These commands should be run in your local devstack checkout:

git checkout master && git pull
make dev.down dev.reset-repos dev.pull dev.up dev.static
docker-compose exec -T mysql57 bash -c "mysql -uroot mysql" < provision.sql
make dev.migrate

And then finally actually copy the data over
make dev.dbcopy57.discovery

This is hopefully a seamless transition, but hit me up if you encounter any problems.

2 Likes