Cannot Access phpMyAdmin
Posted by: atx7953 (4.59.116.---)
Date: February 24, 2012 05:50PM

Problem:
localhost displays: Error establishing a database connection
phpMyAdmin displays: #1045 - Access denied for user 'root'@'localhost' (using password: NO)

SetUp:
WAMP is functioning properly (Green). I have set a password in the MySQL console.

Steps Taken to Resolve:
In config.inc.php I've tried to add the MySQL pw to this line
$cfg['Servers'][$i]['password'] = 'password here';

I've also tried it without a password with nothing between the single quotes.

Also tried setting the line below to 'false':
$cfg['Servers'][$i]['AllowNoPassword'] = true;

Any help is appreciated. I have searched other posts to get this far.

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: TomWilliams (---.om.om.cox.net)
Date: February 29, 2012 12:57AM

Re:
atx7953

Problem:
localhost displays: Error establishing a database connection
phpMyAdmin displays: #1045 - Access denied for user 'root'@'localhost' (using password: NO)

SetUp:
WAMP is functioning properly (Green). I have set a password in the MySQL console.

Steps Taken to Resolve:
In config.inc.php I've tried to add the MySQL pw to this line
$cfg['Servers'][$i]['password'] = 'password here';

I've also tried it without a password with nothing between the single quotes.

Also tried setting the line below to 'false':
$cfg['Servers'][$i]['AllowNoPassword'] = true;

I am experiencing the same thing and have spent the last three hours reaserching and trying the same remedies as you as well as others all without success. One guy's advice said to go to control panel, administrative tools, Services, MySQL and turn it off then try to launch phpMyadmin. One guy claimed it solved his problem. Another post sugested using CTRL+F5 to force the command to the server after changing the config.inc.

Neither worked for me however. After I installed WAMP I was in phpMyadmin and read the error message at the bottom of the page about the root not having a password. I went to the privelidges tab where I found three roots. I added a password to only one of them. Perhaps that is the cause of the problem I'm experiencing. I have completely uninstalled and reinstalled the program three time now. I believe the program is reinserting the password that I submitted after the first installation.

Any assistance would be greatly appreciated.

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: RiggsFolly (---.as13285.net)
Date: February 29, 2012 01:21AM

Out of the box this part normally works fine.

If you are trying to add a password what did you actually change, I assume you got in with phpMyAdmin to set a password.

Did you change the root password? Or did you create a new user with a password.

It has to be related to something you did so post a list or have a think about what you did.

Options: ReplyQuote
phpmyadmin error
Posted by: vjbakshi21 (1.23.148.---)
Date: March 11, 2012 03:32PM

Error

MySQL said: Documentation
#2002 - The server is not responding (or the local MySQL server's socket is not correctly configured)
Open new phpMyAdmin window

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: xymalf (---.as13285.net)
Date: March 13, 2012 07:52PM

The mysqli extension is missing.

i get above message when trying to access php myadmin


what do i need to edit or download?

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: RiggsFolly (---.as13285.net)
Date: March 16, 2012 05:04PM

xzmalf

left click wamp manager

then hover over PHP -> Php Extension and click php_mysqli

give wamp a couple of seconds to restar apache and it should be usable.

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: thanoojpk (117.231.103.---)
Date: March 23, 2012 11:52AM

this is the error i am getting wenever i click on phpMyadmin...help me ....please..


Error
MySQL said:

#1045 - Access denied for user 'root'@'localhost' (using password: YES)

phpMyAdmin tried to connect to the MySQL server, and the server rejected the connection. You should check the host, username and password in your configuration and make sure that they correspond to the information given by the administrator of the MySQL server.

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: GraceBT (---.war.clearwire-wmx.net)
Date: August 02, 2012 01:16PM

wamp phpMyAdmin:

MySQL said: Documentation #1045 - Access denied for user 'root'@'localhost' (using password: NO) .

I do have a MySQL password that I need to enter when I go to MySQL. How do I set this properly. I
am looking at the config.inc.php file and I see a line:

$cfg['MySecretPassword"] = 'a8b7c6d'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */
(password changed to protect the inocent).

When I use WAP to start the MySQL console it prompts for password and I enter "MySecretPassword"winking smiley
and it works fine.

What do I need to do now to make phpMyAdminn happy?

Thanks in advance for any help that You may be able to offer!

73
-Grace
NNNN
z

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: RiggsFolly (---.as13285.net)
Date: August 02, 2012 01:59PM

Grace

Ok so you have told MySQL to use a password for the 'root' userid, now you need to tell the phpMyAdmin app that it should use a password and optionally what that password is.


The file to edit is C:\wamp\apps\phpmyadmin3.x.y\config.inc.php

My preference is to tell phpMyAdmin to ask me for the Userid/Password to use to login to mysql.

To do that change your config.inc.php to look like this

$cfg['Servers'][$i]['verbose'] = 'localhost';
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['port'] = '';
$cfg['Servers'][$i]['socket'] = '';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['auth_type'] = 'http';
$cfg['Servers'][$i]['user'] = '';
$cfg['Servers'][$i]['password'] = '';
$cfg['Servers'][$i]['AllowNoPassword'] = false;
$cfg['Servers'][$i]['LogoutURL'] = 'http://localhost/';


the important bits are
'auth_type' = 'http'
'AllowNoPassword' = false

and leaving the user and password fields blank

As an extra benefit I can show you my exact file and you dont know my userid or password so anybody looking on your wamp server pc wont either.

So lets assume you added a password to 'root'@'localhost'
This is the userid that will be checked as you are running on the localhost machine.

( remember mysql users are associated with a location as well. So root can only login from localhost or ::1(ipv6 localhost) or 127.0.0.1(ipv4 localhost), as these are the ones setup on MySQL out of the WAMP box.
So if you are trying to run from another machine it wont allow you in as root (security).


PS. Once you have this working try downloading MySQL Workbench, it free from the MySQL site and is SOOO much easier to use than phpMyAdmin. Of course you will have to get used to phpMyAdmin as thats whats provided by most hosting companies. But if you get yourself in a bit of a tizz like this it can get you another way of looking at your databases. Its much easier to test your SQL using workbench as well.

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: GraceBT (---.war.clearwire-wmx.net)
Date: August 02, 2012 02:42PM

RiggsFolly,

I don't remember now if the MySQL. password that I set up was for 'root@localhost',
it could have been for grace@localhost or something else. I will need to figure
out how to check on that. I set up MySQL separately prior to installing WAMP and I
was just a little surprised when it remembered my password. The WAMP setup must have
left my original settings intact because the old password is correct. Well it is getting on toward 6:00am
here in Seattle, and I need to get stirring around a little bit, so I will table this for the present. One
other thing that I am noticing is that I need to start WAMP with ""Start all services" and it is showing
orange. I believe it should be green. I wonder how to tell what WAMPs complaint is. I am just new on
this, but it looks pretty good so far. I got Apache Ant running this morning also. So it's breakfast
break time.

Thank You for Your help! I still have the following message after making the recommended changes.
(should I be editing the copy of config.inc.php in the PHPMyAdmin\ directory or the one ii
PHPMyAdmin\setup\frames\ ?

MySQL said: Documentation
#1045 - Access denied for user 'root'@'localhost' (using password: NO)

Regards,

73
-Grace
NNNN
z

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: stevenmartin99 (Moderator)
Date: August 02, 2012 03:19PM

Hi grace - phpmyadmin won't work while the icon is orange,

It sounds like your other MySQL is still running and that's why it know the password.

If you want to get Teamviewer I will take a look at why it's picking up the wrong settings

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

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: GraceBT (---.war.clearwire-wmx.net)
Date: August 02, 2012 05:05PM

Steve, are you on any chat (IRC) etc, or do you want me to send my Teamviewer info via email?

I don't mind if You have a look around. I have Teamviewer set updating it to the latest version
now. (v7.0.13989)

Thank You Steve,

73
-Grace
NNNN
z



Edited 2 time(s). Last edit at 08/02/2012 05:07PM by GraceBT.

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: stevenmartin99 (Moderator)
Date: August 02, 2012 05:21PM

Send by email, to my gmail address below or a private message here

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

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: GraceBT (---.war.clearwire-wmx.net)
Date: August 02, 2012 05:25PM

Sent

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: GraceBT (---.war.clearwire-wmx.net)
Date: August 02, 2012 07:22PM

I have smtp in the management console now... looks okay...

Steve, I have Teaviewer on if you are available.

73
-Grace
NNNN
z

Options: ReplyQuote
Re: Cannot Access phpMyAdmin
Posted by: robmillion (---.static.dsl.dodo.com.au)
Date: November 27, 2012 05:07AM

I made the same mistake of setting a password for the user 'root' via the console. Because phpMyAdmin defaults to the 'root@localhost' user login, it won't work because of the password.

You need to edit the config.inc.php file inside the phpmyadmin folder as follows...

/* Authentication type and info */
$cfg['Servers'][$i]['auth_type'] = 'http';
$cfg['Servers'][$i]['user'] = '';
$cfg['Servers'][$i]['password'] = '';
$cfg['Servers'][$i]['extension'] = 'mysql';
$cfg['Servers'][$i]['AllowNoPassword'] = false;

This will prompt phpMyAdmin to ask for a username and password to login with.

Happy PHP'ing folks.

P.S. my first post on here so be gentle.

Options: ReplyQuote


Sorry, only registered users may post in this forum.