PHP Fatal error in Session_files_driver.php on line 247 |
Hi there,
I built a program using CI 3 with a login page that auto-loads the 'session' library in autoload.php. The problem is that occasionally, now 2nd day in a row, I encounter a 500 Internal Server Error when using the site. After reviewing the error logs in cpanel, this is what I see: Code: mod_fcgid: stderr: PHP Fatal error: Maximum execution time of 30 seconds exceeded in /system/libraries/Session/drivers/Session_files_driver.php on line 247 The only thing that helps fix this is removing the session library from the auto-load file, waiting some time and then re-adding the session library. This happens very sporadically and I am not sure whether this is a bug or something to do with the server config. Once the session library is re-added to the autoload file after some time, the website is working as normal. All the default session settings are used: PHP Code: $config['sess_driver'] = 'files'; Does anyone have any suggestions as to why this is happening and how to troubleshoot this further? Any help is much appreciated. Thank you!
You can try to change the execution time by placing the below at the top of your index.php file:
ini_set('max_execution_time', 60); //60 seconds = 1 minute What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
(01-18-2016, 10:22 AM)vm90 Wrote: Hi there, Hello VM, Well thanks for this post I have done the same thing you have explained and it fixes the issue but I think it must be a bug because I have same application made in CI 2 and it is working perfect without any issue. I will still monitoring for this issue and if I face this again I will downgrade my CI version from 3 to 2. |
Welcome Guest, Not a member yet? Register Sign In |