Skip to main content
The 2024 Developer Survey results are live! See the results
6 votes

When to truncate the core_session table?

The only reason to truncate this table is if you change the session storage so that you don't need the table anymore. That is, after migrating sessions to redis, files or whatever. It's the ...
Fabian Schmengler's user avatar
4 votes

\Magento\Backend\Model\Session Clear: Magento 2

I believe the method you are looking for in Magento 2 is destroy(). Take a look at the following class Magento\Backend\Model\Session it extends \Magento\Framework\Session\SessionManager which has ...
NathanielR's user avatar
3 votes

\Magento\Backend\Model\Session Clear: Magento 2

For frontend, protected $session; public function __construct( \Magento\Framework\Session\SessionManagerInterface $session ) { $this->session = $session; } //Unset all session data front ...
Rakesh Jesadiya's user avatar
2 votes

Magento session validation exception issue

You have a similar issue than this one: Try to to add return true; before if ($this->useValidateSessionExpire() in the file app/code/core/...
Proxium's user avatar
  • 206
1 vote

Loging on frontend failed with no errors

I think issue is regarding session, by default session store in files in Magento, you can try to change it to DB for your local instance and try if your problem resolve or not. You can change session ...
Aman Agarwal's user avatar
1 vote

When to truncate the core_session table?

Why not remove session records older than some time e.g. 1 week. This way you keep recent login/sessions/carts. DELETE FROM `session` WHERE session_expires < UNIX_TIMESTAMP(DATE_SUB(NOW(), ...
Liam Mitchell's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible