Most CPU Friendly settings. Most CPU Friendly settings.
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Most CPU Friendly settings.

Started by Hercules24, November 24, 2006, 12:32:18 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Hercules24

My webhost is suffering more and more under the load of installed Coppermine galleries and I'm wondering what I can do to keep the CPU load as low as possible.
-The most devastating is to batch add hi-res files that need to be resised, this can be solved by doing it yourself and manually upload the large ones later.
-In the main gallery page I don't show thumbnails at all, only links to the different months when the pics were taken.
That's what I've found out so far.

Are there other settings in the config screen which can be adjusted to minimize CPU usage, and how many thumbnails maximum in each album/album category are advised?
My gallery is here if you might see things I could improve.
Thanks for the input.

isloera

You should edit them and compress them as much as possible. Resizing them helps a lot too. I can imagine that pictures with high resolution and large size will take a lot of bandwith. You have no choice but to limit your pictures to about max 80 kilobytes and the larger side no bigger than 800 pixels.  If you have users that upload pictures, you should let them know about the new rules.  You can enforce the limit  size of the pictures that are uploaded so that only the right ones can go into the gallery. This can be done in the admin section of the gallery.

Hercules24

I've already encountered one problem with the resising, let's say I want the full size to be 1200x1800 and the intermidiate 450x675.
When I first upload a 450x675, Coppermine only creates a thumbnail, because the full size is the same as the desired intermediate.
Is there a way to tell Coppermine to also create a normal_xxx.jpg even if it's exactly the same as the xxx.jpg?
When I upload a 451x676 or 500x750 at first, I get a 450x675 which is a lot more blurry because it's resized 2 times instead of 1.

Joachim Müller

Resize on your client before uploading. See my reply here: http://forum.coppermine-gallery.net/index.php?topic=38555.msg182093#msg182093

Post a link to your page for details.

Hercules24

I think I finally managed the manual upload:
First I resize my pics in the desired large format.
In an other dir I resize the same pics to the medium format.
I rename the medium format pics to normal_filename.
I FTP both lists of files to a new directory.
Batch adding goes very fast because only a new thumb will be created what is way little work than also creating the medium size pics it seems.
This way CPG doesn't change the filename.jpg and the normal_filename.jpg, so the files won't be resized more often than needed.
If I uploaded a smaller than finally desired large picture first, batch add everything, and manually later upload the large pictures, CPG would store that smaller resolution size in it's dbase making the pop up much smaller and let people think there's no large picture to be saved.
It's more work to do, but hopefully this will prevent te server from CPU quota warnings during the uploading so my visitors won't be annoyed.

Gaugau, this is a link to my gallery: http://www.kuikens.com/pictures
If you see simple settings I can change to futher lower CPU usage when a lot of visitors are viewing, please let me know.

Joachim Müller

Looks OK to me - your settings for displaying content on the index pages make sense in terms of not wasting resources by running too many queries.

Hercules24

Thanks Gaugau for checking.
Maybe somebody else comes up with someting too, since lately there are more treads arising about CPU usage.