Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a site hosted on Rackspace Cloud. It runs Joomla 2.5, some test scripts, and PHPMyAdmin 4.1.6. Joomla runs off a database hosted in Rackspace Cloud. The host is mysql50-[redacted].wc2.dfw1.stabletransit.com I am able to take Joomla's settings and put them in a simple PHP script that runs mysqli_connect and read the database.

However, I am not able to get a PHPMyAdmin installation in a subfolder of the Joomla directory to connect. I PHPMyAdmin's setup and it generated this config file:

$cfg['Servers'][$i]['verbose'] = 'description';
$cfg['Servers'][$i]['host'] = 'mysql50-[redacted].wc2.dfw1.stabletransit.com';
$cfg['Servers'][$i]['port'] = '';
$cfg['Servers'][$i]['socket'] = '';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['user'] = '';
$cfg['Servers'][$i]['password'] = '';

No other modification to PHPMyAdmin was done.

It seems to match the settings used by Joomla and the test scripts, but every time I connect, I receive a #2002 Cannot log in to the MySQL server error. This error occurs no matter what username/password I use, hostname I use, or connection method/type I use. What is different about PHPMyAdmin that it fails to connect where Joomla and a simple mysqli_connect succeed?

share|improve this question
1  
Did you drop this generated config into the root folder of phpmyadmin? –  Nathan C Feb 3 at 18:45
    
Dear God. No, I thought it had to be in /config where it was generated. Works now. Feel free to make that an answer so I can accept! –  Michael Hopkins Feb 3 at 18:47
    
Yeah, it can be confusing. A bit of google-fo showed me that. :) –  Nathan C Feb 3 at 18:52
add comment

1 Answer 1

up vote 1 down vote accepted

Ensure the generated config file is in your root phpMyAdmin folder so it reads the proper file.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.