Error establishing a database connection WordPress Local Install
Posted by: BrandAgent (204.19.162.---)
Date: March 08, 2012 04:30PM

ERROR TRYING TO INSTALL WORDPRESS LOCALLY WITH WAMPSERVER!

Trying to use WampSever to run WordPress locally but getting an error. WampServer icon is green. I open Localhost, click on my project, and get this message:

"Error establishing a database connection"

RUNNING:
Windows Vista Ultimate Version 6.0 (Build 6002: Service Pack 2)
WampServer Version 2.2
WordPress 3.3.1

STEPS LEADING UP TO ERROR:
1. created a new database in phpMyAdmin
2. created a new user with user name and password
3. gave new user all privelages
4. created a new project forlder in the www directory
5. copied the contents of my WordPress download to the new folder
6. customized the wp-config.php file (database name, user name, password, pasted in new authentication keys and salts)
7. attempted to instal WordPress (entered "[localhost]; in browser (got error); opened Localhost from WampServer, clicked on "brandagents" under "My Projects" and got error)

Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: stevenmartin99 (Moderator)
Date: March 08, 2012 04:34PM

i dont think you should have touched the wp-config file

you cant run the installer after you have edited the file.

thats the whole purpose of the installer- it edits that file for you

start again smiling smiley

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: BrandAgent (204.19.162.---)
Date: March 08, 2012 05:02PM

GOT THE SAME ERROR

Thanks for your response. I started over and ran the installer through the WordPress interface as you suggested and got the following error:



Error establishing a database connection

This either means that the username and password information in your wp-config.php file is incorrect or we can't contact the database server at localhost. This could mean your host's database server is down.

Are you sure you have the correct username and password?
Are you sure that you have typed the correct hostname?
Are you sure that the database server is running?
If you're unsure what these terms mean you should probably contact your host. If you still need help you can always visit the WordPress Support Forums.

Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: stevenmartin99 (Moderator)
Date: March 08, 2012 05:17PM

is this a fresh copy of wordpress from the site? and is mysql running?

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: BrandAgent (204.19.162.---)
Date: March 08, 2012 05:51PM

It's a fresh copy of WP. How can I tell if MySql is running?

Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: stevenmartin99 (Moderator)
Date: March 08, 2012 06:14PM

the wamp icon would be green... but you said phpmyadmin is accessible

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: BrandAgent (204.19.162.---)
Date: March 08, 2012 06:39PM

Thank you. Yes the Wamp icon is green and the phpMyAdmin is accessable

Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: yfastud (Moderator)
Date: March 09, 2012 01:35AM


Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: BrandAgent (204.19.162.---)
Date: March 09, 2012 07:03PM

I did that already. I did it again. It didn't work. Thanks anyway.

Options: ReplyQuote
Re: Error establishing a database connection WordPress Local Install
Posted by: elitefox (106.51.132.---)
Date: June 20, 2013 11:09AM

Provide User Information in privillage option
Refer here
How To Install WordPress using Wamp Server Without Error Establishing a Database Connection
[elitefox.org]

Options: ReplyQuote


Sorry, only registered users may post in this forum.