0

A client recently contacted me to say they got a 500 error when trying to access their Magento 1.9 admin.

My first idea was to refresh the cache manually. This worked.

It sounds like they might not have logged in in a while, but why should not logging in or not clearing the cache make the admin inaccessible.

The associated error message was:

PHP Fatal error: Maximum execution time of 30 seconds exceeded in /lib/Zend/Cache/Backend/File.php on line 679

Here's a link to the file producing the error: https://github.com/OpenMage/magento-mirror/blob/magento-1.9/lib/Zend/Cache/Backend/File.php

I understand that the max_execution_time has exceeded and that increasing this time might help, but I want to understand why it exceeded in the first place. It should not need 30s+ to access Magneto admin so there is obviously an issue causing the timeout.

Any ideas would be helpful.

Thanks in advance :)

  • You should look into running the magento profiler, it will reveal the function causing the delay – Ricky Odin Matthews Jun 17 '20 at 12:47
  • @RickyOdinMatthews, I thought that but as mentioned, clearing the cache fixed the issue so the profiler wouldn't show anything at the moment. – thatweblook Jun 18 '20 at 13:26
  • my logic is that the cache is cleared then something is being created on the first load (into the cache), causing your timeout – Ricky Odin Matthews Jun 18 '20 at 13:38
  • @RickyOdinMatthews thanks. I need the error to come back to I can run the profiler and see what it is! – thatweblook Jun 19 '20 at 14:07
0

Please open your server php.ini file and increase the value of

max_execution_time = 30

to the max value like 60 or 90 so it will increase your execution time and it will work.

Please restart the server after change in this file.

  • keep as informed if that worked or not @thatweblook , otherwise I have another solution to increase the memory – Ahmed Chouihi Jun 16 '20 at 10:38
  • @AhmedC you can post another answer. If this will not work then he can try you one also. And other also can benefit of it. Thanks in advance. – Mayur Sisodiya Jun 16 '20 at 10:44
  • @MayurSisodiya thanks. I mentioned that I know increasing max_execution_time can help, but I want to know why the error occurred. It should not need more than 30s to open the Magento admin. – thatweblook Jun 17 '20 at 12:30
  • @thatweblook Yes some time site will take load or some big images is there. Then it will take more than 30s to open. – Mayur Sisodiya Jun 17 '20 at 13:22
  • @MayurSisodiya. Thanks but that doesn't really answer anything. The issue is with accessing Magneto admin - even just loading the login page. Clearing the cache fixed the issue so I want to understand what caused it. It is related to what happens on line 679 of /lib/Zend/Cache/Backend/File.php – thatweblook Jun 18 '20 at 13:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.