Installation Problems for 1.8.8 on xampp, Database installation DatabaseException:WrongCredentials

I am trying to install elgg using xampp server on my windows 7 laptop and i was having problems with step 1.  but after replies by some helpful members i was able to go as far as step 3, database installation. The error messag i get is

  • DatabaseException:WrongCredentials

There was an error creating the Elgg database and installation cannot continue. Review the message above and correct any problems. If you need more help, visit the Install troubleshooting link below or post to the Elgg community forums

 I read some of the suggestions on this website and i changed my settings.php values accordingly. since im on xampp server, here is how i changed it

$CONFIG->dbuser = 'root';
$CONFIG->dbpass = '';
$CONFIG->dbname = 'elggdb';
$CONFIG->dbhost = 'localhost';
$CONFIG->dbprefix = 'elgg_';

I even tried adding a password for the server and specifying that password here. The settings.php file wasn't created automatically, so i copied and pasted the settings.examples.php file and renamed it to settings.php. I created the database via phpmyadmin, i've created and tested with around 3 databases. Everything stops at step 3. So what can i do?

  • the settings.php should be created automatically.  The error you're getting now is because elgg detects a settings.hp and assumes the database is set up, when in fact the database isn't set up.

    You need to create an empty database first in phpmyadmin, then make sure your credentials are right in the setup form:

    username: 'root'


    database name: Must match what you created exactly

  • Maybe this is not related to your particular situation, however, the last release of Xampp was not compatible with another CMS i am using (or the other way round), disinstalling this last version and going back to the version 1.7.4, fixed my problem.

  • Thanks for the reply but its still not working.
    I tried Matt's suggestion, the settings.php doesn't get created automatically.
    Tried changing Xampp versions, Nothing.
    If anyone has any ideas, please tell me.


  • The settings.php file might not getting created automatically, if the engine folder is not writable (temporarily necessary during installation to allow for settings.php getting created). But it's okay for the settings.php file to be created by copying it from settings.example.php.

    What username / password do you create the database with? The credentials must match. If unsure what username / password are used by default, you can create a database user especially for the Elgg database. In case you create the database via command line you can use these commands:

    use mysql;

    create database elggdb;

    GRANT ALL PRIVILEGES ON elggdb.* to elggdb_account@localhost IDENTIFIED BY 'password';

    flush privileges;

  • Thanks for the fast reply
    I created the database using phpadmin. i created a database named elgg, also tried with a bunch of otther database names. I checked the privilages, it has a 'root' username with no password. I usually use that for all my databases.
    I tried by renaming the settings.php file to settings.examples.php hoping that it will be created automatically, that didn't work.

  • Database name "elgg" or "elggdb"? If it's called "elgg" then the credentials do not match with the entries in settings.php.

    If settings.php already exists, it will not be re-created during the installation and the credentials will not be asked for. If settings.php does not exist yet, it will be created during installation (from settings.example.php). Automatic creation will only work if the webserver can create / write the file.

    I don't know if it might be a problem when not using a password. Elgg could have a problem with that. If it does not work, try with using a password. I would also advice to not use the mysql root user as owner of the database. It's more secure to use a separate mysql account for every database.