![]() |
Issue with session since upgrade to v3.1.9 - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: Issue with session since upgrade to v3.1.9 (/showthread.php?tid=71346) |
Issue with session since upgrade to v3.1.9 - arieccc - 08-02-2018 Hi there, I notice issues with the session since I upgraded to v3.1.9. This is the issue: Severity: Warning --> session_start(): Failed to decode session object. Session has been destroyed /CI_APP/system/libraries/Session/Session.php 143 These are my session settings: $config['sess_driver'] = 'files'; $config['sess_cookie_name'] = 'tp_session'; $config['sess_expiration'] = SESSION_DURATION; $config['sess_save_path'] = null; $config['sess_match_ip'] = false; $config['sess_time_to_update'] = 300; $config['sess_regenerate_destroy'] = false; Anyone else having this issue as well? RE: Issue with session since upgrade to v3.1.9 - php_rocs - 08-02-2018 @arieccc, What version of PHP are you using? RE: Issue with session since upgrade to v3.1.9 - dave friend - 08-02-2018 You cannot have a null sess_save_path when using the files driver. RE: Issue with session since upgrade to v3.1.9 - arieccc - 08-03-2018 Thanks for your replies guys! I am using PHP 7.1.20 I thought sess_save_path set to NULL would CI use the default session storage path, but I will check into this. The session is working normally, but at random moments I am being kicked out of the session and get the error as mentioned in my earlier post. I recall CI 2.x has same issues with this as well, ajax call killing the session and locking issues. Any ideas? RE: Issue with session since upgrade to v3.1.9 - InsiteFX - 08-03-2018 If your using ajax then you need to do a call session_write_close() once you no longer need anything to do with session variables. RE: Issue with session since upgrade to v3.1.9 - dave friend - 08-07-2018 (08-03-2018, 02:23 AM)arieccc Wrote: I thought sess_save_path set to NULL would CI use the default session storage path, but I will check into this. From the Sessions Variables section of config.php Quote:| 'sess_save_path' RE: Issue with session since upgrade to v3.1.9 - arieccc - 08-22-2018 Thanks for your replies! The session files were saved correctly. But issue remained. I tried to reduce size of each session (amount of data stored in the serialized session object). I reduced it from 8 kB to <1 kB. Didn't help. It is still a mystery to me why this issue occurs, but changing the session driver to database fixed my issue. So I will stick to that solution for now. RE: Issue with session since upgrade to v3.1.9 - php_rocs - 08-22-2018 @arieccc, If that was your solution then your problem might have been permissions on the session directory. RE: Issue with session since upgrade to v3.1.9 - InsiteFX - 08-23-2018 Or his session gc_probability is set to 0 |