-
-
Notifications
You must be signed in to change notification settings - Fork 545
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MySQL 8 Causes Lando to fail startup #1462
Comments
@alessandro-bonfatti-pv you might have better luck on one of the newer versions id try one of those and then reopen this if you still have issues |
I had the same issue after I updated Lando to the new release. I think the error is related to the mysql.cnf file used by lando (
I solved my issue by using a custom configuration file without the following:
|
@alessandro-bonfatti-pv this is fixed in RC10 but note that you need to |
@pirog rc10 fixed that issue but I get a new error now:
The Lando file is:
I can work around it using default-authentication-plugin with mysql_native_password but it should work OOTB or be documented. Do you have new docs around it? |
@alessandro-bonfatti-pv im guessing the thing that needs to work out of the box is the mysql client that drupal uses and not lando. See https://bugs.php.net/bug.php?id=76243 |
@pirog I may agree with that but some extra doc may help and the mysql.cnf could include a setting to avoid the error. The current status is that Lando mysql 8 doesn't work OOTB. |
I don't think changing our default config for mysql8 because one client doesnt fully support it makes sense. Please note that Lando is meant for ALL KINDS of development, not just php, so a more accurate "current status" is that lando msyql 8 doesnt work OOTB with clients that dont currently/fully support mysql 8 which i think is expected. I'm even hesitant to add a setting to a particular recipe eg drupal8 knowing that is a "workaround". We should wait till things are mature. That said feel free to submit a PR with said documentation though, i feel like that is harmless as long as we remove it once this is fixed in the relevant upstreams. |
just want to report that i got this issue too with the laravel recipe
|
@thejacer87 same thing is happening here |
I got also this problem after having added solr service and after having rebuilt my app (Drupal9 / MySQL 8 / Solr 8) |
I'm experiencing this same problem. When I try to set my mysql version to match my production environment (Drupal 9 with mySQL 8.0), it just hangs on "Waiting until database service is ready..." until it eventually fails, says it failed its health check, then shows the If this is still the same issue, seems nearly 4 years is enough time to mature. |
I resolve that following Klonos' solution: |
Wow, the internet. I just started dealing with this today... @pirog I think I figured out the issue based on that link above:
https://dev.mysql.com/doc/refman/5.7/en/query-cache-configuration.html Do the recipes my.cnf have that config in them? |
UPDATE: No longer needed! see next comment.So to clarify the fix to get MySQL 8 working:
I looked up @geerlingguy's my.cnf to be sure. It's an ansible template, so he conditions it on the version.
https://github.com/geerlingguy/ansible-role-mysql/blob/master/templates/my.cnf.j2#L90-L94 So, @pirog... How do we handle this? Do the default database containers need these three settings? FWIW these are the defaults in the geerlingguy.mysql ansible role. I checked and they are also the default for MySQL itself.
And here are the defaults in lando drupal9 recipe:
Lando's cache size is 4.x bigger than a default Was this set larger for a reason? Does it improve performance? can we remove it from the all the existing recipies ? or would we need a whole new set for MySQL 8? For now, the custom my.cnf file works! Thanks @klonos |
Whoah! I accidentally discovered an easier fix due to a typo. I added a file to .lando.yml that does not exist. Lando created an empty directory at that path, but the database still started! So instead of all this, just do this:
Tada! 🚀 |
Interestingly enough, when I run with I believe this is because Lando tries to refer to a Submitted a couple PRs to address this:
|
…on ? From where should we get your app's codebase? (Use arrow keys) acquia ❯ current working directory github lagoon pantheon platformsh remote git repo or archive �[29D�[29C.
* lando/lando#1462: Add compatibility for MySQL 8.x. * release v0.8.0
* lando/lando#1462: MySql8 compatibility. * release v0.8.0
* lando/lando#1462: Add mysql8.cnf files to all Drupal recipes. * lando/lando#1462: Test MySQL 8 on the Drupal 10 recipe. * #1462: Separate out MySQL8 tests from drupal10 default test. * #1462: Improve mysql8 test to ensure db version and test Drupal 10 install. * lando/lando#1462: Refactor Drupal 10 MySQL 8 test with --option flag on ? From where should we get your app's codebase? (Use arrow keys) acquia ❯ current working directory github lagoon pantheon platformsh remote git repo or archive �[29D�[29C.
* lando/lando#1462: MySQL8 compatibility for Joomla recipe. * release v0.8.0
I'm trying to use Lando v3.0.0-rc.1 with the following configuration:
but when I start the environment the database doesn't get ready:
and the log shows:
Is there something I can do to solve this issue? I need to use MySQL 8 and I cannot downgrade to 5.x nor use another database.
The text was updated successfully, but these errors were encountered: