roots / trellis

WordPress LEMP stack with PHP 8.2, Composer, WP-CLI and more
https://roots.io/trellis/
MIT License
2.49k stars 608 forks source link

MariaDB 10.6.18 release requires action #1517

Closed nikitasol closed 1 month ago

nikitasol commented 3 months ago

Version

1.22.0

What did you expect to happen?

Seamless sync between production/staging and development

What actually happens?

MariaDB 10.6.18 adds sandbox comman as per release notes and the new line at the top of the db export breaks syncing.

Steps to reproduce

Just re-provision production/staging so the new MariaDB is installed there and then try exporting/importing db either through the amazing sync.sh or manually.

The line which is added is this:

/*!999999\- enable the sandbox mode */

System info

No response

Log output

No response

Please confirm this isn't a support request.

No

retlehs commented 3 months ago

MariaDB breaking database dumps in a patch release is wild 😞

Other relevant discussions/issues:

https://jira.mariadb.org/browse/MDEV-34183 https://github.com/ddev/ddev/issues/6249 https://github.com/wp-cli/db-command/issues/254

nikitasol commented 3 months ago

Just to add a few possible solutions:

nikitasol commented 3 months ago

And to confirm that rebuilding vm with updated MariaDB also works too.

strarsis commented 2 months ago

For my local development (Docker-based) setup (Debian-based) I had to use curl -LsS https://r.mariadb.com/downloads/mariadb_repo_setup | bash -s -- --mariadb-server-version="mariadb-11.2" and installed the mariadb-client package as a drop-in for mysql-client. The 11.2 version is much newer and has the issue fixed. This also works on Ubuntu. Edit: Do not blindly use that command above on a production system. https://discourse.roots.io/t/sync-script-fix-for-error-at-line-1-unknown-command/27734

retlehs commented 1 month ago

If you're a sync script user landing on this issue, take a look at this solution from @joshuafredrickson:

https://discourse.roots.io/t/sync-script-fix-for-error-at-line-1-unknown-command/27734

We've also upgraded MariaDB in Trellis (https://github.com/roots/trellis/pull/1520) which will be in the next release