Title: Fresh install &#8211; database connection issue
Last modified: August 5, 2020

---

# Fresh install – database connection issue

 *  Resolved [cpietquin](https://wordpress.org/support/users/cpietquin/)
 * (@cpietquin)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/fresh-install-database-connection-issue/)
 * Hi,
 * I’ve installed and activated MailPoet3 WP Plugin on my WP Web site hosted at 
   AwardSpace ([https://www.awardspace.com/](https://www.awardspace.com/)). Here
   is my configuration:
    – PHP 7.4.8 – MySQL 5.5 – WordPress 5.4.2 – FR_fr language
 * Directly after plugin activation, an error notification banner has appeared on
   the top of WP Admin dashboards with the same message as mentioned in [https://kb.mailpoet.com/article/200-solving-database-connection-issues](https://kb.mailpoet.com/article/200-solving-database-connection-issues).
   Note the message appears as an error (in red) and not as a warning as described
   in the knowledge base (in orange)
 * Investigation made so far:
    1. I’ve checked my wp-config.php and verify DB_HOST
   value. It is set to the DB domain name which is different from localhost. I guess
   this mean the knowledge base topic solution isn’t going o fix the issue. 2. I’ve
   verified PDO and PDO_MySQL extensions are properly activated in my php.ini. It
   seems to be OK as I’ve found “extension=pdo.so” and “extension=pdo_mysql.so”.
   3. I’ve deactivated and uninstall the plugin and re-install and activate back.
   4. I’ve found this topic on the forum [https://wordpress.org/support/topic/plugin-is-unable-to-connect-to-the-database-not-localhost/](https://wordpress.org/support/topic/plugin-is-unable-to-connect-to-the-database-not-localhost/),
   thus I’ve checked the db encoding value and it’s properly set to “utf8”: define(‘
   DB_CHARSET’, ‘utf8’);
 * The error is still present and I’ve explored all the investigation paths I’ve
   thought about. I’v even searched for the plugin logs, thinking they could provide
   more precision about the issue root cause, but I didn’t find where they are stored
   on the file system.
 * Does anyone could help me solve this issue?
    Thanks in advance,
 * Christophe
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Ffresh-install-database-connection-issue%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [Wysija](https://wordpress.org/support/users/wysija/)
 * (@wysija)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/fresh-install-database-connection-issue/#post-13237215)
 * Hello,
 * Thanks for writing. ​Sorry about the problem you’re having with the installation.
   Can you try doing step one on the troubleshooting steps you linked? Change the‘
   DB_HOST’ to ‘127.0.0.1’.
 * The entry should look like this: define(‘DB_HOST’, ‘127.0.0.1’);
 * ​Thanks,
    …
 *  Thread Starter [cpietquin](https://wordpress.org/support/users/cpietquin/)
 * (@cpietquin)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/fresh-install-database-connection-issue/#post-13237319)
 * Hi,
 * Thanks for your answer, I’m going to check with my hosting provider, but I’m 
   pretty sure the the DB isn’t hosted locally on the same server as PHP. DB is 
   currently referenced by the DB domain name: define(‘DB_HOST’, [_DB Domain Name_]);
 * Doesn’t MailPoet 3 support referencing the DataBase using a domain name instead
   of an IP Address?
 * Regards,
 * Christophe
    -  This reply was modified 5 years, 11 months ago by [cpietquin](https://wordpress.org/support/users/cpietquin/).
 *  Thread Starter [cpietquin](https://wordpress.org/support/users/cpietquin/)
 * (@cpietquin)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/fresh-install-database-connection-issue/#post-13241258)
 * Hi,
 * As an update to my previous comment, I’ve had the confirmation of my hosting 
   provider: “The website is hosted on a shared-hosting space with a separate database
   server, so setting the DB_HOST to localhost or 127.0.0.1 will render the website
   unavailable.”
 * So, how can I make MailPoet3 working on that kind of infrastructure? Doesn’t 
   MailPoet 3 support referencing the DataBase using a domain name instead of an
   IP Address?
 * Thanks for your help,
 * Christophe
 *  Thread Starter [cpietquin](https://wordpress.org/support/users/cpietquin/)
 * (@cpietquin)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/fresh-install-database-connection-issue/#post-13280143)
 * Hi,
 * I’ve asked my provider to migrate my hosting to a newer infrastructure running
   MySQL 5.7 (instead of 5.5) and MailPoet has now been installed and activated 
   successfully.
    Not sure the MySQL version was the only issue or the root cause
   of my problem as migrating has implied other environment changes, but at least,
   it’s working now 🙂
 * I change the status of this topic to Resolved, perhaps it will help someone in
   the future.
 * Christophe
    -  This reply was modified 5 years, 10 months ago by [cpietquin](https://wordpress.org/support/users/cpietquin/).

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Fresh install – database connection issue’ is closed to new replies.

 * ![](https://ps.w.org/mailpoet/assets/icon-256x256.png?rev=3284564)
 * [MailPoet - Newsletters, Email Marketing, and Automation](https://wordpress.org/plugins/mailpoet/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/mailpoet/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/mailpoet/)
 * [Active Topics](https://wordpress.org/support/plugin/mailpoet/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/mailpoet/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/mailpoet/reviews/)

## Tags

 * [database connection](https://wordpress.org/support/topic-tag/database-connection/)

 * 4 replies
 * 2 participants
 * Last reply from: [cpietquin](https://wordpress.org/support/users/cpietquin/)
 * Last activity: [5 years, 10 months ago](https://wordpress.org/support/topic/fresh-install-database-connection-issue/#post-13280143)
 * Status: resolved