• Resolved Rafa? Gicgier

    (@gicolek)


    Hello,

    First of all I have to say I really love this plugin and I can’t understand some of the negative reviews posted here. Apparently people are not going through the detailed guidelines you have posted all over the place.

    Needless to say I have a problem which occurred to me for the first time and since I’m not a server side specialist I’d love to see your input.

    I’ve solved all of the errors that have been put inside the error.log that might’ve caused the issue, and now, without any kind of errors I’m still getting some outrageously long image generation times:


    www-data
    EWWW IO version: 293.0
    WP version: 4.5.2
    PHP version: 50622
    ewww_image_optimizer_gallery_support()
    ewww_image_optimizer_admin_init()
    ewww_image_optimizer_init()
    ewww_image_optimizer_cloud_init()
    ewww_image_optimizer_exec_init()
    ewww_image_optimizer_cron_setup()
    ewww_image_optimizer_tool_init()
    ewww_image_optimizer_install_tools()
    Checking/Installing tools in /var/www/discoverslots/wp-content/ewww/
    wp-content/ewww permissions: 0755
    ewww_image_optimizer_install_paths()
    CPU architecture: x86_64
    generated paths:
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/jpegtran-linux
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/optipng-linux
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/gifsicle-linux
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/pngquant-linux
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/cwebp-linux
    /var/www/discoverslots/wp-content/ewww/jpegtran
    /var/www/discoverslots/wp-content/ewww/optipng
    /var/www/discoverslots/wp-content/ewww/gifsicle
    /var/www/discoverslots/wp-content/ewww/pngquant
    /var/www/discoverslots/wp-content/ewww/cwebp
    ewww_image_optimizer_skip_tools()
    enabled: jpegtran
    enabled: optipng
    enabled: gifsicle
    Linux/UNIX style OS, checking permissions
    ewww_image_optimizer_check_permissions()
    permissions for /var/www/discoverslots/wp-content/ewww/jpegtran: 0755
    permissions ok
    ewww_image_optimizer_check_permissions()
    permissions for /var/www/discoverslots/wp-content/ewww/gifsicle: 0755
    permissions ok
    ewww_image_optimizer_check_permissions()
    permissions for /var/www/discoverslots/wp-content/ewww/optipng: 0755
    permissions ok
    ewww_image_optimizer_settings_script()
    ewww_image_optimizer_bulk_script()
    ewww_image_optimizer_aux_images_script()
    ewww_image_optimizer_webp_script()
    ewww_image_optimizer_notice_utils()
    ewww_image_optimizer_exec_check()
    disable_functions: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
    suhosin_blacklist:
    ewww_image_optimizer_safemode_check()
    safe_mode =
    ewww_image_optimizer_skip_tools()
    enabled: jpegtran
    enabled: optipng
    enabled: gifsicle
    ewww_image_optimizer_path_check()
    ewww_image_optimizer_find_nix_binary()
    found /var/www/discoverslots/wp-content/ewww/jpegtran, testing...
    ewww_image_optimizer_md5check()
    /var/www/discoverslots/wp-content/ewww/jpegtran: 21d8046e07cb298dfd2f3b1e321c67c378a4d35fa8adc3521acc42b5b8088d64
    checksum verified, binary is intact
    ewww_image_optimizer_mimetype()
    testing mimetype: /var/www/discoverslots/wp-content/ewww/jpegtran
    finfo_file: application/x-executable
    ewww_image_optimizer_tool_found()
    testing case: j at /var/www/discoverslots/wp-content/ewww/jpegtran
    /var/www/discoverslots/wp-content/ewww/jpegtran: Independent JPEG Group's JPEGTRAN, version 9b 17-Jan-2016
    optimizer found
    ewww_image_optimizer_find_nix_binary()
    found /var/www/discoverslots/wp-content/ewww/optipng, testing...
    ewww_image_optimizer_md5check()
    /var/www/discoverslots/wp-content/ewww/optipng: 853ca5936a2dd92a17b3518fd55db6be35e1b2bebfabca3949c34700072e08b8
    checksum verified, binary is intact
    ewww_image_optimizer_mimetype()
    testing mimetype: /var/www/discoverslots/wp-content/ewww/optipng
    finfo_file: application/x-executable
    ewww_image_optimizer_tool_found()
    testing case: o at /var/www/discoverslots/wp-content/ewww/optipng
    /var/www/discoverslots/wp-content/ewww/optipng: OptiPNG version 0.7.6
    optimizer found
    ewww_image_optimizer_find_nix_binary()
    found /var/www/discoverslots/wp-content/ewww/gifsicle, testing...
    ewww_image_optimizer_md5check()
    /var/www/discoverslots/wp-content/ewww/gifsicle: deea065a91c8429edecf42ccef78636065f7ae0dad867df7696128c6711e4735
    checksum verified, binary is intact
    ewww_image_optimizer_mimetype()
    testing mimetype: /var/www/discoverslots/wp-content/ewww/gifsicle
    finfo_file: application/x-executable
    ewww_image_optimizer_tool_found()
    testing case: g at /var/www/discoverslots/wp-content/ewww/gifsicle
    /var/www/discoverslots/wp-content/ewww/gifsicle: LCDF Gifsicle 1.87
    optimizer found
    using: /var/www/discoverslots/wp-content/ewww/jpegtran
    using: /var/www/discoverslots/wp-content/ewww/optipng
    using: /var/www/discoverslots/wp-content/ewww/gifsicle
    defining EWWW_IMAGE_OPTIMIZER_JPEGTRAN
    defining EWWW_IMAGE_OPTIMIZER_OPTIPNG
    defining EWWW_IMAGE_OPTIMIZER_GIFSICLE
    defining EWWW_IMAGE_OPTIMIZER_PNGOUT
    defining EWWW_IMAGE_OPTIMIZER_PNGQUANT
    defining EWWW_IMAGE_OPTIMIZER_WEBP
    ewww_image_optimizer_options()
    ABSPATH: /var/www/discoverslots/
    home url: https://www.staging.discoverslots.com
    site url: https://www.staging.discoverslots.com
    ewww_image_optimizer_savings()
    querying savings for single site
    query to be performed: SELECT SUM(orig_size-image_size) FROM wpa5_ewwwio_images
    savings found: 107858
    ewww_image_optimizer_install_paths()
    CPU architecture: x86_64
    generated paths:
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/jpegtran-linux
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/optipng-linux
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/gifsicle-linux
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/pngquant-linux
    /var/www/discoverslots/wp-content/plugins/ewww-image-optimizer/binaries/cwebp-linux
    /var/www/discoverslots/wp-content/ewww/jpegtran
    /var/www/discoverslots/wp-content/ewww/optipng
    /var/www/discoverslots/wp-content/ewww/gifsicle
    /var/www/discoverslots/wp-content/ewww/pngquant
    /var/www/discoverslots/wp-content/ewww/cwebp
    ewww_image_optimizer_skip_tools()
    enabled: jpegtran
    enabled: optipng
    enabled: gifsicle
    ewww_image_optimizer_tool_found()
    testing case: j at /var/www/discoverslots/wp-content/ewww/jpegtran
    /var/www/discoverslots/wp-content/ewww/jpegtran: Independent JPEG Group's JPEGTRAN, version 9b 17-Jan-2016
    optimizer found
    ewww_image_optimizer_tool_found()
    testing case: o at /var/www/discoverslots/wp-content/ewww/optipng
    /var/www/discoverslots/wp-content/ewww/optipng: OptiPNG version 0.7.6
    optimizer found
    ewww_image_optimizer_tool_found()
    testing case: g at /var/www/discoverslots/wp-content/ewww/gifsicle
    /var/www/discoverslots/wp-content/ewww/gifsicle: LCDF Gifsicle 1.87
    optimizer found
    ewww_image_optimizer_safemode_check()
    safe_mode =
    ewww_image_optimizer_exec_check()
    disable_functions: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
    suhosin_blacklist:
    ewww_image_optimizer_gd_support()
    GD found, supports:
    GD Version: 2.1.1
    FreeType Support: 1
    FreeType Linkage: with freetype
    T1Lib Support:
    GIF Read Support: 1
    GIF Create Support: 1
    JPEG Support: 1
    PNG Support: 1
    WBMP Support: 1
    XPM Support: 1
    XBM Support: 1
    WebP Support: 1
    JIS-mapped Japanese Font Support:
    ewww_image_optimizer_gmagick_support()
    ewww_image_optimizer_imagick_support()
    ewww_image_optimizer_find_nix_binary()
    ewww_image_optimizer_tool_found()
    testing case: i at convert
    convert: sh: 1: convert: not found
    tool not found
    ewww_image_optimizer_tool_found()
    testing case: i at /usr/bin/convert
    /usr/bin/convert: sh: 1: /usr/bin/convert: not found
    tool not found
    ewww_image_optimizer_tool_found()
    testing case: i at /usr/local/bin/convert
    /usr/local/bin/convert: sh: 1: /usr/local/bin/convert: not found
    tool not found
    ewww_image_optimizer_tool_found()
    testing case: i at /usr/gnu/bin/convert
    /usr/gnu/bin/convert: sh: 1: /usr/gnu/bin/convert: not found
    tool not found
    ewww_image_optimizer_tool_found()
    testing case: i at /usr/syno/bin/convert
    /usr/syno/bin/convert: sh: 1: /usr/syno/bin/convert: not found
    tool not found
    ewww_image_optimizer_find_nix_binary()
    ewww_image_optimizer_tool_found()
    testing case: n at nice
    nice: 0
    nice found
    remove metadata: on
    jpg level: 10
    png level: 10
    gif level: 10
    pdf level: 0
    bulk delay: 0
    optipng level: 2
    pngout disabled: yes
    pngout level: 3
    ewww_image_optimizer_jpg_quality()
    parallel optimization: on
    scheduled optimization: off
    include media library: off
    max media dimensions: 0 x 0
    max other dimensions: 0 x 0
    resize existing images: off
    ewww_image_optimizer_get_image_sizes()
    Array ( [0] => thumbnail [1] => medium [2] => medium_large [3] => large )
    Array ( [thumbnail] => Array ( [width] => 150 [height] => 150 ) [medium] => Array ( [width] => 300 [height] => 300 ) [medium_large] => Array ( [width] => 768 [height] => 9999 ) [large] => Array ( [width] => 1024 [height] => 1024 ) )
    disabled resizes:
    thumbnail: optimization=enabled creation=enabled
    medium: optimization=enabled creation=enabled
    medium_large: optimization=enabled creation=enabled
    large: optimization=enabled creation=enabled
    skip images smaller than: 0 bytes
    skip PNG images larger than: 300000 bytes
    exclude originals from lossy: off
    exclude originals from metadata removal: off
    use system binaries: no
    webp conversion: off
    alt webp rewriting: on
    jpg2png: off
    ewww_image_optimizer_jpg_background()
    ewww_image_optimizer_jpg_background()
    png2jpg: off
    gif2png: off
    max_execution_time: 30

    The plugin status is All Clear:


    Total Savings: 105.33 kB
    If updated versions are available below, you may need to enable write permission on the /var/www/discoverslots/wp-content/ewww/ folder to use the automatic installs.
    *Updates are optional, but may contain increased optimization or security patches

    jpegtran: Installed?version: Independent JPEG Group's JPEGTRAN, version 9b 17-Jan-2016
    optipng: Installed?version: OptiPNG version 0.7.6
    pngout: Not installed, enable in Advanced Settings
    gifsicle: Installed?version: LCDF Gifsicle 1.87
    safe mode: Off??exec(): Enabled??
    Graphics libraries - only need one, used for conversion, not optimization
    GD: Installed??Gmagick: Missing??Imagick: Missing??Imagemagick 'convert': Missing
    Only need one of these:
    finfo: Installed??getimagesize(): Installed??mime_content_type(): Installed

    Can you post any suggestion what could be improved or why is it slow? There aren’t much plugins installed and even disabling them doesn’t help.

    https://www.ads-software.com/plugins/ewww-image-optimizer/

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author nosilver4u

    (@nosilver4u)

    Hmmm, so when you say it is “slow”, can you clarify which part of the process is slow? Is the upload slow itself, or the background processing takes a while before they show as optimized in the Media Library? Or are you doing a bulk optimize and the images are taking a really long time there?

    Thread Starter Rafa? Gicgier

    (@gicolek)

    Either of the options.

    The ajax request to either bulk optimize or manually optimize each from Unoptimized Images section takes forever.

    Needless to say even after it’s gone through the optimization process under Bulk Optimize the exact same image is listed as not processed under Unoptimized Images section.

    Plugin Author nosilver4u

    (@nosilver4u)

    That sounds like it is just timing out. 2 things to look into:
    1. What type of images are timing out (provide links if possible)?
    2. Can you increase the php max execution time longer than 30 seconds?

    Thread Starter Rafa? Gicgier

    (@gicolek)

    Hey,

    1. The images that timeout are both .png and .jpg files which are lower in size than 90 kb for instance: https://dl.dropboxusercontent.com/u/4374990/Wizard_of_gems.jpg

    2. I’ll do another test with execution time increased tomorrow.

    Thank you for a quick turnaround ??

    Plugin Author nosilver4u

    (@nosilver4u)

    Also wanted to mention, try turning off Alt WebP Rewriting and see if that helps at all.

    Plugin Author nosilver4u

    (@nosilver4u)

    One last note if you haven’t solved it is that parallel optimization can give this sort of behavior if your server denies (or drops) some of the async requests.

    Thread Starter Rafa? Gicgier

    (@gicolek)

    Hey,

    Actually I was having a holiday and didn’t manage to get in touch with the sys admin ?? I’m hoping to have this solved this week. Thank you for the insight I’ll definitely get back to you once the issue was found!

    Thread Starter Rafa? Gicgier

    (@gicolek)

    Hello Sir,

    This has been fixed and the issue has been different. The NGINX didn’t have a proper etc/hosts configuration so the address wasn’t referenced by any IP hence the AJAX call the plugin was doing was taking forever.

    strace -s 1024 -f -p 27551
    sendto(13, "<190>Aug 17 19:56:12 discoverslots-staging-php-app1 nginx: 149.156.208.41 - - [17/Aug/2016:19:56:12 +0000] \"POST /wp-admin/admin-ajax.php HTTP/1.1\" 200 34 \"https://www.staging.discoverslots.com/wp-admin/admin.php?page=w3tc_minify\" \"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:44.0) Gecko/20100101 Firefox/44.0\" \"-\" <msec=1471463772.099|connection=228|connection_requests=7|http_host=www.staging.discoverslots.com|millis=0.151>", 424, 0, NULL, 0) = 424
    
    root@discoverslots-staging-php-app1:/root/strace# telnet www.staging.discoverslots.com 80
    Trying 52.208.143.126...
    
    www.staging.discoverslots.com. 262 IN    A    52.208.143.126
    
    No IP on the server.

    Not sure if there’s a workaround for such a situation on your side.

    Regards,
    Rafal

    Plugin Author nosilver4u

    (@nosilver4u)

    Curious, was it entirely missing, or was it present but incorrect in the /etc/hosts file?
    If it was missing, the server should fall back to DNS, and if it can’t resolve it’s own address via DNS, then you have other problems there. Or perhaps it was trying to connect via the localhost address (127.0.0.1) before the hosts entry was made and nginx may have been configured to only listen on the public IP, rejecting the connection to 127.0.0.1.

    At any rate, glad your server admin was able to find out the actual fix. Keep him well paid ??

    Thread Starter Rafa? Gicgier

    (@gicolek)

    From what I know it was entirely missing. I’m not that proficient with the server side configuration so really can’t tell ??

    Needless to say it’s an outside job so we’ve jumped in the middle of the project hence yeah there may be a lot of different issues still persisting.

    Thank yoU!

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Resizing Images takes around 569 seconds’ is closed to new replies.