Zen Cart Logo
Forums / Installing on a Linux/Unix Server / Getting a "Connection to Database Failed" message

Getting a "Connection to Database Failed" message

Locked

Views: 1,984

Results 1 to 5 of 5
This thread is locked. New replies are disabled.
3 Nov 2008, 2:37 AM
#1
inuashley avatar

inuashley

New Zenner

Join Date:
Nov 2008
Posts:
2
Plugin Contributions:
0

Getting a "Connection to Database Failed" message

Hi, I've followed these instructions up to #12, but after I pass the pre-requisites for the install and try to connect to the mySQL database I set up, I get a "Connection to Database Failed. Access denied for user "(my username here)" @ localhost(or my ip address, if I put that in there instead) using password: yes" message.

I'm sure that the user name, password, and database name that I'm putting in are correct, but I think that I may be putting in the wrong database host name. Any help would be very much appreciated. :smile:

  1. Download the software from the mamp.info website
  2. Agree to install terms
  3. Drag the MAMP folder to the Applications folder (a usual Mac procedure)
  4. In the Applications/MAMP folder, double-click on the MAMP.app file
  5. Accept license, and choose just to use MAMP, and not MAMP PRO.
  6. Click on Start Servers in the MAMP application control window.
  7. Decided that I wanted to change the preferences so that Apache runs on port 80 (so I don't have to say localhost:8888 everything I want to look at my local server), so I clicked on Preferences, then on Apache, then on Use Apache and MySQL defaults, and saved the changes. It asked for my MAC user password in order to allow the system port change to be completed.
  8. Clicked on Open Start Page, and it shows me all my appropriate settings such as my MySQL username and password so I can put them into my Zen Cart when I set it up.
  9. Clicked on the phpMyAdmin tab, and created a new database named zencart138.
  10. Use finder to create an /Applications/MAMP/htdocs/zencart folder (change "zencart" to whatever you prefer)
  11. Unzip a copy of Zen Cart files into that folder.
  12. Open the browser and point it to: http://localhost/zencart ... and Zen Cart fires up in Install mode.
  13. Fill in all the fields as appropriate, and complete installation.
  14. Access my store as usual via http://localhost/zencart and admin as http://localhost/zencart/admin
3 Nov 2008, 3:20 AM
#2
bobdog avatar

bobdog

Totally Zenned

Join Date:
Mar 2006
Location:
Fresno, California
Posts:
590
Plugin Contributions:
0

Re: Getting a "Connection to Database Failed" message

Did you create a user and password in phpmyadmin and apply it to the database?

3 Nov 2008, 3:38 AM
#3
inuashley avatar

inuashley

New Zenner

Join Date:
Nov 2008
Posts:
2
Plugin Contributions:
0

Re: Getting a "Connection to Database Failed" message

bobdog:

Did you create a user and password in phpmyadmin and apply it to the database?

I'm not sure if I did, but I did create a database with the same name as the mySQL database. I just now went to the start page in MAMP and I saw that it said to put in "root" for both the database username and password, and it seemed to work, although I'm not sure why.

10 Nov 2008, 7:59 PM
#4
brokeneyeball avatar

brokeneyeball

New Zenner

Join Date:
Nov 2008
Posts:
2
Plugin Contributions:
0

Re: Getting a "Connection to Database Failed" message

I'm getting this same error. I seem to be typing in all the correct names and passwords, I'm getting my information from "MySQL Database Information"
Maybe godaddy doesn't allow zencart to access... something? I dont know?

Please help me if you know about this. thanks.

17 Nov 2008, 12:34 AM
#5
brokeneyeball avatar

brokeneyeball

New Zenner

Join Date:
Nov 2008
Posts:
2
Plugin Contributions:
0

Re: Getting a "Connection to Database Failed" message

i tried it again today, a week later, and it installed just fine.
so maybe you just have to wait a while for it to do its stuff and be ready.
now i just have to figure out..how to make it actually be a shop!