Greetings!
First off, kudos on this GREAT piece of software!
I've been playing with G2 for a while, and my only complaint is that it seems to create the thumbnails every time that I go to an album. Is this going to be how G2 does it rather than creating and keeping the thumbnail? Can there be an option to store thumbs?
Thanks!
Posts: 7994
Can you explain what leads you to believe that it's creating the thumbnails every time?
By design, G2 creates the thumbnail/resize once and caches it. The cached thumbnail/resize is deleted and recreated it the source image changes, but not otherwise.
Posts: 12
I don't see any new files being created, and once in an album it takes about a second for EACH thumb to show up.
Could I have a mis-configuration? What other information could I give you?
FYI:
I've tried this on two systems with identical results. One is RedHat 8.0/Apache 2.x. The other is a Win2k Server with Apache 2.x as well. Both systems use ImageMagick.
Many thanks for your time!
Posts: 81
I get similar results.
When displaying the contents of an album it takes a second for each thumb image to load.
The first time opening an album after uploading images, the placeholders for the thumbnail images are not pre-sized. Subsequent visits to the album have the placeholders correctly sized.
In all cases, however, the thumbs take about a second to load, even when you are returning to an album you just viewed.
All of G1 installs, both localhost and on the Internet, display the thumbs much quicker, especially when the page was cached.
NOTE: I'm working localhost, so I doubt this is network related.
System is WinXP Home, Apache 1.3.27 and PHP 4.3.1, VisualMagick
Posts: 7994
It's not regenerating the thumbnail each time, it's just slow to display them.
Gallery 1.x simply sent the browser a URL to an image which loads very quickly (and is very insecure). G2 sends the browser a link to another script which then verifies your authentication information before downloading the image. This can be a lot slower.
The current G2 code has not been optimized yet. Don't worry about the performance; we'll make it go a lot faster before we ship it.
Posts: 4
I also seem to have this problem. thumbnails are not created like G1 in the map with the original JPG's. Instead they seem to be made "on the fly" whenever an album is opened. This results in waiting about 1-2 sec before a tumbnail appears....
Posts: 7994
See my last post. Nothing has changed -- we only ever generate thumbnails once. Provide the URL to your G2 with debug mode on if you think that this is not the case and we can go over the debug output (because all image operations show up there so its easy to tell if they're happening every time or not)
Posts: 4
It apperently seems to be the same "problem"; Just have to get used to the new procedure, which is indeed much safer and cool.
Running on FreeBSD 4.7 on a pentium II -280 Mhz with 64 MB RAM.
Posts: 7994
It's definitely going to be slow on a PII for now -- but wait until I get around to doing optimization. I'm confident that I can speed up image loading by a factor of 2x.
There are a lot of benefits to the new model of only creating thumbnails when you need them. Uploading is much, much faster and if you never view the image, it never gets processed. Also, we can write a module that lets you establish a limit on the number and size of generated files (eg thumbnails, resizes, highlights, etc) and then it can delete the ones that haven't been viewed often. For example, you can say something like "Keep only 10 MB of thumbnails, and when we go over 10 MB get rid of the ones that nobody ever looks at". Haven't written that yet, of course -- but its coming!
Posts: 16
I'm having the same problem. I have installed Gallery 2, and imported almubs form my old Gallery. The thumbnails load very slow. It takes about 30 seconds to load the screen with thumbs. I have looked on the server, but I can't find any thumbnails and it seems that they are being generated every time I enter any album.
The /home/user/public_html/gallery2/g2data/albums directory only contains the full size images. I looked around, but I can't seee the thumbs anywhere...
Otherwise I really like Gallery 2 and can't wait for the final release (BTW how does the timeline look like, when can we expect it?)
Thanks!
Posts: 8601
g2data/cache/derivative
Posts: 7994
We generate thumbnails the first time you view them, then cache them for later. One of the problems is that the browser will request 3+ thumbnails at once, and if your server is slow, it may start thrashing trying to compute the thumbnails simultaneously. I'm planning on a solution that will let you generate the thumbnails at upload time, which would happen serially so your machine won't thrash.
We're making rapid progress. I wouldn't be surprised to see a final version by the end of the year or the first month or so of next year. But, I've blown every time estimate I've ever made for G2 so don't hold me to this one either.
Posts: 6
I see that this is an old post but im having some of the same problems with this situation. I dont know if anything has ever been done about this or any new features have been added in. I also dont know if anyone else still sees the same thing that im seeing, that is the server loading thumbs very slow. I can watch the cpu performance go to 100% every time i hit refresh on a page. I just thought i would bring this topic back up again see if i can get any responses on this
Posts: 32509
lol, you're resurrecting a > 1 year old forum thread here.
please post your issue in the support forums and post details about your server hardware, software, nr of albums / items, useralbums, are most items / albums public or private, etc.
Posts: 6
I brought this back up because i would like to know if any of the features talked about in this thread have been addressed? I am having the same issue as the guy who posted the first thread. The thumbnails load slowly on first load. What i would like to know is if there is a feature that will let me automatically create the thumbs right from the start. Or as quoted above keep X amount of megs of thumbs and dumb unrecently used thumbs?
Posts: 32509
- thumbnails are *not* generated on each request
- thumbnails are stored on disk
- thumbnails are generated on upload if you have the "generate thumbnails" option selected in "add items -> from browser"
- else, thumbnails are generated when first needed
- thumbnails can also be generated when going to "site admin -> maintenance -> build thumbnails and resizes"
hasn't been implemented yet.
and this would only address disk space usage.
there have been other improvements, e.g. we added a fast download cache and a few other things to speed things up. more to come at some point.
a pentium 2 is just too slow for most g2 installs.