phpMyAdmin
Posted by: alejandrowski (---.Red-213-98-71.staticIP.rima-tde.net)
Date: July 06, 2006 09:27AM

Hi, a new problem I have got.

I put a password to my root in phpMyAdmin, and now I can't use phpMyAdmin, this is that apeear in the sceen:

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

How I can resolve this?
Thank you.

Options: ReplyQuote
Re: phpMyAdmin
Posted by: yfastud (72.236.169.---)
Date: July 06, 2006 02:06PM

This question is repeated more than a million times already, you should perform a search in this forum before post. Any way, here is the solution:

For setup password, need to change it in 2 places:

1. Set password in Privilleges in phpMyAdmin from your Browser/Localhost.
Goto: localhost/phpmyadmin/
click on "Privileges" link
click on "edit Privileges" link for ROOT user
and set-up your password (change password) and click go

2. Set password in config.inc.php in /wamp/phpmyadmin.
Find and put your password in this line:
$cfg['Servers'][$i]['password'] = 'Your_new_password_here'; // MySQL password (only

Also, if like to set the permission to access PHPmyadmin and SQLitemanager (credited to Joshua), so only local network user can access it through Localhost or Alias; otherwise, use htaccess and htpasswrd.

1. open httpd.conf in /wamp/Apache2/conf

2. find the lines
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all
</Directory>

3. after the </directory> line above add the following:

<Directory "C:/Internet/wamp/www/phpmyadmin">
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Directory>

<Directory "C:/Internet/wamp/www/sqlitemanager">
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Directory>

4. change location of the directories as your might be different from "C:/Internet/wamp/www/phpmyadmin"

Also in Alias folder (/wamp/Apache2/conf/alias), replace these lines in phpmyadmin.conf and splitemanager.conf:

Order allow,deny
Allow from all

By these lines:

Order deny,allow
Deny from all
Allow from 127.0.0.1

Hope this help

Options: ReplyQuote
Re: phpMyAdmin
Posted by: sharksandwich (---.houston.res.rr.com)
Date: July 07, 2006 05:38AM

That is all well and good but PHPmyAdmin has an error every time for many users, I think it is more important to show how to change inside mysql console.

Author: SkareCrow (---.dhcp.wnch.wa.charter.com)
Date: 06-15-06 11:45

You do not need to login.
By default the mysql root user password is null.
Just press <enter> when it asks you for your password and you will login just fine.
If you want to set a password you do this...

get into mysql console..
type: USE mysql;
type: UPDATE user SET Password=PASSWORD('yournewpassword') WHERE User='root';
type: FLUSH PRIVILEGES;

now you can logout of mysql and then when you open the mysql console again you will need to use that

new password to login


Options: ReplyQuote
Re: phpMyAdmin
Posted by: CyberSpatium (67.170.181.---)
Date: July 07, 2006 09:12AM

using phpmyadmin or the console to set users and passwords is the same thing.

sharksandwich, you should not let anyone exept for yourself have access to phpmyadmin. WAMP was designed for local testing and development, not to be a full production server. it has no security in place.

However, if you want to only allow a few trusted friends to have access to your phpmyadmin. you can add their ip address to the Allow from directive from what yfastud posted above. say you have two friends, one with the ip address 11.11.11.11 and the other with 22.22.22.22. Here is how you would do it.

change:
<Directory "C:/Internet/wamp/www/phpmyadmin">
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Directory>

to this:
<Directory "C:/Internet/wamp/www/phpmyadmin">
Order deny,allow
Deny from all
Allow from 11.11.11.11 22.22.22.22
</Directory>

save the file and restart apache for the new settings to take effect.

Options: ReplyQuote


Sorry, only registered users may post in this forum.