Archive for category PhpMyAdmin

PHP parameter session.gc_maxlifetime is lower that cookie validity configured in phpMyAdmin

If you have installed a new MySQL version you may be getting the following warning message:

Your PHP parameter session.gc_maxlifetime is lower that cookie validity configured in phpMyAdmin, because of this, your login will expire sooner than configured in phpMyAdmin.

To solve this issue we first need to check what the session.gc_maxlifetime value is in php.ini and what the $cfg['LoginCookieValidity'] is in config.inc.php.

Example:

1. php.ini

session.gc_maxlifetime = 1440

2. config.inc.php

$cfg['LoginCookieValidity'] = 1800;

Now, we only need to make these two values the same. For the sake of this example, we will change the value of $cfg['LoginCookieValidity'] to 1440.

After saving the changes we need to restart the services to make them effective.

Notes:

1.The php.ini file can be found on the php folder.

2. The config.inc.php file can be found on the phpmyadmin folder.


If you’re interested in learning more about PhpMyAdmin then check out the book “Mastering PhpMydmin for Effective MySQL Management“.


No Comments

phpMyAdmin root with no password message

After installing WAMP Server it is common when you first access phpMyAdmin to get the following message:

“Your configuration file contains settings (root with no password) that correspond to the default MySQL privileged account. Your MySQL server is running with this default, is open to intrusion, and you really should fix this security hole by setting a password for user ‘.root’.”

To correct this security issue you need to do the following:

  1. Go to phpMyAdmin
  2. Select the Privileges tab
  3. Locate the user “root” that has localhost for a host
  4. Edit the root user privileges by clicking on the corresponding Edit Privileges button
  5. On the Change Password section insert the desired password and press Go
  6. You should now have at the top of the screen the message: “The password for ‘root’@’localhost’ was changed successfully.
  7. Now you need to edit file config.inc.php normally located at C:\wamp\apps\phpmyadmin3.2.0.1 (note that the version indication may vary)
  8. Locate $cfg['Servers'][$i]['auth_type'] = ‘config’; and change from config to cookie so that you get a login window every time you access phpMyAdmin
  9. Locate $cfg['blowfish_secret'] = ‘  ‘; line. If you don’t have one add it to your config.inc.php file
  10. Add a secret passphrase to $cfg['blowfish_secret'] = ‘  ‘; for example: $cfg['blowfish_secret'] = ‘secret_pass’;
  11. Save your changes
  12. Go to the WAMPServer and select Restart All Services
  13. Once all the services have been restarted go to phpMyAdmin and enter the username root and your password to access phpMyAmdin

Notes:

  1. The blowfish_secret passphrase should not be the same as the root password.
  2. If you don’t add a $cfg['blowfish_secret'] line to the config.inc.php file, when you access phpMyAdmin you’ll get the message: “The configuration file now needs a secret passphrase (blowfish_secret).

If you’re interested in learning more about PhpMyAdmin then check out the book “Mastering PhpMydmin for Effective MySQL Management“.


No Comments

%d bloggers like this: