How to fix Magento 2 error Fatal error: Uncaught TypeError: strtotime() expects parameter 1 to be string, null given in /module-security/Model/AdminSessionInfo.php:136?

How to fix Magento 2 error Fatal error: Uncaught TypeError: strtotime() expects parameter 1 to be string, null given in /module-security/Model/AdminSessionInfo.php:136?

---

If you upgraded Magento 2 and when you entering into Magento 2 admin you can see error:

Fatal error: Uncaught TypeError: strtotime() expects parameter 1 to be string, null given in /module-security/Model/AdminSessionInfo.php:136

Hot to fix this error:

1. Check config variable:

bin/magento config:show system/security/max_session_size_admin

If you see answer like this:

Configuration for path: "system/security/max_session_size_admin" doesn't exist

then you just need to add new variable into Magento 2 config:

bin/magento config:set system/security/max_session_size_admin 2560
00                                                  

DONE

now you can enter into admin