0

So I installed the P3 plugin to analyze the plugin load time at my site. It was OK at the actually analyzing but just a really poor plugin that basically crashed my server which has great specs over and over.

So I deactivated and deleted the plugin... boom. Problems

My php log got filled up with

WordPress database error MySQL server has gone away for query UPDATE learning_options SET option_value = 'a:6:{i:1441144722;a:4:{s:16:\"wp_version_check\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}s:17:\"wp_update_plugins\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}s:16:\"wp_update_themes\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}s:19:\"wp_scheduled_delete\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:5:\"daily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:86400;}}}i:1441146005;a:5:{s:48:\"check_plugin_updates-wp-slimstat-export-to-excel\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}s:42:\"check_plugin_updates-wp-slimstat-custom-db\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}s:46:\"check_plugin_updates-wp-slimstat-email-reports\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}s:46:\"check_plugin_updates-wp-slimstat-user-overview\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}s:48:\"check_plugin_updates-wp-slimstat-default-filters\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}}i:1441179720;a:1:{s:20:\"wp_maybe_auto_update\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:10:\"twicedaily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:43200;}}}i:1441266295;a:1:{s:30:\"wp_scheduled_auto_draft_delete\";a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:3:{s:8:\"schedule\";s:5:\"daily\";s:4:\"args\";a:0:{}s:8:\"interval\";i:86400;}}}s:20:\"wp_batch_split_terms\";a:9780:{i:1441144656;a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:2:{s:8:\"schedule\";b:0;s:4:\"args\";a:0:{}}}i:1441144658;a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:2:{s:8:\"schedule\";b:0;s:4:\"args\";a:0:{}}}i:1441144659;a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:2:{s:8:\"schedule\";b:0;s:4:\"args\";a:0:{}}}i:1441144669;a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:2:{s:8:\"schedule\";b:0;s:4:\"args\";a:0:{}}}i:1441144686;a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:2:{s:8:\"schedule\";b:0;s:4:\"args\";a:0:{}}}i:1441144687;a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:2:{s:8:\"schedule\";b:0;s:4:\"args\";a:0:{}}}i:1441144702;a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:2:{s:8:\"schedule\";b:0;s:4:\"args\";a:0:{}}}i:1441144730;a:1:{s:32:\"40cd750bba9870f18aada2478b24840a\";a:2:{s:8:\"schedule\";b:0;s:4:\"args\";a:0:{}}}i:1441144748;a:1:{s:32:\

....

.... (1-2 MB of similar data)

WHERE option_name = 'cron' made by do_action('admin_init'), call_user_func_array, _wp_check_for_scheduled_split_terms, wp_schedule_single_event, _set_cron_array, update_option

So it looks like P3 didn't delete its cron jobs. I saw that it left an option_name "cron" with the 1-2MB of data that was causing the mysql timeout... I had deleted that. But boom a couple days later I noticed it popped back up in my database - I had checked after the first delete that the cron wasn't writing php errors.

So this time around I deleted the cron again, and I noticed option_name "_transient_doing_cron" with the transient id which I am assuming is the P3 plugin. And then option_name "p3_scan_" with what looks to be its scan script. I deleted these. Is there anything else I can do to make sure this P3 cron doesn't keep writing to my db?

Update: Given that the cron is executing a script too long for my server to handle - for whatever reason. Why does this cron job keep reappearing in my options table every week? Server will run clean then bam... I see the transient mentioned and the cron job. Is there a place to look to delete files/database options?

  • 1
    If you search the P3 plugin files for wp_cron or cron, nothing comes up in the results. Is it possible another plugin is causing this? It doesn't appear that P3 actually sets any crons via wp_cron. Perhaps the P3 plugin caused issues with another plugin which caused it to write these cron jobs to the DB ??? – Chris Sep 14 '15 at 1:34
  • @Chris - I will look but I think it is P3. When I was using P3 using the admin interface - not knowing how the plugin worked I had a scheduled job for it to scan my site and report plugin issues. Maybe you are right but I am almost positive these were registered as cron jobs. I guess I could tell on my sandbox. – STing Sep 14 '15 at 2:10
  • Yea it makes sense, but in order to interact with built in WP crons, they need to be registered using something. I couldn't even find a database write by P3 to modify the wp_cron scheduled string. Strange. – Chris Sep 14 '15 at 2:12
  • 1
    @cybmeta - learning_options is my options table. And plugins write to the options table. If I knew for 100% sure it was a P3 issue I would write them. – STing Sep 22 '15 at 22:52

Your Answer

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

Browse other questions tagged or ask your own question.