Error at creating MySQL

Thank you for your follow-up.
Just tell me which config.json I should select.

Yes, I modified …/Library/Application Support/DevKinsta/config.json the way you suggested, but the behavior is still the same, as you can see in the main.log file.
[main.log redacted)

@jazzyguy Thank you for the update! However, I have noticed that the main.log still shows database user permission errors.

`

[2024-02-13 14:37:04.714] [error] watchDocker - Error: connect ENOENT /var/run/docker.sock
[2024-02-13 14:38:32.875] [error] [ipcMainStep] Error in operation SITE_CREATION, step database: Error: Error (1): UERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
[2024-02-13 14:38:49.566] [error] Error - DK0051: DELETE_SITE_DATABASE: Error (1): UERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
[2024-02-13 14:40:56.238] [error] Error - DK0081: WP_PARSE_CONFIG: wp-config.php not found
[2024-02-13 14:40:56.241] [error] [validateBackupArchive] validating backup archive failed. Error - DK0081: WP_PARSE_CONFIG: wp-config.php not found
[2024-02-13 14:40:56.245] [error] [ipcMainStep] Error in operation SITE_CREATION, step validate: Error - DK0081: WP_PARSE_CONFIG: wp-config.php not found
[2024-02-13 14:41:13.268] [error] Error - DK0051: DELETE_SITE_DATABASE: Error (1): UERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
[2024-02-13 22:49:56.746] [error] watchDocker - Error: connect ENOENT /var/run/docker.sock
[2024-02-13 22:52:42.109] [error] [ipcMainStep] Error in operation SITE_CREATION, step database: Error: Error (1): UERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
[2024-02-13 22:53:00.294] [error] Error - DK0051: DELETE_SITE_DATABASE: Error (1): UERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
[2024-02-13 22:55:49.096] [error] Error - DK0081: WP_PARSE_CONFIG: wp-config.php not found
[2024-02-13 22:55:49.101] [error] [validateBackupArchive] validating backup archive failed. Error - DK0081: WP_PARSE_CONFIG: wp-config.php not found
[2024-02-13 22:55:49.105] [error] [ipcMainStep] Error in operation SITE_CREATION, step validate: Error - DK0081: WP_PARSE_CONFIG: wp-config.php not found
[2024-02-13 22:56:14.048] [error] Error - DK0051: DELETE_SITE_DATABASE: Error (1): UERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)`

Just to confirm, and make sure we are up to date with this issue, you are trying to import a WordPress backup from MAMP to Devkinsta, but you are continuously encountering the same exact error while doing so, the same error when attempting to create a new WordPress site within Devkinsta. Is that correct?

If possible, please share an updated screenshot showing the error in DevKinsta while performing such actions.

I will contact our developers to get their recommendations again on how we can proceed with troubleshooting the issue. I will keep you updated on any progress we make.

Thank you for your reply.

Yes, I confirm your understanding of the error I am facing.

Here is a screenshot of my last trial, with the associated main.log :

[main.log redacted)

Thank you. Our team dig more through the main.log, it looks like the database (MariaDB) password is successfully reset on each startup. Possible that when trying to authenticate, it still tries with some old password. To continue troubleshooting, you could try to manually login to MariaDB using Docker. To do this:

  1. Open Docker Desktop while DevKinsta is running

  2. Select devkinsta_db container and attach a shell to it (see picture below)

  3. In the shell, log in with mysql: mysql -u root -p<HERE_THE_PASSWORD_FROM_DK_UI> - make sure there is not space after the -p

  4. If successful, the user should see something like the below screenshot.

  5. If successful, run some command like SHOW DATABASES; which should provide a similar output as shown in this screenshot.

If this is unsuccessful however, that means the password on DevKinsta UI is never the one that can be used to login to the MySQL server. In such a case, what we can do is stop DK and all the containers, and try to reset the password manually. This, however, requires a quite advanced user comfortable with CLI and stuff. At this point, it is just easier to to back up your site/s and remove the containers, volumes and files and start from scratch.

To try to reset the password manually:

  • Stop the MariaDB container.

  • Start a new mariadb container on the same volume, without privileges (something like docker run --name devkinsta_reset_mariadb_root -v devkinsta_db_data:/var/lib/mysql/ -d mariadb:10.5.5 mysqld --skip-grant-tables ).

  • This is basically identical to DevKinsta’s MariaDB container, with the exception that it does not require login. So even if it prompts for user/password, any random value will work.

  • Alter the root user:

USE mysql;
FLUSH PRIVILEGES;
ALTER USER 'root'@'localhost' IDENTIFIED BY 'ENTER_THE_NEW_PASS_HERE';
FLUSH PRIVILEGES;
  • Remove the temp container:

docker rm devkinsta_reset_mariadb_root -f

  • Start the real DK MariaDB container.

I hope it helps!

Hello,

I finally could achieve the setting-up of my local website with DevKinsta after the installation of an empty site, then :slight_smile:

  • updating URLs and importing the database tables,
  • updating wp-config.php with the appropriate hosting, URLs and MySQL parameters,
  • copying the WordPress files in the site folder.

I thank you for your reactive help,

@jazzyguy Awesome, glad to hear it! :grinning: If you do have any other questions, or run into any more issues, please let us know and we’ll be happy to take another look with you.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.