Title: Fatal Error: Maximum execution time exceeded
Last modified: August 30, 2016

---

# Fatal Error: Maximum execution time exceeded

 *  [SJW](https://wordpress.org/support/users/whitsey/)
 * (@whitsey)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/)
 * I seem to be getting this more and more these days…
 * Fatal error: Maximum execution time of 30 seconds exceeded in /wp-content/plugins/
   better-wp-security/modules/free/file-change/class-itsec-file-change.php on line
   609
 * What is wrong with iTheme Security?
 * I can increase the max execution time but either way, if my customers have to
   wait more than 30 seconds for the page to load, it probably doesn’t matter by
   then…
 * Amny help or recommendations would be appreciated
 * [https://wordpress.org/plugins/better-wp-security/](https://wordpress.org/plugins/better-wp-security/)

Viewing 9 replies - 1 through 9 (of 9 total)

 *  [dwinden](https://wordpress.org/support/users/dwinden/)
 * (@dwinden)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299264)
 * There are 2 ways of running a File Change Detection scan.
    Manually by clicking
   on the “Scan Files Now” button in WP Dashboard or automatically triggered by 
   users visiting your site or you accessing WP Dashboard.
 * Does the error occur in both situations ?
 * Line 609 is executed as part of any type of File Change Detection scan.
    This
   line checks whether a file/folder found needs to be scanned according to the **
   Include/Exclude Files and Folders** and **Files and Folders List** settings.
 * In order to be able to say anything about your issue please provide how the following
   File Change Detection settings are set in your env:
 * **Split File Scanning** [ ] Split file checking into chunks.
 * **Include/Exclude Files and Folders**
 * **Files and Folders List**
 * **Ignore File Types**
 * The problem could be specific for the check performed in line 609.
    But it could
   also be that the File Change Detection scan as a whole is just too big. You may
   need to split file checking into (7) chunks.
 * Also provide the data from the “PHP Information” section in the System Information
   metabox on the iTSec plugin Dashboard page.
 * dwinden
 *  Thread Starter [SJW](https://wordpress.org/support/users/whitsey/)
 * (@whitsey)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299560)
 * Thanks for the response
 * Yes – it occurs in both the front end and backend – Just checked the error_log
   and it is 509MB with this line occuring regularly:
    [12-Jun-2015 01:41:37 UTC]
   PHP Fatal error: Maximum execution time of 30 seconds exceeded in /wp-includes/
   option.php on line 52 (1128 times)
 * Split File Scanning
    – Not Checked
 * Include/Exclude Files and Folders
    – Exclude Selected
 * Files and Folders List
    – error_log .htaccess wp-content/uploads/wpcf7_captcha/
   wp-content/cache/
 * Ignore File Types
    – .jpg .jpeg .png .log .mo .po
 * PHP Information
    PHP Version: 5.3.29 PHP Memory Usage: 61.99 MB PHP Memory Limit:
   256M PHP Max Upload Size: 10MB PHP Max Post Size: 8M PHP Safe Mode: Off PHP Allow
   URL fopen: On PHP Allow URL Include: Off PHP Display Errors: On PHP Display Startup
   Errors: Off PHP Expose PHP: On PHP Register Globals: Off PHP Max Script Execution
   Time: 30 Seconds PHP Magic Quotes GPC: On PHP open_basedir: Off PHP XML Support:
   Yes PHP IPTC Support: Yes PHP Exif Support: Yes ( V1.4 ) Disabled PHP Functions:(
   none)
 *  [dwinden](https://wordpress.org/support/users/dwinden/)
 * (@dwinden)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299561)
 * Thank you for your feedback.
 * Are you using a caching plugin ? If so which one ?
 * Any idea how much files (roughly) are in the excluded dirs:
 * wp-content/uploads/wpcf7_captcha/
    wp-content/cache/
 * 10s, 100s, 1000s, 10000s, 100000s, 1000000s ?
 * If I understand correctly the issue is intermittent. Though getting more frequent.
   
   So there are probably also completed File Changes Detected log entries in the
   iTSec plugin Logs page. Please provide a screendump of the iTSec plugin Logs 
   page after selecting **File Change History** in the **Select Filter:** dropdown
   listbox.
 * Send the screendump file as an email attachment to _[ redacted, support is not
   offered via email, Skype, IM etc. only in the forums ]_
    Once all the above info
   has been collected and analyzed I hope to be able to provide you with some advice
   on what to do.
 * dwinden
 *  Thread Starter [SJW](https://wordpress.org/support/users/whitsey/)
 * (@whitsey)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299562)
 * Yes – W3 Total Cache
 * File Count:
    wp-content/uploads/wpcf7_captcha/ – 163 wp-content/cache/ – 19
 * The issue is intermittent for me but with 1128 entries in error_log, I wonder
   how many customers I’ve lost – I’ve de-activated the plugin atm but I can check
   for Logs.
 * Logs say there are 0 Files Changes in the History.
    Do you still want screen 
   dump?
 *  [dwinden](https://wordpress.org/support/users/dwinden/)
 * (@dwinden)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299564)
 * I’m a little bit puzzled now because this topic started with the msg:
 * Fatal error: Maximum execution time of 30 seconds exceeded in /wp-content/plugins/
   better-wp-security/modules/free/file-change/class-itsec-file-change.php on line
   609
    (It’s not clear where this message is reported).
 * But in your second post you mention a somewhat different error msg from the error_log:
 * [12-Jun-2015 01:41:37 UTC] PHP Fatal error: Maximum execution time of 30 seconds
   exceeded in /wp-includes/option.php on line 52 (1128 times)
 * The first error msg can easily be linked to the iTSec plugin File Change Detection
   feature, but the second one refers to a general WP file\script (option.php).
 * Perhaps this needs a little bit of clarification.
 * I certainly would like to have a look at the requested screendump.
    You can temp
   reactivate the iTSec plugin, make the screendump and then deactivate the plugin
   again.
 * dwinden
 *  Thread Starter [SJW](https://wordpress.org/support/users/whitsey/)
 * (@whitsey)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299565)
 * Where’s the confusion? I’ve just re-read and its all pretty clear.
 * The first error occurred when I tried to access a page on my site – it displayed
   in the front end for the whole world to see – I posted here!
 * You asked for additional information, at which stage I noticed an exorbitantly
   large error_log file. I checked it and it was apparent that this issue has been
   happening quite regularly (1128 times to be exact)
 * Where’s the confusion? This plugin has caused a timeout 1128 times on my website!
 *  [Gerroald](https://wordpress.org/support/users/gerroald/)
 * (@gerroald)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299587)
 * Hey Shannon,
 * You can ask your host to increase your PHP max execution time and see if that
   helps. They won’t have to wait longer than 30 seconds (or even 30 seconds) for
   the page to load. This is for PHP processes to run, not page load time.
 * If this doesn’t help I’d suggest disabling the File Change Detection feature 
   for now.
 * Thanks,
 * Gerroald
 *  [bedifferent](https://wordpress.org/support/users/bedifferent/)
 * (@bedifferent)
 * [10 years, 5 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299658)
 * I understand the solution that you have proposed above to disable the file changing
   detection feature. My issue is that I am currently receiving a 504 error from
   the site and so I cannot access my WP dashboard to disable the feature. My error
   is
 * a function from wp-content/plugins/better-wp-security/core/modules/file-change/
   class-itsec-file-change.php at line 230 that’s timing out and causing the issue,
   here’s the php-slow.log entry showing this:
 * bc. [08-Dec-2015 10:47:49] [pool www] pid 10227
    script_filename = /srv/bindings/
   586ed90fb03e4e19903b848e0d2635a5/code//index.php [0x00007f29479ca3e0] array_diff_assoc()/
   srv/bindings/586ed90fb03e4e19903b848e0d2635a5/code/wp-content/plugins/better-
   wp-security/core/modules/file-change/class-itsec-file-change.php:230 [0x00007fff9afbae80]
   execute_file_check() unknown:0 [0x00007f29479ca1e8] call_user_func_array() /srv/
   bindings/586ed90fb03e4e19903b848e0d2635a5/code/wp-includes/plugin.php:503 [0x00007f29479ca050]
   do_action() /srv/bindings/586ed90fb03e4e19903b848e0d2635a5/code/wp-settings.php:
   353 [0x00007f29479c9f28] +++ dump failed
 * How do I change the settings in code, qwhat do I change it to?
 * Obviously if I could get to the WP dashboard then I could change the settings
   through the interfface but currently that isn’t possible.
 * Here is line 230 from my PHP file in the plugin
 * wp-content/plugins/better-wp-security/core/modules/file-change/class-itsec-file-
   change.php
 * $files_added = @array_diff_assoc( $current_files, $logged_files ); //files added
 * Can I just comment it out and expect things to work or is there a lot more to
   it than that?
 *  [dwinden](https://wordpress.org/support/users/dwinden/)
 * (@dwinden)
 * [10 years, 5 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299659)
 * [@bedifferent](https://wordpress.org/support/users/bedifferent/)
 * > Can I just comment it out and expect things to work or is there a lot more 
   > to it than that?
 * In general changing the code is not a good idea.
 * Assuming the File Change Detection feature is preventing you to access WP Dashboard
   simply disable the File Change Detection feature in the database.
 * 1. Login into your database using PHPMyAdmin.
    2. Execute the following SQL command:
 * > select * from wp_options where option_name = ‘itsec_file_change’;
 * 3. Change in serialized option_value string s:7:”enabled”;b:**1**; into string
   s:7:”enabled”;b:**0**;
    4. Save change and exit.
 * dwinden

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Fatal Error: Maximum execution time exceeded’ is closed to new replies.

 * ![](https://ps.w.org/better-wp-security/assets/icon.svg?rev=3529351)
 * [Kadence Security – Password, Two Factor Authentication, and Brute Force Protection](https://wordpress.org/plugins/better-wp-security/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/better-wp-security/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/better-wp-security/)
 * [Active Topics](https://wordpress.org/support/plugin/better-wp-security/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/better-wp-security/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/better-wp-security/reviews/)

 * 9 replies
 * 4 participants
 * Last reply from: [dwinden](https://wordpress.org/support/users/dwinden/)
 * Last activity: [10 years, 5 months ago](https://wordpress.org/support/topic/fatal-error-maximum-execution-time-exceeded-3/#post-6299659)
 * Status: not resolved