I am trying to install a craft playground using vagrant and puppet. After firing the default installation for a LAMP stack and creating related DB and User, granting privileges, ... I want to start the craft installation, all I get is:

Craft can’t connect to the database with the credentials in craft/config/db.php.

The commands I am using to create the DB:

CREATE DATABASE craftdb CHARACTER SET utf8 COLLATE utf8_general_ci;
CREATE USER craftadmin@localhost IDENTIFIED BY 'ThisPassword';
GRANT ALL PRIVILEGES ON craftdb.* TO craftadmin@localhost;

The dp.php looks like this:

// The database server name or IP address. Usually this is 'localhost' or ''.
'server' => 'localhost',

// The database username to connect with.
'user' => 'craftadmin',

// The database password to connect with.
'password' => 'ThisPassword',

// The name of the database to select.
'database' => 'craftdb',

// The prefix to use when naming tables. This can be no more than 5 characters.
'tablePrefix' => '',

PHP Packages installed:


Any suggestions are much appreciated

  • 1
    Not really an answer, but lots of Craft + Vagrant tips and tricks here: plus.google.com/communities/106505340287442511226/s/vagrant and a whole Craft + Vagrant video here: plus.google.com/events/…
    – Brad Bell
    Commented Aug 26, 2014 at 19:26
  • thx for the hint, the video I know, the first link shows me some topics that are of help for further dev, but I doubt that this is a permission issue (assuming I would get another error then), however, I will check on permissions. Thanks for the hint. one more thing brad: can you confirm that I got all required php modules? I am not really confident about them...
    – frank
    Commented Aug 26, 2014 at 20:34
  • Ben Crocker has a nice stand-alone requirement checker you can run outside of Craft: github.com/putyourlightson/craft-requirements
    – Brad Bell
    Commented Aug 26, 2014 at 20:51

1 Answer 1


Solution found:

I copied again all files to the root folder, changed the very same settings and got it to work - for whatever reason it seems that with the first attempt some files where missing.

@Brad: Thanks for taking the time - the shared infos are of help anyway.

  • No problem... glad you got it sorted.
    – Brad Bell
    Commented Aug 26, 2014 at 22:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.