CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Drupal Installations (Moderator: Piotr Szotkowski) »
  • Getting database error when performing new installation
Pages: [1]

Author Topic: Getting database error when performing new installation  (Read 1880 times)

suegeuens

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
  • CiviCRM version: 4.2.7
  • CMS version: Drupal
  • MySQL version: 5.5.25
  • PHP version: 3.5.1
Getting database error when performing new installation
January 16, 2013, 11:15:15 am
I am positive this question has been asked and answered, but I've been trying to find the answer for two days now and I've had it:

Have installed MAMP (because I am using a MBP 13" Retina Display), Drupal 7 and need to install CiviCRM. The MAMP install went great, got my user name and password set up and can go into phpmyadmin and create users as well as databases. Logged in with the password I created.

Drupal installation went well enough so that I now have a site I can test on AND LEARN what I am doing.

I played around a little bit with the various modules, downloaded a few themes, etc and started to get the hang of Drupal (VERY VERY BASICALLY).

Then I realised I needed CiviCRM to be installed as well - and this is where it has gone pear-shaped.

As any good newbie, I searched the net for a decent installation process and have followed it to the T - until the bit where the damned database access needs to be done. I used my standard ones as created and with which I logged into MySql and PHP. No luck and all the errors came up. Through a bit of trial and error I finally have a working username - for "access". BUT .. this is where it stops. For some reason I get the following errors:

I can't create new databases and the database 'drupal' doesn't exist (user 'drupal' doesn't have CREATE DATABASE permissions.) Followed by Could not select the database - this is for the CiviCRM DB.

The error for the Drupal DB is: The database: 'drupal' does not exist.

Through the MAMP phpmyadmin I can not only access the DB (drupal) as well as the one I created (Civi1) but I can check that the user permissions are about as good as they can be. I have tried the root user in the thought that perhaps this is where the problem is. I also checked the settings.php file (as explained in a post somewhere on the net) and made sure that my settings were the ones I am using.

Still no luck and it's been two days of this. I do not know where else to turn and I would love to have someone assist me. Please note that I am a rank beginner in this - including hardly knowing ANY unix/linux - so I need to have this explained in words of one syllable.

To my mind this should be simple. I just can't think of anything else I can do - and trying to wade through the 1000's of posts and sites dedicated to this has given me a massive headache.

Is there anyone willing to take pity on me and put me out of my misery??? Pretty please????

Jason W

  • I post frequently
  • ***
  • Posts: 197
  • Karma: 12
  • jason@civitrainingtutorials.com
  • CiviCRM version: 4.2
  • CMS version: Drupal 7
  • MySQL version: 5.x
  • PHP version: 5.x.x
Re: Getting database error when performing new installation
January 16, 2013, 01:43:18 pm
Hello suegeuens,

I'm going to include a snippet of a walkthrough that my company uses, but I wonder if you are trying to include a password when you fill out the information on the installer page. that hung me up for the longest time.

4. Install CiviCRMa:  - Step 1
   a. Go to http://civicrm.org/
   b. On the download page scroll down until you see a link that reads "Download CiviCRM from SourceForge", Click on this link.
   c. download the latest version of CiviCRM. Get Drupal.tar.gz filetype.
   d. Extract the gz filetype
   e. Extract the CiviCRm v.x.xx.Drupal .tarfile to the Drupal/sites/All/Modules folder on your website.
   f. Rename this folder to CiviCRM (i.e. delete any version numbers and Drupal from the CiviCRM module folder name)
   g. Bring up your browser and navigate to www.yourwebdomain.com/ Drupal/sites/all/modules/CiviCRM/install/index.php
5. Install CiviCRM – Step 2
   a. When you are  in the /CiviCRM/install/index.php  location, (you will get red bar error messages don't worry the following steps will correct those)
   b. Now on this Installer page you need to fill out the information based off the information that we used to create the database earlier.
      MySQL server:
      MySQL username: root
      MySQL password: empty unless you set one up earlier.
      MySQL database: yourCiviCRMdatabaseName
         Drupal Database
      MySQL server:
      MySQL username: root
      MySQL password: empty unless you created one
      MySQL database: yourCiviCRMwebsiteName
      Make sure you set the language and check the "load sample data" box (if desired)
   c. Click the Check Requirement box. Now everything should be green and at the top of the page you should get a "Ready to Install" box.
   d. Now there will be a "Check Requirements and Install CiviCRM" button. Click it.
   e. If everything installed with out any issues you will receive a "CiviCRM has been successfully installed" page. You can now edit information and view the links on the page.
6. Accessing CiviCRM
There are two ways to access your CiviCRM website:
   a. Go to Drupal and select yourCiviCRMwebsite
   b. Navigate directly to yourCiviCRMwebsite in the address bar of your browser.

Hope this helps, please let me know.

Cheers,
Jason
civiTrainingTutorials
"Helping You Help Others"

suegeuens

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
  • CiviCRM version: 4.2.7
  • CMS version: Drupal
  • MySQL version: 5.5.25
  • PHP version: 3.5.1
Re: Getting database error when performing new installation
January 16, 2013, 10:45:27 pm
Hi Jason

I have been following the exact process steps you have sent me (also got it off the net and it made a lot of sense). I am stuck at step c. I keep getting the errors which tell me that the user does not have access to create databases and that the database does not exist! Both the drupal db and the one I created for CiviCRM are in MySql and all the users I've tried have FULL and Admin access to the to DB's - as well as being able to create a new DB via the phpmyadmin screen. I've tried all variations of the users that I created as well as the root user. But to no effect. I am stuck! I have also uninstalled EVERYTHING 3 times already and started from the beginning to see if perhaps my installation at some stage didn't work - but everything to this step has worked fine!

The frustration is driving me mad!!! I don't know what else I can try - and I am not a person who has any knowledge of unix/ linux so using the terminal is a joke ....

Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
Re: Getting database error when performing new installation
January 17, 2013, 03:20:32 am
There can sometimes be an issue of mysql vs mysqli. I haven't seen this problem in a while, but sometimes it can prevent the installer from working, i.e. if you have only mysqli installed and not mysql. These are PHP connectors to MySQL and they're different.

Can you check that?

Beyond that, it's hard to say--it sounds like you're making a little mistake like a type or the wrong server or some such.
CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

suegeuens

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
  • CiviCRM version: 4.2.7
  • CMS version: Drupal
  • MySQL version: 5.5.25
  • PHP version: 3.5.1
Re: Getting database error when performing new installation
January 17, 2013, 05:12:50 am
Hi Hershel

Can you please treat me as a know-nothing dummy at this stage - not being unkind to myself, just know I really do know nothing. I am not sure how to check whether I have mysqli or mysql? Is there a step by step test?

I've checked the settings that I am putting in for the database connection and I am pretty sure they are all correct.  I am happy to try anything as long as I get this working - so will re-check that the settings I am using are in fact 100% correct.

I took a screenshot of my MAMP settings which shows the php extension as mysql - is this what you are referring to or is there another place I need to check?

Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
Re: Getting database error when performing new installation
January 17, 2013, 06:13:27 am
If you have Drupal installed and working, go to Admin -- Reports -- Status Report and then the PHP version should be clickable. Click on that to see phpinfo() output and search that page.
CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

suegeuens

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
  • CiviCRM version: 4.2.7
  • CMS version: Drupal
  • MySQL version: 5.5.25
  • PHP version: 3.5.1
Re: Getting database error when performing new installation
January 17, 2013, 09:33:44 pm
Checked and nowhere does it say Mysqli .....

Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
Re: Getting database error when performing new installation
January 17, 2013, 11:05:32 pm
So then that is not the problem. Unfortunately I am not able to guess what else might be the problem. :(
CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

suegeuens

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
  • CiviCRM version: 4.2.7
  • CMS version: Drupal
  • MySQL version: 5.5.25
  • PHP version: 3.5.1
Re: Getting database error when performing new installation
January 18, 2013, 12:37:39 am
Hi Hershel

Thanks for all your help and support. I finally found the issue and have resolved it. Have to say it took going back to the installation of MAMP to get it right ... nowhere in the installation docs I went through did it mention I needed to change the ports  :( :( :( -. Reinstalling MAMP, changing the settings, then reinstalling Drupal and finally CiviCRM has sorted out my problem.

This is a rank beginner mistake, so I will not make it again!!! ;D

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Getting database error when performing new installation
January 18, 2013, 08:30:37 am

so u had to enable mysqli in the MAMP install?

most (none?) of us use MAMP and so we have no idea what the config options are for various packages out there

would be great if you can edit the relevant wiki documentation and let folks know they need to do that

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Drupal Installations (Moderator: Piotr Szotkowski) »
  • Getting database error when performing new installation

This forum was archived on 2017-11-26.