After resetting password on a Magento 2 installation, when trying to login to backend, I get following error message.
Your password has expired; please contact your administrator. All other open sessions for this account were terminated. It's time to change your password.
To fix this error, on the command line, run the following commands
php bin/magento config:set admin/security/password_is_forced 0 php bin/magento config:set admin/security/password_lifetime 0 php bin/magento cache:flush
You can also update the database table admin_passwords and update the value of the “expires” column to a future date (UNIX timestamp)
UPDATE admin_passwords SET expires=1999999998 WHERE user_id=USER_ID_HERE;
In the above SQL command, replace USER_ID_HERE with the “user_id” of the admin user for which you get the password expired error message.
Back to Magento
Leave a Reply