PhpMyAdmin: Keeping the session alive

Here we will see how to configure PhpMyAdmin to avoid the “login again” request when the session expires.

If the “login again” message is bothering you because the session has expired after 30 minutes (1800 seconds), which is a really short time :-), we can follow the next steps to keep the session alive.

The first step is to edit the configuration file (

user@unix:~$ gedit /path/to/your/phpmyadmin/

And replace the below line:

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

For this:

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

And, at the end of the file we should add:

$cfg['LoginCookieValidity'] = 86400;

That’s it, we should save the modifications and enter PhpMyAdmin again.