Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Jul 16, 2009 @ 15:40
    Douglas Robar
    12

    [UPDATE] Fix to caching bug in 2.0.1

    ImageGen 2.0.1 has a bug in the caching system that may allow the 'cached' folders to grow and grow, wasting disk space and slowing site performance.

    I'm working on ImageGen 3 and the updated version has a number of fixes, including the important 'caching bug.' I don't want to wait to get this into users hands.

    NOTE
    If you use the ?text= parameter you may notice some small changes to the appearance of text images, as that area has seen a lot of work. If you do use ?text= you'll want to compare the images created by this updated version; you might need to modify your macros or css slightly to accommodate the changes in text handling. Otherwise, the update is fully backward compatible.

    TO UPDATE IMAGEGEN
    0. install ImageGen 2.0.1 normally
    1. download and expand the updated .zip file from ImageGen.2.2.1.38932.zip
    2. replace /bin/imagegen.dll
    3. replace /umbraco/imagegen.ashx
    4. delete all folders named 'cached' on your site

    cheers,
    doug.

  • Nico Lubbers 151 posts 174 karma points
    Jul 16, 2009 @ 20:53
    Nico Lubbers
    0

    JIIIIHAAAA !!!

    Thanx ! :-)

  • Dirk De Grave 4532 posts 5976 karma points MVP 3x admin
    Jul 16, 2009 @ 21:27
    Dirk De Grave
    0

    Ohh, you're making lots of clients soooo happy. Well done Doug!

     

    Cheers,

    /Dirk

  • Daniel.S 50 posts 135 karma points
    Jul 17, 2009 @ 07:59
    Daniel.S
    0

    Thanks Doug. Imagegen is an excellent and integral part of the Umbraco site-building toolkit IMO.

  • Robin Overgaard 33 posts 73 karma points
    Jul 24, 2009 @ 15:55
    Robin Overgaard
    0

    I get an object reference not set to an instance of an object, I am using TIFF based images, is that even compatible ?

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Jul 24, 2009 @ 16:49
    Douglas Robar
    0

    TIF is not officially supported (I haven't tested it extensively) but it should work and I've used it before. There are lots of types of tiff files (color depth, compression, byte order) and it may be that not every combination works properly.

    First things first... do you have any problem with jpg or png images? If not, then it is probably the combination of tiff file details that isn't compatible with ImageGen. If you re-save the tiff with different details. I believe 8-bit (rather than 16-bit), full color, rle or no compression, pc compatible byte format works.

    You might also start with a small image and then work up in filesize from there. As the filesize gets larger it takes longer and longer to process the image with ImageGen (the number of bytes grows quickly as image dimensions increase) and you might possibly be running out of memory if you're working with massive images?

    cheers,
    doug.

  • Robin Overgaard 33 posts 73 karma points
    Jul 24, 2009 @ 17:55
    Robin Overgaard
    0

    We are trying to make it easy for the user (seams that the user is somewhat "unsure" of how web and cms works).

    The ideer is to make it possible to upload on huge/highres image, and that will be made into a highres, lowres, preview and thumbnail version.

    I have no control over what formats the tiff gets saved as.

    Can this en up as a null reference ?.

    I am hoping that we can finde a sollution to this, because I am suppose to deliver this project today, but I cant get it done untill monday earliest, and there are different ways to achieve this, but preferable ImageGen should handle it all

    Best regards,

    Robin

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Jul 24, 2009 @ 18:23
    Douglas Robar
    0

    As I said, ImageGen does not officially support tiff format, though it should work.

    But perhaps the issue isn't related to the tiffs? Does ImageGen always give you a null reference exception, even for jpgs? Have you applied the patch for ImageGen 2.2? Are you running it on localhost?

    cheers,
    doug.

  • Robin Overgaard 33 posts 73 karma points
    Jul 24, 2009 @ 18:44
    Robin Overgaard
    0

    I am trying it out on jpeg's right now, I have also applied the patch, and I have not been able to get the class's working in the config file, even tho the registrationinfo is functioning.

  • Robin Overgaard 33 posts 73 karma points
    Jul 24, 2009 @ 18:54
    Robin Overgaard
    0

    I works in jpg's, I have also applied the patch, and I have not been able to get the class's working in the config file, even tho the registrationinfo is functioning.

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Jul 24, 2009 @ 19:07
    Douglas Robar
    0

    Okay, it's not a general ImageGen problem if it's working with jpgs. Two things remain to be sorted out... ImageGen Pro features not active and tiff files giving a null reference error.

    Be sure to check that you've got the Pro features enabled for your domain by calling http://mydomain.dk/umbraco/imagegen.ashx?version If the Pro features aren't enabled for your domain then you either need to double-check the web.config and /config/imagegen.config settings (see the documentation for ImageGen) or else you need to purchase a registration key for the domain you're using.

    If you can't figure it out, contact me through my website (www.percipientstudios.com) so we can sort out the issus with your web.config and /config/imagegen.config files. We can also to share a few tiffs that don't work and some that do.

    I'm off for the weekend but I'll check my mail periodically and we'll get this sorted out as soon as possible.

    cheers,
    doug.

  • Robin Overgaard 33 posts 73 karma points
    Jul 24, 2009 @ 19:25
    Robin Overgaard
    0

    I just checked that the pro features are turned on for the domain in question, but the classes dont work :/

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Jul 24, 2009 @ 22:18
    Douglas Robar
    0

    You'll have to give more information about your imagegen.config file and the parameters you're passing to ImageGen.ashx if we're going to get anywhere on resolving this. Classes are used all the time and are known to work, but they can sometimes be a bit difficult for people to set up properly. One thing to check... are you using the ImageBaseDir? If so, you might want to remove it to get started as that setting often confuses people.

    cheers,
    doug.

  • Robin Overgaard 33 posts 73 karma points
    Jul 24, 2009 @ 22:41
    Robin Overgaard
    0

    The config looks lige this

    <ImageGenConfiguration>
        <!-- SAMPLE IMAGEGEN.CONFIG FILE -->
        <Registration>
            <Key domain="##########">############################</Key>
        </Registration>

        <Class Name="default" OverridesQueryString="true">
            <ImageBaseDir>/media</ImageBaseDir>
            <AllowUpsizing>false</AllowUpsizing>
            <MaxHeight>800</MaxHeight>
            <MaxWidth>800</MaxWidth>
            <!--<OverlayImage>watermark.png</OverlayImage>-->
        </Class>

        <Class Name="Thumbnail" OverridesQueryString="true">
            <InheritFromClass>default</InheritFromClass>
            <Width>166</Width>
            <Height>206</Height>
            <Constrain>true</Constrain>
        </Class>

        <Class Folder="/screenshots" OverridesQueryString="true">
            <Height>100</Height>
            <Border>2</Border>
        </Class>
    </ImageGenConfiguration>

     

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Jul 25, 2009 @ 13:03
    Douglas Robar
    0

    You're not providing enough information to make helping you easy. This would go much faster if you'd respond with more details so we could use real examples that work for your setup. Still... we'll do our best with the little we have to go on.

    Let's suppose you have two images in the /media folder, one a jpg and the other a tiff, but otherwise the images are the same. Let's further assume that you can bring up these images with the following urls: http://www.example.dk/media/sample.jpg and http://www.example.dk/media/sample.tif

    You'll have to adjust this according to your specific setup, but let's keep going with this example to understand how ImageGen should work and how the classes in the config file will change the behavior.

    If you do NOT have the Pro features enabled (remove the registration key from the imagegen.config file temporarily), or if you have the Pro features enabled please comment out all of the <Class ... /> information in the imagegen.config section, especially the 'default' class. With a clean imagegen.config file you would be able to resize the images with this querystring:

    http://www.example.dk/umbraco/imagegen.ashx?image=/media/sample.jpg&width=400

    Please try that. Does it work? If not, do not procede until you have the imagegen.config file clean of any class information and this call works.

     

    Now try it with one of your sample tif file (with the clean imagegen.config):

    http://www.example.dk/umbraco/imagegen.ashx?image=/media/sample.tif&width=400

    Does this work, or do you get an error? If you get an error, please email me the tif file that creates the error so that I can debug it.

     

    Even if the tif file gives an error, we can still move on to making the classes work with supported filetypes such as jpgs.

    Restore the imagegen.config file to that which you showed above.

    BUT... comment out or remove the <ImageBaseDir>/media</ImageBaseDir> line. This is very important!

     

    http://www.example.dk/umbraco/imagegen.ashx?image=/media/sample.jpg&width=400 should still work.

     

    Now try:

    http://www.example.dk/umbraco/imagegen.ashx?image=/media/sample.jpg&class=Thumbnail

    This should return a smaller version of the sample image. Does it?

    If so, your configuration is correct and the classes are functioning properly and the ImageGen documentation can explain more about how to set up additional classes, the effect of a class named 'default', and the way that the <ImageBaseDir> property will change the url you call.

    If the thumbnail image is not shown, please explain what happened at each step of these instructions.

     

    I will emphasize that setting up classes, particularly with the <ImageBaseDir> property, is very powerful but does require careful attention to details. For instance, if you set the <ImageBaseDir> to /media then the sample url would change to:

    http://www.example.dk/umbraco/imagegen.ashx?image=sample.jpg&class=Thumbnail

    And you would ONLY be able to reference images contained somewhere within the /media folder or its sub-folders. The documentation discusses this in further detail.

     

    cheers,
    doug.

  • Ruth White 5 posts 23 karma points
    Jul 29, 2009 @ 18:20
    Ruth White
    0

    Hi Doug,

    I got ImageGen working to resize an image and output a thumbnail which was great. I then tried to fix the caching bug and so replaced the .dll and .ashx files. I deleted the 'Cached' folders below the relevant media nodes. This has stopped the thumbnails displaying.

    I have ImageGen without the bug fix installed on one website and http://localhost/umbraco/ImageGen.ashx?text=test displays a picture showing 'test'.

    On the website with the bug fix http://localhost:9678/umbraco/ImageGen.ashx?text=test returns the error: Value cannot be null. Parameter name: value

    I am running IIS version 6.0, SQL Server 2008, Umbraco v 4.0.2.1 for both websites.

    Is there something I have done wrong when implementing the bug fix? If you need any more information about the versions I am running etc please let me know.

     

    Thanks

    Ruth

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Jul 30, 2009 @ 02:54
    Douglas Robar
    0

    Hi, Ruth,

    Please see this post for details of how to resolve this issue
    http://our.umbraco.org/projects/imagegen/imagegen-bugs/3250-localhost-gives-%27Value-cannot-be-null%27-error

    cheers,
    doug.

  • Martin 17 posts 24 karma points
    Aug 12, 2009 @ 15:17
    Martin
    0

    This update apparently also fixes the issue about ImageGen sometimes locking files so they can not be overwritten/deleted etc.

    Thank you so much Doug :)

  • Martin 17 posts 24 karma points
    Aug 12, 2009 @ 17:10
    Martin
    0

    I discovered that, if I use the classname "_default" for a page then that page will be broken:

    Compiler Error Message: ASPNET: Make sure that the class defined in this code file matches the 'inherits' attribute, and that it extends the correct base class (e.g. Page or UserControl).

    Source Error:

    Line 2:  Imports System.Data.SqlClient
    Line 3:
    Line 4: Partial Class _default
    Line 5:
    Line 6: Inherits System.Web.UI.Page

    If I go back to version 2.0.1 of Imagegen then there is no problem.

    I have fixed the problem by changing the class name of the default.aspx page but this shouldn't be the solution as far as I think.

  • Tommy Poulsen 514 posts 708 karma points
    Oct 06, 2009 @ 11:56
    Tommy Poulsen
    1

    If anyone is interested I made a aspx-script for automatically removing the cached-folders in the media library. It's available here if anyone's interested. Use it at your own risk.

    >Tommy

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Oct 06, 2009 @ 12:07
    Douglas Robar
    0

    Really nice and useful tool, Tommy! Thanks for sharing.

    cheers,
    doug.

  • Dav 44 posts 69 karma points
    Jan 06, 2010 @ 09:35
    Dav
    0

    Thanks for fixing the caching bug and updating us even thou you didn't have to - really appreciate that sort of commitment to users getting the best tool around for resizing and generating text.

    We use ImageGen for generating headers with a non-standard web font (Adobe's Myriad). And we came across another bug(s) after installing the update you provided. It only happens rarely, on few systems. Does not seem to be dependent on the browser (Opera and Ff for now).

    ONE

    Page displays more-less the same, but a message appears above content:

    HTTP/1.1 200 OK Cache-Control: private Content-Type: text/html; 
    charset=utf-8 Server: Microsoft-IIS/7.0 X-AspNet-Version: 2.0.50727 X-Powered-By: ASP.NET
    Date: Tue, 05 Jan 2010 23:32:47 GMT Content-Length: 8860

    Whenever this happens, conent encoding is also broken, ie. instead of Polish characters (ążćł) the famous question marks appear.

    TWO

    This is more serious; no content is displayed but you get a 'trace' page - the one with black bars. At the top: HTTP/1.1 302 (and so on), and a big link "Object moved to here".

    Would be great to know if anyone else is experiencing the issues above.

  • Dav 44 posts 69 karma points
    Jan 19, 2010 @ 09:13
    Dav
    0

    Anyone experiencing the above issue? Perhaps it's something to do with configuration that we've missed?

  • Matt Brailsford 2187 posts 10693 karma points MVP 6x c-trib
    Mar 08, 2010 @ 11:49
    Matt Brailsford
    0

    Whilst not the same issue as Dav, I too seem to be having a problem.

    When I install the DLL on the live server, no images display, and when i navigate to the URL directly I am getting Parameter is not valid.

    I currently have it setup as so that I pass the text paramter, and use the class feature to define everything else. With trial an error, it looks as though it's a problem with the font declaration. I am not using a standard font, so have it set to point to a ttf in /fonts/myfont.ttf. Removing the font declaration displays an image, adding it back displays the error. However, Images display fine localy.

    Anbody got any ideas?

    Many thanks

    Matt

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 08, 2010 @ 12:05
    Douglas Robar
    0

    "Parameter is not valid" is probably related to the font file. There are a few situations that might cause such an error. Typically, the file can't be read (it isn't there or can't be read) or else the font is using postscript outlines rather than truetype outlines (only truetype outlines are supported).

    0. As a test, copy a font such as Verdana into the /fonts folder and try it (/fonts/verdana.ttf). If it works the problem has to do with your font file.

    1. Please verify that the /fonts/myfont.ttf file exists on your site and that it is readable by the site's application pool owner.

    2. Please check that the font you're using has TrueType outlines rather than Postscript outlines. You can do this with the Microsoft Font Properties extension (http://www.microsoft.com/typography/truetypeproperty21.mspx). If your font is using postscript outlines you may be able to find a truetype outline version or convert the font using an online or downloadable tool.

    cheers,
    doug.

  • Matt Brailsford 2187 posts 10693 karma points MVP 6x c-trib
    Mar 08, 2010 @ 15:22
    Matt Brailsford
    0

    Hi Doug,

    Ok, I double checked permissions and they are fine, with the app pool user having full control. I tried it with a different font (comic sans) and thet came up with the same "Parameter is not valid" message. Again, the weird thing is that it works with the old DLL.

    Any other thoughts?

    Many thanks

    Matt

  • Matt Brailsford 2187 posts 10693 karma points MVP 6x c-trib
    Mar 08, 2010 @ 15:27
    Matt Brailsford
    0

    Sorry, just a little more detail. Comic sans didn't work, if i copied the font int my fonts folder and set the font property to /fonts/comic.ttf, however it does work if i reference the installed version "Comic Sans MS"

    Matt

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 17, 2010 @ 23:57
    Stefan Kip
    0

    Our server was down every now and then because of extreme RAM usage by two of our IIS websites.

    I finally tracked down the problem tonight and it was because of ImageGen. The cache folder existed of 44.000 files, total 80GB!!!!!!!!!!!!!!
    The weird thing is, I'm using the fix. If I request /umbraco/ImageGen.ashx?version it says:

    ImageGen version 2.2.1.38932

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 18, 2010 @ 10:42
    Douglas Robar
    1

    There are a few things you can do to get to the bottom of this:

    1. First things first... delete all the 'cached' folders and reclaim your disk space.

    2. Then watch for cache growth and duplicate cached images. Do you see any pattern to redundant images, or is every image request slightly different than those before such that you get few hits for the same image and resizing parameters?

    3. Do not use the &nocache=true flag on a production site (see docs for full details)

    Note:
    80GB of cache images for 44,000 files means the average filesize is 1.8MB each. If these are jpg's with decent compression then your source image may be quite large. This isn't a problem for ImageGen but it does require a lot of cpu/memory to resize a very large image because it has to decompress the image to its full size.

    For example: a 10 megapixel image (3648 x 2736) in 8bit full color requires 76MB of memory in its decompressed format. If you're using even larger images you'll need even larger amounts of availalbe memory. This is compounded if you have simultaneous requests for resized images, which is why ImageGen caches the result so that the next request for the same image simply reads from disk for performance.

    What ever is causing your site to generate so many cached images is probably the source of the problem rather than a memory leak in ImageGen itself.

    cheers,
    doug.

     

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 18, 2010 @ 10:44
    Douglas Robar
    0

    @Matt - sorry for the slow response. Is this still an outstanding issue? If not, please let us know how you resolved it. If it is an ongoing issue, please contact me through my website and maybe I can RDP to your server and figure it out for you.

    cheers,
    doug.

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 18, 2010 @ 10:51
    Douglas Robar
    0

    Let me do that math again... a 10 megapixel image is about 10MB uncompressed and probably around 2MB compressed as a jpg. If this is about how large your resized images are (on average), how large are the original images? ImageGen can handle it but your server will need the resources to process very large images.

    cheers,
    doug.

  • Matt Brailsford 2187 posts 10693 karma points MVP 6x c-trib
    Mar 18, 2010 @ 11:00
    Matt Brailsford
    0

    Hi Doug,

    I didn't find a solution to my problem, however we have moved the site to another server, and it is now running fine, so I can only guess it was something to do with my specific setup.

    Appologies I can't give you any more detail, but thanks for you help.

    Matt

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 18, 2010 @ 11:12
    Stefan Kip
    0

    Thanks for the quick reply Douglas, my findings:

    I cleared the cache yesterday of the problematic folder. This folder has 998 images, which are all 640 x 480 px and all below 100KB.
    The cache directory at this moment contains 540 items, because every image is used on multiple places in the website (with different width/height settings), so that's not really weird.

    I will keep an eye on the cache folder and post my findings here, ok? :)

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 18, 2010 @ 11:49
    Douglas Robar
    0

    Interesting. So it is only one folder that grows and grows? That is curious.

    Before the folder grows too large, would you mind zipping it up and emailing it to me so I can look at the images and especially the index.xml file? doug at my website's domain.

    cheers,
    doug.

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 18, 2010 @ 14:01
    Stefan Kip
    0

    Ofcourse Doug :) Not a problem at all.

    The cached folder contains 700 files now... Still growing, so I'm really curious what's going to happen!
    If every image is used with 3 different width/height combinations, eventually there should +/- 3000 cached images, I'll let you know as soon as I know more!

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 18, 2010 @ 14:21
    Stefan Kip
    0

    I just took a look at the xml btw and those images are used by two websites, with different width/height combinations...

    There are already images with 6 differently sized cache images, but that's normal behavior :) ImageGen should be able to handle cases like this right?

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 18, 2010 @ 16:22
    Douglas Robar
    0

    Should be okay. But tell me more about how you have two websites using the same images. There might be something in that scenario I don't account for.

    cheers,
    doug.

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 18, 2010 @ 16:24
    Douglas Robar
    0

    Just saw your twitter picture of the yellow-screen-of-death on the site... the error was caused by a full disk not by extreme RAM usage. The two things are very different. Please let me know which it was (memory or full disk) that caused your site to stop.

    The issue of massive number of files in the cached folder is what we're working on understanding and resolving but if there is also a memory issue that's another matter.

    cheers,
    doug.

  • sneakyckb 8 posts 28 karma points
    Mar 19, 2010 @ 10:21
    sneakyckb
    0

    Hi there,

    I am having the same caching issue and have applied the fix you mentioned and deleted all the cached folders, but now my images aren't showing up at all?  When I try to view the image it says 'Access to the path 'Cached' is denied.', have I done something wrong?

    Cheers,

    Cory

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 19, 2010 @ 10:37
    Stefan Kip
    0

    Hi Doug,

    I will explain the problems a bit more :)
    We're running two websites about cars (http://www.astonmartin.nl and http://www.kroymans.nl). Both sites show pictures of used cars (preowned). Those pictures get refreshed every night on our server from an external source.
    So both websites will show the pictures contained in, let's say, 'wwwroot/kroymans/shared/preowned/'. (contains 998 pictures, total size 63 MB, every picture is 640x480px).

    The problem was, that there were 44.000 cached items in the Cached folder (80GB), so the disk was full. But when one of these sites tried to request a cached image, the memory usage of the w3wp process accessing the file went through the roof (like 3.5 GB). Also trying to open the Cached folder in Windows Explorer let Explorer crash (obvious).

    The picture with the full hard disk was just for fun, it's not the problem we're discussing here ;-) I posted it online because I guess no-one has ever seen such an error before :)

    At this moment, there are 1740 items in the Cached folder, total size 12 MB). Hopefully the complete picture is a bit more clear now? :) Will keep you up to date!

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 19, 2010 @ 13:19
    Douglas Robar
    0

    @Cory - The message means what it says... ImageGen cannot create the cached folder because of a file permission issue.

    ImageGen creates a cached folder in whatever folder the &image= image resides in. For text-only images, the cached folder is created in the /data folder.

    Reset the file permissions on the /data folder and any folders with images you process with ImageGen to allow your site's application pool owner to create, read, update, and delete folders and files.

    cheers,
    doug.

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 19, 2010 @ 13:32
    Douglas Robar
    0

    @Stef (aka kipusoep) - Thanks for the more detailed response, that helps a lot.

    ImageGen is not designed to have sites process images in the same folder and I think that may be the root of the issue with each site updating the index.xml file from its own memory cache, ignorant of what the other site may be doing. In some situations it is possible that the index.xml file will lose information as one site updates it independantly of the other and images in the cached folder are no longer referenced in the index.xml file. In that case the image will need to be created again even though an identical image exists on the filesystem. If a reference to a cached file sn't in the index.xml or the website's memory cache it is as though the cached image file does not exist and must be created. Over time this could generate an unlimited number of duplicate files.

    There are two ways to resolve this.

    1. Store images on each site rather than sharing a common folder of images. Then each site is responsible for its own ImageGen processing.

    2. Purchase ImageGen Professional for one of your sites. Store the images on the other site (which can use the free version of ImageGen). Reference the iamges from the remote site with ImageGen Professional using a whitelist setting in the ImageGen.config file. Your image reference would look like:

    <img src="/umbraco/imagegen.asph?width=160&image=http://example.com/images/JagEType.jpg" />

    cheers,
    doug.

     

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 19, 2010 @ 13:37
    Stefan Kip
    0

    Doug,

    Thanks for the heads up. I will keep monitoring the Cached folder and if it seems to be happening again, I will store the images on each site. Thanks for the help! :)

  • sneakyckb 8 posts 28 karma points
    Mar 19, 2010 @ 19:40
    sneakyckb
    0

    Doh, it was a permissions issue on the media folder.  All sorted now, cheers mate!

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 24, 2010 @ 15:14
    Stefan Kip
    0

    Hi Doug,

    Just an update...
    The cached folder contains 7.150 images at the moment. I just analyzed the XML and these are my findings:
    Number of image elements: 424
    Number of image/cachedImage elements: 692

    As far as I know, the number of image/cachedImage elements should be the same as the total cached images in the folder, or am I missing something here?

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 24, 2010 @ 15:36
    Douglas Robar
    0

    Hi, Stef,

    Thanks for the update. From your previous posts you have about 1000 images in the folder and the xml file suggests 424 of them have been ImageGen'd with a total of 692 unique combinations. Which means you should have less than 700 images in the cached folder rather than more than 7000.

    Do you still have both sites using a shared images folder? If so, please try making an image folder for each site (and deleting the cached files).  That should make a difference. If it doesn't, at least we can rule out a number of potential issues caused by sharing a folder between IIS sites.

    Hang in there... we'll get to the bottom of this!

    cheers,
    doug.

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 24, 2010 @ 16:28
    Stefan Kip
    0

    Yes, both sites still use the same shares images folder, I will seperate them this week :)

  • Stefan Kip 1578 posts 4013 karma points c-trib
    Mar 28, 2010 @ 20:25
    Stefan Kip
    0

    I seperated the images and the count in the XML files are still equal to the number of files, so it seems like that was the problem...

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Mar 29, 2010 @ 12:00
    Douglas Robar
    0

    Excellent; glad that resolved the problem. I'll add a note in the documentation to avoid this in the future.

    cheers,
    doug.

  • Soeren Sprogoe 575 posts 259 karma points
    May 05, 2010 @ 23:45
    Soeren Sprogoe
    0

    I'm seeing issues similar to this, and I'm only running one site on one server.

    We have around 3.300 product jpeg's in one folder, displayed in 3-4 different formats and sizes around the site.

    Earlier today while debugging some performance problems, I noticed that the Cached folder had 130.000+ files in it! So I deleted them, recycled the app. pool, and the performance problems disapeared.

    Now 7 hours later, the Cached folder has grown again to about 15.000 files.

    I'm running ImageGen version 2.2.1.38932.

    Best regards,
    Soeren Sprogoe

  • Casey Neehouse 1339 posts 483 karma points MVP 2x admin
    May 07, 2010 @ 07:33
    Casey Neehouse
    0

    Doug,

    I can attest that there is still a problem with cached images as well.  I frequently run scripts to delete the cache folders from a couple of my sites as they are massive.  I too am running the latest 2.2.1 version as far as I am aware.

  • Soeren Sprogoe 575 posts 259 karma points
    Jun 04, 2010 @ 14:47
    Soeren Sprogoe
    0

    Casey,

    your images wouldn't by any chance be located on a SAN/NAS solution?

    I moved my images to its own site (images.mysite.com) on the C-drive of the server, and the caching issue disapeared. Not sure if it was the dedicated site or the drive move that solved the issue.

    /SoerenS.

  • Henrik Stidsen 3 posts 22 karma points
    Jul 06, 2010 @ 09:04
    Henrik Stidsen
    0

    The link to the zip file with the updated DLL is broken :(

  • Heather Floyd 477 posts 609 karma points MVP c-trib
    Jul 22, 2010 @ 03:14
    Heather Floyd
    0

    Hi Doug,

    I just installed this update on a client's site because the Cached images have completely filled the disk space. One thing I noticed after install is that the text headings I had that included an ampersand no longer generate.

    My original ImageGen URL was: /umbraco/ImageGen.ashx?text=News+%26+Announcements - which always worked before. I am using umbraco.library:UrlEncode() to generate the encoded text for ImageGen.

    Has something changed? Do I need to encode special characters differently?

    If I try to view the text image directly in a new browser window I get this error:

    An error occurred while parsing EntityName. Line 1, position 13.

    Any tips? I'd like to use the update, but it has broken half my headings.

    Thanks,

    Heather

    EDIT: Never mind - I found the solution here: http://our.umbraco.org/projects/website-utilities/imagegen/imagegen-bugs/10207-Ampersand-gives-me-an-EntityName-error

     

  • jacob phillips 130 posts 372 karma points
    Aug 17, 2010 @ 00:33
    jacob phillips
    0

    imagegen.ashx failed a security scan because of xss:

    /umbraco/imagegen.ashx?image=1<ScRiPt%20%0d%0a>alert('hello world')%3B</ScRiPt>&width=530&height=284

    Is there a suggested workaround for this, or is it addressed in the version after 2.01?

  • Rich Green 2245 posts 3893 karma points
    Sep 14, 2010 @ 18:17
    Rich Green
    0

    Link to the zip file is fixed now (thanks Doug) 

  • Kim Hansen 63 posts 144 karma points
    Dec 02, 2010 @ 18:34
    Kim Hansen
    0

    Link to updated dll is broken

  • kashif 18 posts 38 karma points
    Dec 16, 2010 @ 07:56
    kashif
    0

    link is still dead:    ImageGen.2.2.1.38932.zip

  • Kim Hansen 63 posts 144 karma points
    Dec 16, 2010 @ 09:11
    Kim Hansen
    0

    Edit: nevermind

  • Niklas Hjelm 104 posts 125 karma points
    Jan 01, 2011 @ 11:24
    Niklas Hjelm
    0

    The link for the update is not working. Could anyone please add it for download somewhere.

    Thanks / Niklas

  • Sebastiaan Janssen 4831 posts 14195 karma points MVP admin hq
    Jan 02, 2011 @ 13:41
    Sebastiaan Janssen
    0

    The link on the package page works just fine for me.. 

  • Bjarke Petersen 9 posts 29 karma points
    Jan 06, 2011 @ 15:05
  • MartinB 411 posts 512 karma points
    Jan 06, 2011 @ 20:51
    MartinB
    0

    Ok things make more sense now.

    I got a bucketload of folders with HUGE cache folders in them. Any "quick" way to get rid of these cached folders?

    Can i upgrade, and then remove the remaining cached folders (does the upgraded version regenerate the cache folder if deleted after installation?)

     

  • Rich Green 2245 posts 3893 karma points
    Jan 06, 2011 @ 21:18
    Rich Green
    0

    Hi, Just do a search for 'cached' and delete all the resulting directories. The cached images will be recreated automatically when they are accessed. Rich

  • MartinB 411 posts 512 karma points
    Jan 06, 2011 @ 21:31
    MartinB
    0

    Hi Rich

    Thx for the info. I can't search like that as i get access through an online .net panel, so i think i have to do it by sql, but perhaps that was what you meant?

    I'm not too familiar with SQL queries, so any help is much appreciated!

    Thanks

  • Rich Green 2245 posts 3893 karma points
    Jan 06, 2011 @ 21:44
    Rich Green
    0

    Hi, These will be physical directories in your server, nothing to do with SQL. Can you FTP all the images directories down and the clean them up, delete image directory on server and re-upload the clean directory? You would have to take the site down I guess for this. The other option would be to write a script in .net or something that looped the directories and deleted all the 'cached' ones. Rich

  • MartinB 411 posts 512 karma points
    Jan 06, 2011 @ 21:48
    MartinB
    0

    Hi Rich

    You're right, i got things mixed up! The folders are ofc not in the sql.

    I can delete them manually and have been doing so for a while in the .net panel. Just hoped for a quicker fix :-)

    .net scripting and development is not my strong side, at all.

    I'll go on with the manual thing i guess :/

  • Sebastiaan Janssen 4831 posts 14195 karma points MVP admin hq
    Jan 10, 2011 @ 08:25
    Sebastiaan Janssen
    0

    MartinB Please make sure that you follow the instructions on the project page, after the normal install you need to update it with the cache fix. This way you won't get more cache folders.

  • MartinB 411 posts 512 karma points
    Jan 18, 2011 @ 18:41
    MartinB
    0

    Hi Sebastiaan

    I had the imageGen 2.0.1 installed already before i did the upgrade by replacing the 2 mentioned files. Then i manually deletede ALL cache folders in my Media library.

    imageGen has now reinserted the cache folders, but this time there's only 3 files in each folder. Are you saying that it should not generate cache folders at all?

    If not, then i'm confused! Do i have to install imageGen 2.0.1 once more and then do the upgrade, shouldn't it be enough that imageGen 2.0.1 was installed to begin with?

    I'm having fairly large issues with loadtimes again, eventhough cache folders are not growing like they did to start with,

    Your help and advice is much appreciated!

  • Rich Green 2245 posts 3893 karma points
    Jan 18, 2011 @ 18:44
    Rich Green
    0

    Hey Martin,

    The cache folders SHOULD be recreated and there will be one image for each size you have requested.

    I believe the original bug meant that there would be multiple cached folders / or multiple cached images for the same image.

    Rich

  • MartinB 411 posts 512 karma points
    Jan 18, 2011 @ 19:11
    MartinB
    0

    Hi Rich

    Dang, then i have to look elsewhere for the slow load times :/

    I've been busting my a** off to minimize total page size, but Google Labs insists that the frontpage i a 6.5 second load eventhough i got a 1.3 sec runthrough in ySlow.

    I know a guy who has a page as well which takes about the same time for me to load in ySlow, but apparently Google thinks that his site is fast...oh well back on the horse

  • Rich Green 2245 posts 3893 karma points
    Jan 18, 2011 @ 19:55
    Rich Green
    0

    Hey Martin,

    I'm not quite sure what you mean, but not sure if you know but you can add ?umbdebugshowtrace=true to the end of the url to see a whole list of debug info.

    Rich

     

  • Kim Hansen 63 posts 144 karma points
    Jan 18, 2011 @ 20:58
    Kim Hansen
    0

     Did you remember this part?

        Create /config/ImageGen.config containing the following

    <?xml version="1.0"?> 
    <ImageGenConfiguration> 
    </ImageGenConfiguration>

        Insert the following into web.config in the configSections node.  

    <section name="ImageGenConfiguration" type="ImageGen.ImageGenConfigurationHandler,ImageGen"/>

        Insert the following just below the configSections node.  

    <ImageGenConfiguration configSource="config\ImageGen.config" />
  • MartinB 411 posts 512 karma points
    Jan 18, 2011 @ 21:52
    MartinB
    0

    Hi Rich

    I'm sorry for the confusion. I'm experiencing some bad load times on a site i did alot to keep down in size and thought i solved it when i got around to fix the imageGen 2.0.1 cache bug. Unfortunately it didn't do the trick as the site is still very slow on the initial page load from time to time. Sometimes very fast (0.8 secs), sometimes very slow 4+ secs).

    I dont get anything particularly bad when running the debugTrace and the last thing i had to try was bugfixing the ImageGen addon, as i've been through EVERYTHING else multiple times.

    @Kim

    Where did you see that? All i have is a /config/ImageGen.sample.config

     

     

  • Kim Hansen 63 posts 144 karma points
    Jan 19, 2011 @ 08:57
    Kim Hansen
    0

    I cant remember where i found it, maybe in the 2.1.1 zip a few months ago.

    Try it and let me know if it helps.

  • Douglas Robar 3565 posts 4640 karma points MVP 6x admin c-trib
    Feb 14, 2011 @ 17:02
    Douglas Robar
    0

    This forum thread is now closed

    With the release of ImageGen 2.5, please create a new topic for bugs (this forum) or questions (the 'how to') forum. 

    cheers,
    doug.

Please Sign in or register to post replies

Write your reply to:

Draft