phpmyadmin logs out after 1440 secs

To fix the issue of phpMyAdmin logging out after 1440 seconds (24 minutes), you need to adjust the session timeout settings in both php.ini and phpMyAdmin’s configuration file. Here’s a step-by-step guide on how to do it:

  1. Locate the php.ini file: The location of the php.ini file may vary depending on your operating system and PHP installation. Common locations include /etc/php.ini for Linux or C:\php\php.ini for Windows.
  2. Open the php.ini file with a text editor.
  3. Search for the following line:
    session.gc_maxlifetime = 1440

    This line specifies the maximum lifetime of a session in seconds. By default, it’s set to 1440 seconds (24 minutes).

  4. Increase the session timeout value: Change the value to a higher number to extend the session timeout. For example, if you want the session to last for 1 hour (3600 seconds), change it to:
    session.gc_maxlifetime = 3600
  5. Save the changes and close the php.ini file.
  6. Locate the phpMyAdmin configuration file: The configuration file for phpMyAdmin is called config.inc.php, and it is typically located in the phpMyAdmin installation directory.
  7. Open the config.inc.php file with a text editor.
  8. Search for the following line:
    $cfg['LoginCookieValidity'] = 1440;

    This line sets the session validity for phpMyAdmin in seconds. Again, it is set to 1440 seconds (24 minutes) by default.

  9. Increase the session validity value: Change the value to match the updated value in the php.ini file. For example:
    $cfg['LoginCookieValidity'] = 3600;

    Make sure the value matches the one you set in step 4.

  10. Save the changes and close the config.inc.php file.
  11. Restart your web server: After modifying the session timeout settings, restart your web server to apply the changes. The method to restart the web server depends on the operating system and the web server software you are using.

If  editing Config.inc.php doesn’t work change it the following way –

To fix the issue of phpMyAdmin logging out after 1440 seconds (24 minutes) directly from phpMyAdmin settings, you can follow these steps:

  1. Open your web browser and access phpMyAdmin.
  2. Log in to phpMyAdmin with your username and password.
  3. Once logged in, navigate to the “Settings” tab at the top.
  4. In the settings page, find the “Features” section.
  5. Look for the option called “Login cookie validity” or something similar. This option determines the duration of the session before phpMyAdmin logs you out.
  6. By default, this value is set to 1440, which corresponds to 1440 seconds (24 minutes).
  7. Increase the session timeout value: Modify the value to a higher number to extend the session timeout. For example, if you want the session to last for 1 hour (3600 seconds), change it to 3600.
  8. After changing the value, scroll down to the bottom of the page and click on the “Save” or “Apply” button to save the changes.
  9. Refresh the phpMyAdmin page or log out and log back in to apply the new session timeout setting.

phpmyadmin logs out after 1440 secs