phpmyadmin logs out after 1440 secs

后端 未结 24 1567
予麋鹿
予麋鹿 2021-01-29 23:29

In my local development Ubuntu box I use MySQL and phpmyadmin to work with the database.

Whenever phpmyadmin is idle for 1440 secs (24min) the session expires. I lose m

24条回答
  •  刺人心
    刺人心 (楼主)
    2021-01-30 00:00

    Follow below steps to increase session timeout for phpmyadmin:

    Method 1:

    • Login to phpMyAdmin with your root credentials
    • Select Settings from the top in navigation bar
    • Tap on Features
    • Search for Login cookie validity field in General tab
    • Change the value for this field to something greater than 1440 like 36000 or anything higher.

    Make sure whatever value you are entering in Login cookie validity is in seconds

    Method 2:

    Locate your config.inc.php file

    For CentOS, Fedora servers:
    /etc/phpMyAdmin/config.inc.php
    
    For Ubuntu, Debian servers:
    /etc/phpmyadmin/config.inc.php
    

    Search LoginCookieValidity in config.inc.php and increase its value

    $cfg['Servers'] [$i] ['LoginCookieValidity'] = 1440;
    
    //change to 
    $cfg['Servers'] [$i] ['LoginCookieValidity'] = 36000;
    

    Save the changes to the config.inc.php file and restart your server.

    Increase session.gc_maxlifetime in php.ini to be greater than or equal to the value that you entered in config.inc.php.

提交回复
热议问题