Updated WP Smush Pro, 40-50 second load. Long Time to first byte time.

WP Smush Pro was working well for me on shared hosting, but for some reason when I moved to a VPS and updated the plugins. I have been plagued by slow load times on pagespeed and webpagetest.org

Bulk of it comes from a server wait 30-40 seconds for Time to First Byte.

Apache slow logs show Smush Pro coming up pretty often and after disabling it my TTFB dropped to 2-3 seconds

Anyone know why this would be?

  • Rupok
    • Support Ninja

    Hi webworth

    I hope you had a wonderful day.

    I'm running 3 test sites on my VPS but I didn't face any issue like this. I'm using latest version of the plugin with WordPress 4.4.1 in all my sites.

    So there could be configuration related issue in your VPS. Is it a managed one or un-managed one? If un-managed, are you using basic lamp server or third party solutions like VestaCP or Sentora? Can you share your apache log file with us? If it's too big, can you copy relevant lines, paste it in a text file and attach here so we can have a look?

    I just went to http://www.rattleandyum.com/ and it showing WSoD (White Screen of Death). Are we talking about this site?

    Have a nice day. Cheers!

    • webworth
      • Flash Drive

      I'm using serverpilot to control a vultr instance. It's not managed, I think the paid tier of serverpilot provides some basic support and they had pointed out that my theme and WP Smush Pro were showing up quite often in the _php7.0.slow.log That's when I disabled the WP Smush Pro plugin and noticed a jump in TTFB.

      Yes that's the site.

      Here's a link to the log file


      I think the pertinent parts are

      [0x00007f7061a16090] wp_remote_post() /srv/users/serverpilot/apps/rattleandyum/public/wp-content/plugins/wp-smush-pro/lib/class-wp-smush.php:490
      [0x00007f7061a15f20] _post() /srv/users/serverpilot/apps/rattleandyum/public/wp-content/plugins/wp-smush-pro/lib/class-wp-smush.php:134
      [0x00007f7061a15de0] do_smushit() /srv/users/serverpilot/apps/rattleandyum/public/wp-content/plugins/wp-smush-pro/lib/class-wp-smush.php:315
      [0x00007f7061a15b90] resize_from_meta_data() /srv/users/serverpilot/apps/rattleandyum/public/wp-content/plugins/wp-smush-pro/lib/class-wp-smush.php:443

      Smush Pro is currently disabled on the site.

  • Umesh Kumar
    • Code Wrangler

    Hey @webworth,

    Apologies for not responding earlier.

    From the first look at the log, it appears that the theme is generating images on every page load, which in turns calls the filter "wp_update_attachment_metadata", which is being used by Smush to optimise the images. This should be the case, only when you are logged in, and checking the front-end of website.

    If you turn off the Smush images on upload option, you should be fine with the page load time.

    Although if theme is really generating images on every page load, then it might be a big issue, but to confirm that, I'd have to debug it further, and since it's a paid theme, I'd need your help to do that.

    If you have a staging website, or if you could please create one and send the WordPress admin and FTP credentials through our contact form.

    You can go to:
    On the contact form, select "I have a different question"

    Can you please send in:
    - In the subject field add "Attn: Umesh Kumar"
    - Link back to this thread
    Include WordPress administrator login
    - Include FTP
    - Include any relevant URLS for your site

    this ensures it comes through and gets assigned to me.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.