Reputation: 1676
I just migrate my site to localhost and everything working fine. but when i try to logged into my admin pannel then its through me error like Your current session has been expired.
I removed all the cache from the folder also change the setting from database about session expiration time.
also we have tried each and every possible solution from this thread.
Thanks in advance.
Upvotes: 6
Views: 17016
Reputation: 11
Admin Side login that time session expired
1 step: Find "admin/security/session_lifetime" in table core_config_data.
if not exist create one and set value to 86400
second step: clean cache (remove var/cache)
login and fix
Upvotes: 1
Reputation: 161
This is the perfect solution
first step: find "admin/security/session_lifetime" in table core_config_data. if not exist create one and set value to 86400
second step: clean cache (remove var/cache)
login and fix
https://github.com/magento/magento2/issues/5309
Upvotes: 16
Reputation: 1448
Make sure the times on all your servers are in sync. You do not need to update any tables.
Upvotes: 1
Reputation: 750
You need just to modify a value in your table [core_config_data] in database.
core_config_data
SET value
= 864000 WHERE path
= 'admin/security/session_lifetime'I hope this could help you.
Upvotes: 1
Reputation: 89
I was facing same issue, After some research I had found the solution for admin login issue.
It's occured due to MySql TIMESTAMP and MySql version issue.
If we are using MySql 5.5.x than we need to take care about TIMESTAMP.
Here is the perfect solution which helps you to overcome the admin login issue of session.
Go to : admin_user_session
table in MySql
Set created_at
column to '0' and updated_at
column to 'CURRENT_TIMESTAMP' as it is.
Refresh admin page and try to login again, it will work 100%
Thanks.
Upvotes: 6
Reputation: 2325
Run the below commonds in your local server.
First, clean cache and index all
php bin/magento cache:clean
php bin/magento indexer:reindex
Still have issue then deploy again:
rm -rf pub/static/* // remove all static folder content
rm -rf var/* // remove var folder content
bin/magento setup:static-content:deploy
chmod -R 7777 var pub/static // set permission (not need in local server)
Upvotes: -5