[DIFFERENT APPROACH WORKS] could not connect to the database mysql 5.0.45

Help with getting the CMS CORE package up and running. This does not include 3rd party modules, PHP scripts, anything downloaded via module manager or from any external source.
Locked
anderwelten

[DIFFERENT APPROACH WORKS] could not connect to the database mysql 5.0.45

Post by anderwelten »

Hi there,

I've tried hard to find a solution through the search, everything failed so far...

Mac OS X    10.4.11
Apache       1.3.33 (preinstalled)
MySql           5.0.45 (downloaded from their website.
PHP            4.4.7 (activated by decommenting the httpd.conf file of Apache)
CMSMS        1.2.2

All on the local machine.

The installation works until step 3 with this error message:
Could not connect to the database. Verify that username and password are correct, and that the user has access to the given database.

these are the credentials:

Database Type:         mysql
Database host address:       localhost
Database name :          cms
Username : cms_user
Password : cms_pass
Table prefix cms_

if I go to the OSX terminal, I can log on with mysql -u cms_user -pcms_pass;
on the mysql> command prompt,  I can enter
show databases;
and it will show

+--------------------+
| Database           |
+--------------------+
| information_schema |
| cms                |
| mysql              |
| test               |
+--------------------+

so I infer that I've successfully created a user names cms_user, who has access to the 'cms' database, right?

One thing I thought might be my problem is the issue with older php versions not being able to communicate with newer mysql databases according to
http://forum.cmsmadesimple.org/index.ph ... l#msg65618

But this didn't make any difference.

Any help much appreciated :-)
I know I'm a newbee, but that's simply because I've just discovered CMSMS...

Gratefully
anderwelten
Last edited by anderwelten on Wed Dec 12, 2007 11:09 am, edited 1 time in total.
anderwelten

used MAMP instead - working now

Post by anderwelten »

I didn't identify the problem, however I thought it would be a wise move to get the newest version of all the involved software (apache, mysql, php)
The easiest way on a mac to do this is to get www.mamp.info (Mac Apache MySql Php)

Before that I had to switch of the preinstalled Apache webserver  in
system preferences /sharing / personal web sharing

then get rid of automatic mysql start in
/Library/StartupItems

then delete the mysql folder:

Make sure the mysql server is not running. Start a terminal window. Type the following commands VERY CAREFULLY:
    cd /usr/local
    sudo rm mysql

Warning: this will also destroy any databases you created with MySQL

then install MAMP. (with me, the widget control didn't work. If the widget is dragged into the /Library/widgets folder and then you start up applications/Mamp/mamp, then there is a warning saying mamp PRO is running. once you remove the widget, the warnign disappears.)

Now I don't know the filepath to reach the mysql prompt in the terminal, which I would need to create the cms_user and cms database. Before trying to figure the filepath out, I thought I'd try to create these with phpMyAdmin, which comes preinstalled with MAMP. (can be launched from the MAMP start page)

so I created a user :  myphpadmin home - privileges - add a new user
ATTENTION: make sure you choose 'local' under Host. If not, you won't be able to connect to the database with 'localhost" in the CMSMS setup step 3.

And now I'm up and running!

anderwelten
Locked

Return to “[locked] Installation, Setup and Upgrade”