Title: Getting errors while optimizing
Last modified: August 20, 2016

---

# Getting errors while optimizing

 *  Resolved [webguru4u](https://wordpress.org/support/users/webguru4u/)
 * (@webguru4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/)
 * Hi
 * I have a huge blog with over 10,000 images. I am optimizing them manually in 
   media library- 400 at a time. It optimized half of the images successfully but
   when I am at page 15 of media library and all subsequent pages, it shows this
   error in the “image optimizer” column-
 * _[ Moderator Note: [Please post code](http://codex.wordpress.org/Forum_Welcome#Posting_Code)
   or markup snippets between backticks or use the code button or log data. ]_
 *     ```
       ===================
       Warning: getimagesize(/home/xxxx/public_html/mysite.com/wp-content/uploads//var/www/vhosts/mysite.com/httpdocs/wp-content/uploads/2007/08/imagename.jpg) [function.getimagesize]: failed to open stream: No such file or directory in /home/xxxx/public_html/mysite.com/wp-content/plugins/ewww-image-optimizer/ewww-image-optimizer.php on line 1890
   
       Warning: filesize() [function.filesize]: stat failed for /home/xxxx/public_html/mysite.com/wp-content/uploads//var/www/vhosts/mysite.com/httpdocs/wp-content/uploads/2007/08/imagename.jpg in /home/xxxx/public_html/mysite.com/wp-content/plugins/ewww-image-optimizer/ewww-image-optimizer.php on line 1904
       Unsupported file type
       ===================
   
       When I still try to optimize them by bulk selecting the images, it returns this error for each image-
   
       ===================
       Optimized image: /var/www/vhosts/mysite.com/httpdocs/wp-content/uploads/2007/08/imagename.jpg
       Full size – Could not find /home/xxxx/public_html/mysite.com/wp-content/uploads//var/www/vhosts/mysite.com/httpdocs/wp-content/uploads/2007/08/imagename.jpg
       Elapsed: 0.2 seconds
       ===================
       ```
   
 * Please let me know whats the problem. Thanks.
 * [http://wordpress.org/extend/plugins/ewww-image-optimizer/](http://wordpress.org/extend/plugins/ewww-image-optimizer/)

Viewing 15 replies - 1 through 15 (of 16 total)

1 [2](https://wordpress.org/support/topic/getting-errors-while-optimizing/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/getting-errors-while-optimizing/page/2/?output_format=md)

 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575472)
 * somewhere in there, it is appending the path to what wordpress says is your uploads
   folder. I’m guessing that at some point you changed the upload path, and it is
   confusing the plugin, because it doesn’t realize that wordpress is giving the
   full path already. I’m sure there is someway to detect that, but not quite sure
   how.
 * I’ll have to give it some thought and see what I can come up with.
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575478)
 * The dev version has a fix for this (hopefully). Try it out and let me know if
   that fixes it. If you are uploading via ftp, you can skip all the binaries, or
   make sure to transfer in BIN (binary) mode.
 *  Thread Starter [webguru4u](https://wordpress.org/support/users/webguru4u/)
 * (@webguru4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575483)
 * Thanks. I installed the dev version but it didn’t changed anything. I am still
   getting the same errors in media library like above.
 * Also, with dev version some new errors occurred on the settings page. It says
   few files are missing, but I checked and they are present. Here is the screenshot
   of settings page-
 * > [View post on imgur.com](https://imgur.com/R6kj8sF)
 * Thanks again!
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575497)
 * Hmm, I wonder if the mime_content_type() function isn’t working quite right. 
   I’ll have to double-check that, since I switched to using php to validate the
   mime-types of the binaries.
 * Can you also post the md5sum info from the debug area, so I can verify that your
   binaries are intact?
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575499)
 * ok, scratch the previous post. I’ve tweaked the mimetype detection stuff so it
   should be working properly again.
 * If it isn’t, you can use the new debugging functionality. There is a checkbox
   on the settings page to turn it on. Once you’ve saved the setting, you will see
   a rather large debug log section near the bottom. If you don’t feel comfortable
   posting all that info (or taking the time to black out everything again), you
   can e-mail the info via: [http://www.shanebishop.net/contact-me/](http://www.shanebishop.net/contact-me/)
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575500)
 * oh, and if the bulk optimize still isn’t working right (you may want to turn 
   debugging back off when you test it), please let me know what errors/information
   it is giving now.
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575501)
 * Any progress, did I get it fixed this time? I tried to replicate your issue as
   best I could, and it worked for me, but I want to make sure that we actually 
   fixed your problem.
 *  Thread Starter [webguru4u](https://wordpress.org/support/users/webguru4u/)
 * (@webguru4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575502)
 * Ok, I just checked it again by enabling the debug function. Here are the results-
 * _[ Moderator Note: [Please post code](http://codex.wordpress.org/Forum_Welcome#Posting_Code)
   or markup snippets between backticks or use the code button or log data. ]_
 *     ```
       ============
       Checking/Installing tools in /home/xxx/public_html/mysite.com/wp-content/ewww/
       wp-content/ewww permissions: 0755
       generated paths:
       /home/xxx/public_html/mysite.com/wp-content/plugins/ewww-image-optimizer/jpegtran-linux64
       /home/xxx/public_html/mysite.com/wp-content/plugins/ewww-image-optimizer/optipng-linux
       /home/xxx/public_html/mysite.com/wp-content/plugins/ewww-image-optimizer/gifsicle-linux
       /home/xxx/public_html/mysite.com/wp-content/ewww/jpegtran
       /home/xxx/public_html/mysite.com/wp-content/ewww/optipng
       /home/xxx/public_html/mysite.com/wp-content/ewww/gifsicle
       Linux/UNIX style OS, checking permissions
       found /home/xxx/public_html/mysite.com/wp-content/ewww/jpegtran, testing...
       /home/xxx/public_html/mysite.com/wp-content/ewww/jpegtran: 4da4092708650ceb79df19d528e7956b
       testing mimetype: /home/xxx/public_html/mysite.com/wp-content/ewww/jpegtran
       mime_content_type: text/plain
       jpegtran: libjpeg-turbo version 1.2.1 (build 20130221)
       found /home/xxx/public_html/mysite.com/wp-content/ewww/optipng, testing...
       /home/xxx/public_html/mysite.com/wp-content/ewww/optipng: 4eb91937291ce5038d0c68f5f2edbcfd
       testing mimetype: /home/xxx/public_html/mysite.com/wp-content/ewww/optipng
       mime_content_type: text/plain
       found /home/xxx/public_html/mysite.com/wp-content/ewww/gifsicle, testing...
       /home/xxx/public_html/mysite.com/wp-content/ewww/gifsicle: 44273fad7b3fd1145bfcf35189648f66
       testing mimetype: /home/xxx/public_html/mysite.com/wp-content/ewww/gifsicle
       mime_content_type: text/plain
       pngout-static: sh: pngout-static: command not found
       pngout: sh: pngout: command not found
       /usr/bin/pngout-static: sh: /usr/bin/pngout-static: No such file or directory
       /usr/bin/pngout: sh: /usr/bin/pngout: No such file or directory
       /usr/local/bin/pngout-static: sh: /usr/local/bin/pngout-static: No such file or directory
       /usr/local/bin/pngout: sh: /usr/local/bin/pngout: No such file or directory
       using: jpegtran
       generated paths:
       /home/xxx/public_html/mysite.com/wp-content/plugins/ewww-image-optimizer/jpegtran-linux64
       /home/xxx/public_html/mysite.com/wp-content/plugins/ewww-image-optimizer/optipng-linux
       /home/xxx/public_html/mysite.com/wp-content/plugins/ewww-image-optimizer/gifsicle-linux
       /home/xxx/public_html/mysite.com/wp-content/ewww/jpegtran
       /home/xxx/public_html/mysite.com/wp-content/ewww/optipng
       /home/xxx/public_html/mysite.com/wp-content/ewww/gifsicle
       jpegtran: libjpeg-turbo version 1.2.1 (build 20130221)
       GD found, supports:
       GD Version: bundled (2.0.34 compatible)
       FreeType Support: 1
       FreeType Linkage: with freetype
       T1Lib Support:
       GIF Read Support: 1
       GIF Create Support: 1
       JPG Support: 1
       PNG Support: 1
       WBMP Support: 1
       XPM Support: 1
       XBM Support: 1
       JIS-mapped Japanese Font Support:
       convert: Version: ImageMagick 6.7.6-8 2012-05-02 Q16 http://www.imagemagick.org
       disabled functions: dl
       /usr/bin/file: magic file from /etc/magic:/usr/share/misc/magic
       /usr/bin/nice: sh: /usr/bin/nice: No such file or directory
       nice: 15
       tar: tar (GNU tar) 1.23
       user: xxx
       operating environment: Linux 3.2.38 #11 SMP Sat Feb 16 20:42:35 CST 2013 x86_64
       ==============
       ```
   
 * The bulk optimizer is still not working. Thanks for your efforts.
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575513)
 * aha, so the mimetype functions in php are broken in your system, since they are
   detecting the executables as text/plain…
    I’ll rework the detection a bit to 
   fail-over better.
 * Are you seeing the same errors on the bulk, or just having trouble because I 
   broke the tool detection?
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575514)
 * Ok, it should fall-back properly to the ‘file’ command now. If the bulk still
   is busted, turn on debugging, and post one of the sections that gets generated
   when it fails to optimize an image.
 *  Thread Starter [webguru4u](https://wordpress.org/support/users/webguru4u/)
 * (@webguru4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575515)
 * Its still the same errors, no change.
 * Debug- same error as above.
    Bulk optimize- same error as above.
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575516)
 * The bulk optimize should have extra information in it as well, that’s what I 
   was hoping to see. Not sure that it will help a ton, but there might be a clue.
 * Anyway, I figured out the problem with the binary checks (or at least another
   one), and tested it with similar settings to what your debug showed, and it seems
   to be working now for me.
 * You can try the latest dev version to see if that fixes the status on the tools.
   I’m going to add in some extra debug information to try and pinpoint the issue
   with those old images though.
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575517)
 * Ok, the new debug information should help me figure out what is going on, and
   better replicate your setup. I just uploaded the latest code a couple minutes
   ago. Install that, and then turn on debugging, and then try to optimize one of
   the images in question. Once it attempts an image, copy the (rather large) block
   of text in the yellow section. There could be up to 200+ lines, so it may be 
   advisable to use something like [http://pastebin.com/](http://pastebin.com/),
   that will also allow you to make your paste unlisted. You can even create an 
   account, and delete the pastebin snippet later on.
 * Alternatively, you can submit the information directly via e-mail: shanebishop
   with a gmail dot you-know-what at the end.
 *  Plugin Author [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * (@nosilver4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575518)
 * One more thing with the above. If you are still having trouble, please e-mail
   screenshots of the media library and the bulk optimize to the address above.
 *  Thread Starter [webguru4u](https://wordpress.org/support/users/webguru4u/)
 * (@webguru4u)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/#post-3575519)
 * I just sent you an email with all the details. Thanks.

Viewing 15 replies - 1 through 15 (of 16 total)

1 [2](https://wordpress.org/support/topic/getting-errors-while-optimizing/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/getting-errors-while-optimizing/page/2/?output_format=md)

The topic ‘Getting errors while optimizing’ is closed to new replies.

 * ![](https://ps.w.org/ewww-image-optimizer/assets/icon-256x256.png?rev=1582276)
 * [EWWW Image Optimizer](https://wordpress.org/plugins/ewww-image-optimizer/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/ewww-image-optimizer/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/ewww-image-optimizer/)
 * [Active Topics](https://wordpress.org/support/plugin/ewww-image-optimizer/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/ewww-image-optimizer/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/ewww-image-optimizer/reviews/)

## Tags

 * [EWWW](https://wordpress.org/support/topic-tag/ewww/)

 * 16 replies
 * 2 participants
 * Last reply from: [Shane Bishop](https://wordpress.org/support/users/nosilver4u/)
 * Last activity: [13 years, 1 month ago](https://wordpress.org/support/topic/getting-errors-while-optimizing/page/2/#post-3575524)
 * Status: resolved