WordPress.org

Ready to get started?Download WordPress

Forums

config file not recognizing the MySQL db (17 posts)

  1. pikmin
    Member
    Posted 9 years ago #


  2. moshu
    Member
    Posted 9 years ago #

    I am afraid this is not enough info to be able to help.

  3. pikmin
    Member
    Posted 9 years ago #

    Here is what i get on my page

    Error establishing a database connection

    This either means that the username and password information in your wp-config.php file is incorrect or we can't contact the database server at localhost. This could mean your host's database server is down.

    * Are you sure you have the correct username and password?
    * Are you sure that you have typed the correct hostname?
    * Are you sure that the database server is running?

    If you're unsure what these terms mean you should probably contact your host. If you still need help you can always visit the WordPress Support Forums.

    here is my config file

    <?php
    // ** MySQL settings ** //
    define('DB_NAME', 'db_name'); // The name of the database
    define('DB_USER', '*******'); // Your MySQL username
    define('DB_PASSWORD', '******'); // ...and password
    define('DB_HOST', 'localhost'); // 99% chance you won't need to change this value

    // Change the prefix if you want to have multiple blogs in a single database.
    $table_prefix = 'wp_'; // example: 'wp_' or 'b2' or 'mylogin_'

    // Change this to localize WordPress. A corresponding MO file for the
    // chosen language must be installed to wp-includes/languages.
    // For example, install de.mo to wp-includes/languages and set WPLANG to 'de'
    // to enable German language support.
    define ('WPLANG', '');

    /* Stop editing */

    define('ABSPATH', dirname(__FILE__).'/');
    require_once(ABSPATH.'wp-settings.php');
    ?>

    and my password and username are fine i use them to get into mysql and i also just set up that dbname so it should be fine i even rebooted the server and restarted that db

  4. moshu
    Member
    Posted 9 years ago #

    Is this a local install? Is PHP able to "talk" with the db?

  5. pikmin
    Member
    Posted 9 years ago #

    it should they are both running on that machine i am using fedora core 3 with php and apache and mysql enabled all are running the site url that wordpress is http://www.cloudchaos.com/wordpress/

  6. moshu
    Member
    Posted 9 years ago #

    Does the user has all the privileges for that new db?

  7. jetshack
    Member
    Posted 9 years ago #

    don't know if this is relavent, but I think the most recent fantastico release is installing wp correctly... i ran a fantastico install script for wp this morning and came up with the same error

    did the manual install and all was good.

  8. pikmin
    Member
    Posted 9 years ago #

    i even tried using root to configure it all so everything could talk to each other but to no avail still same message

  9. Are you running MySQL v4.1.7?

  10. pikmin
    Member
    Posted 9 years ago #

    not sure I am using fedora core 3 with whatever it came with

  11. You might want to look into that. There is a bug with v4.1.7 that prevents most PHP scripts from logging into the database. The solution is to upgrade to v4.1.8 or higher.

  12. pikmin
    Member
    Posted 9 years ago #

    i have to remember how to check versions since i have not used linux in a few years i have to get used to things again

  13. mouah
    Member
    Posted 9 years ago #

    I have the same problem, with MySQL 4.1.7
    So I install 4.1.12 but it remains the same :

    "Error establishing a database connection"

    :(

  14. pikmin
    Member
    Posted 9 years ago #

    I am still having the same problem and even phpMyAdmin is coming up with a blank page instead of the admin page

  15. I am still having the same problem and even phpMyAdmin is coming up with a blank page

    Pikmin, if phpmyadmin is also coming up with a blank page, then this is a server issue, not a WordPress issue.

    I have the same problem, with MySQL 4.1.7. So I install 4.1.12 but it remains the same : "Error establishing a database connection"

    Mouah, either your information in wp-config.php is wrong, or you are experiencing a MySQL issue on your server.

  16. roterhund
    Member
    Posted 9 years ago #

    I just experienced the same inexplicable problem - until I deleted the space that I had unintentionally copied along with the username … I'm not saying that you're as stupid as I am, but maybe you should double-check anyway. Good luck!

  17. pikmin
    Member
    Posted 9 years ago #

    That was one of the first things i checked for cause that is a common oversight and that still wasn't the problem

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags