Skip to content
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

Error establishing a database connection #170

Open
janoist1 opened this issue Feb 21, 2020 · 6 comments
Open

Error establishing a database connection #170

janoist1 opened this issue Feb 21, 2020 · 6 comments

Comments

@janoist1
Copy link

janoist1 commented Feb 21, 2020

I'm getting Error establishing a database connection when installing WP.

The following prints "Connected" when putting intowp-config.php:

$mysqli_connection = mysqli_connect(
  $_dbsettings['host'],
  $_dbsettings['user'],
  $_dbsettings['pass'],
  trim( $_dbsettings['path'], '/' ),
  $_dbsettings['port']
);

if ($mysqli_connection->connect_error) {
   echo "Not connected, error: " . $mysqli_connection->connect_error;
}
else {
   echo "Connected.";
}

What's going on?

@nickmerwin
Copy link

This is due to the RDS certificate change.

From jawsdb.com:
image

You'll need to swap out this file in your repo support/mysql-certs/rds-combined-ca-bundle.pem with this new one from AWS:

https://s3.amazonaws.com/rds-downloads/rds-combined-ca-bundle.pem

and redeploy.

@nickmerwin
Copy link

Pull Request opened: #171

@janoist1
Copy link
Author

👍👍👍👍👍👍👍👍👍👍👍👍👍👍👍

@DSaxon
Copy link

DSaxon commented Mar 18, 2020

thanks a million I overlooked the update

@DSaxon
Copy link

DSaxon commented Mar 18, 2020

there are a few pulls that i think is pending. Is anyone on this thread able to help keep the repo updated?

@lilpkstud
Copy link

Switch WP_DB_SSL to OFF from Heroku's Settings Tab -> Config Vars

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants