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

When the auth_type is set to cookie, phpMyAdmin won't allow anyone access.

Putting the same credentials we are trying on the form into the config file works.

Does anyone have any ideas what could be causing this? I have a blowfish secret set and can't see anything else that is needed or missing.

Here is my config.inc.php file (with the blowfish secret removed).

 /*
 * This is needed for cookie based authentication to encrypt password in
 * cookie
 */
$cfg['blowfish_secret'] = '***********'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */

/*
 * Servers configuration
 */
$i = 0;

/*
 * First server
 */
$i++;

/* Authentication type */

$cfg['Servers'][$i]['auth_type'] = 'cookie';

/* Server parameters */
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['compress'] = false;

/*
 * Directories for saving/loading files from server
 */
$cfg['UploadDir'] = '';
$cfg['SaveDir'] = '';
share

migration rejected from superuser.com May 6 at 14:45

This question came from our site for computer enthusiasts and power users. Votes, comments, and answers are locked due to the question being closed here, but it may be eligible for editing and reopening on the site where it originated.

closed as off-topic by Jenny D, mdpc, Scott Pack, MadHatter, Massimo May 6 at 14:45

This question appears to be off-topic. The users who voted to close gave these specific reasons:

If this question can be reworded to fit the rules in the help center, please edit the question.

2  
Anything show up in error log when you try to login? –  opsguy Jul 18 '11 at 16:52

1 Answer 1

up vote 4 down vote accepted

I'll take a guess at this one (despite little diagnostic information), having had the exact same problem before.

Run <?php phpinfo(); ?> to determine the location of your php.ini file (mine is in /etc/php.ini)

Open php.ini and check look for session.save_path (in my case, /var/lib/php/session )

Check the permissions of that directory, try setting it to 0777 initially to see if it resolves the problem. If it does, check your users and groups (e.g. do you run php under apache/www-data or do you use suexec and run under multiple users) and set appropriate permissions.

(If none of the above work, I suggest trying a clean copy of phpMyAdmin, and making minimal changes to the config file (while keeping the permissions on the above directory 0777) - I have had it happen where my modifications prevented a successful login).

share
    
That line is commented out, I will need to schedule some downtime to play with that, thanks for your help. –  Toby Jul 19 '11 at 7:44
    
a) double check that it actually is commented out - php.ini has a lot of 'documentation' in it - I have two lines where it is commented out (part of the 'how to use it' sections - both values starting with 'N;' and one where it is not commented out. b) Even if it is commented out, you should be able to find the path by looking in at the output of your phpinfo() script, under the 'session' section. –  cyberx86 Jul 19 '11 at 9:21

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