Page 1 of 1
phpmyadmin login problem
Posted: Fri May 12, 2006 12:06 am
by bugthefixer
I have installed wamp 1.6.3 on my machine. Initially MySQL user 'root' was set using NO password. But then I assigned it a password. Now the problem is when ever I try to open phpmyadmin it say Access Denied.
Posted: Fri May 12, 2006 1:15 am
by RobertGonzalez
Which version of MySQL and which mysql client API are you using? If mysql is over 4.1 and your client is older than 3.23, you are going to have this problem. You made need to edit your my.ini (or my.conf for linux) to add the 'old_passwords'directive to the mysqld section.
Posted: Fri May 12, 2006 2:10 am
by Benjamin
Actually I think the solution would be to configure phpMyAdmin to use a password. It attempts to login using root with no password as default. So if a password was set, phpMyAdmin needs to be configured to use the password.
Posted: Fri May 12, 2006 2:27 am
by bugthefixer
I am using mysql 5.0 version i cudnt understand which directive you are talking about and wat shud be the value for this directive.
Posted: Fri May 12, 2006 10:36 am
by RobertGonzalez
DB server: MySQL 5.0.
PHP version: ?
MySQL client API version: ?
What type of authentication are you using for PMA, cookie, config or httpd?
Posted: Sat May 13, 2006 5:16 am
by raghavan20
in the installation folder of the phpmyadmin, you should be having config.inc.php, if not available you have to create one.
use this code
Code: Select all
<?php
/*
* Generated configuration file
* Generated by: phpMyAdmin 2.8.0.3 setup script by Michal ÄŒihaÅ™ <michal@cihar.com>
* Version: $Id: setup.php,v 1.23.2.2.2.1 2006/03/08 19:06:48 nijel Exp $
* Date: Sun, 30 Apr 2006 09:22:55 GMT
*/
/* Servers configuration */
$i = 0;
/* Server localhost (config:pma) [1] */
$i++;
$cfg['Servers'][$i]['bookmarktable'] = 'pma_bookmark';
$cfg['Servers'][$i]['relation'] = 'pma_relation';
$cfg['Servers'][$i]['table_info'] = 'pma_table_info';
$cfg['Servers'][$i]['table_coords'] = 'pma_table_coords';
$cfg['Servers'][$i]['pdf_pages'] = 'pma_pdf_pages';
$cfg['Servers'][$i]['column_info'] = 'pma_column_info';
$cfg['Servers'][$i]['history'] = 'pma_history';
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['port'] = '3306';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['compress'] = false;
$cfg['Servers'][$i]['auth_type'] = 'http';
$cfg['Servers'][$i]['controluser'] = 'pma';
$cfg['Servers'][$i]['controlpass'] = 'pmapass';
$cfg['Servers'][$i]['user'] = 'pma';
$cfg['Servers'][$i]['password'] = 'pmapass';
$cfg['Servers'][$i]['pmadb'] = 'pmadb';
$cfg['Servers'][$i]['ThemePath'] = '/darkblue_orange';
/* End of servers configuration */
?>
you should also create pma user and password which will be used by phpmyadmin to make changes to their tables. if the pmadb DB is not available, you can find the code for creating it from the documentation they have provided.
you have to make sure, this line has value of http
$cfg['Servers'][$i]['auth_type'] = 'http';
so that we you try access the index.php, it will prompt you for username and password which can be any valid existing username and password in the DB.
Posted: Sat May 13, 2006 8:52 am
by RobertGonzalez
None of this matters if the client api version is to old or the my.ini (my.conf) is not properly set up to handle old passwords with a new api.
On a side note, I have a setup on my devlopment machine that uses config as authentication, user root, no password and it works fine. It also has no PMA table. My production server has PMA set http authentication. No PMA table, but all DB users have a password.
Posted: Sat May 13, 2006 1:20 pm
by raghavan20
Everah wrote:None of this matters if the client api version is to old or the my.ini (my.conf) is not properly set up to handle old passwords with a new api.
I remember that when you put the phpmyadmin folders inside documentRoot, it will first try to connect to DB using root with no password. But if you want to connect with password, you have to create the config.inc.php where it reads how to configure the phpmyadmin to work. The authentication type would not be http for the first time you run phpmyadmin, and it will be using root with no password. You can alternatively retain the older authentication type but still you have to put a valid username and password if you do not want yourself or the users authenticated through HTTP. If you choose HTTP, you do not have to mention the username and password and the DB since these would anyway be asked when you try accessing index.php in phpmyadmin installation/root folder.
On a side note, I have a setup on my devlopment machine that uses config as authentication, user root, no password and it works fine. It also has no PMA table. My production server has PMA set http authentication. No PMA table, but all DB users have a password.
you are right. The phpmyadmin can work without the DB for itself. But if the DB is available it will save some information on our user sessions and about the data available in our mysql DBs.
Posted: Mon May 15, 2006 3:40 am
by bugthefixer
Thanks raghavan and every one else .... actually the password was not set in phpmyadmin config file i.e. config.inc.php so now it works fine .... thanx again