Welcome to Geeklog, Anonymous Wednesday, November 27 2024 @ 11:46 am EST
Geeklog Forums
Media gallery and memory_limit
Status: offline
worldfooty
Forum User
Full Member
Registered: 01/13/09
Posts: 162
Location:Mostly Adelaide, South Australia, Australia
Hi,
I've installed Media Gallery on my GL site and have been using it okay, except I can only upload very small photos to albums. memory_limit is set to 8 Mb and I've spoken to the webhosts and they don't really want to increase it because they'd have to do it for everyone and it would choke the system.
They also suggested other people have galleries on their systems (probably not GL though) and get on okay by limiting the image sizes to say 800 pixels width. The theory is that if you upload say a 1400 wide image, the system will re-size it first.
So in my test album, I've set the limits to 200 x 200 pixels and 1000 kb. Then I try uploading a 2000 x 1400, 600 kb photo, hoping it will be sized down to 200 x 200 and fit in okay. But I just get a blank page.
It seems that only if I pre-reduce the image with my own graphics editor then upload it will the process work okay. So I assume that means that the size I try to upload is what matters (which makes sense to me, but my webhost suggested that people have the gallery re-size the images, but I don't think it gets a chance because of the memory limit).
If I set the limits to 800x600 and pre-reduce my image to that first, then upload, it's okay.
Note upload_max_filesize is 20 Mb, post_max_size is 55 Mb, whatever they control.
Any advice - is 8 Mb just way too small or is there some other problem? The graphics package is GD libraries.
Cheers,
Brett
I've installed Media Gallery on my GL site and have been using it okay, except I can only upload very small photos to albums. memory_limit is set to 8 Mb and I've spoken to the webhosts and they don't really want to increase it because they'd have to do it for everyone and it would choke the system.
They also suggested other people have galleries on their systems (probably not GL though) and get on okay by limiting the image sizes to say 800 pixels width. The theory is that if you upload say a 1400 wide image, the system will re-size it first.
So in my test album, I've set the limits to 200 x 200 pixels and 1000 kb. Then I try uploading a 2000 x 1400, 600 kb photo, hoping it will be sized down to 200 x 200 and fit in okay. But I just get a blank page.
It seems that only if I pre-reduce the image with my own graphics editor then upload it will the process work okay. So I assume that means that the size I try to upload is what matters (which makes sense to me, but my webhost suggested that people have the gallery re-size the images, but I don't think it gets a chance because of the memory limit).
If I set the limits to 800x600 and pre-reduce my image to that first, then upload, it's okay.
Note upload_max_filesize is 20 Mb, post_max_size is 55 Mb, whatever they control.
Any advice - is 8 Mb just way too small or is there some other problem? The graphics package is GD libraries.
Cheers,
Brett
9
4
Quote
Status: offline
suprsidr
Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
GD is a memory hog, but 8MB is still too small.
But you should still try imagemagick or netpbm. Your host may already have the binaries. try /usr/local/bin/ or /usr/bin/ for your path.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
But you should still try imagemagick or netpbm. Your host may already have the binaries. try /usr/local/bin/ or /usr/bin/ for your path.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
7
7
Quote
Status: offline
worldfooty
Forum User
Full Member
Registered: 01/13/09
Posts: 162
Location:Mostly Adelaide, South Australia, Australia
The webhoster says he can upload 20 pics in one go, so I'll try to find out what package he uses. I tried setting to those other two, and tried both paths you suggested, but got errors like:
file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/bin//convert) is not within the allowed path(s): (/home/world:/usr/lib/php:/usr/local/lib/php:/tmp) @ /home/world/public_html/admin/plugins/mediagallery/envcheck.php line 94
I thought setting skip_file_find to 1 should've got rid of those errors (I had to set it earlier to get rid of a similar jhead error).
So I'll find out, at this stage not sure whether those packages are available.
Must admit I haven't followed your attached link - the gallery2 website seems to be down at the moment, so I'll try again later.
While I'm here - am I blind or is there no delete option in albums? I want to delete a couple of photos and I can't find a delete button anywhere, only an entire album delete option.
file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/bin//convert) is not within the allowed path(s): (/home/world:/usr/lib/php:/usr/local/lib/php:/tmp) @ /home/world/public_html/admin/plugins/mediagallery/envcheck.php line 94
I thought setting skip_file_find to 1 should've got rid of those errors (I had to set it earlier to get rid of a similar jhead error).
So I'll find out, at this stage not sure whether those packages are available.
Must admit I haven't followed your attached link - the gallery2 website seems to be down at the moment, so I'll try again later.
While I'm here - am I blind or is there no delete option in albums? I want to delete a couple of photos and I can't find a delete button anywhere, only an entire album delete option.
7
5
Quote
Status: offline
1000ideen
Forum User
Full Member
Registered: 08/04/03
Posts: 1298
Quote by: worldfooty
File(/usr/local/bin//convert)
There is a typo, no double slash //convert !
Anyway there must be a bis misunderstanding. 8 MB for a jpg pic is huge. Normally they are no more than 0.5 -2 MB.
As far as I understand not the memory limit is important but the upload_max_filesize.
6
5
Quote
Status: offline
::Ben
Forum User
Full Member
Registered: 01/14/05
Posts: 1569
Location:la rochelle, France
Hello Worldfooty,
To delete medias in an album go to media manager, select medias and press delete button.
See # Manage Media Items on this page.
::Ben
I'm available to customise your themes or plugins for your Geeklog CMS
To delete medias in an album go to media manager, select medias and press delete button.
See # Manage Media Items on this page.
::Ben
I'm available to customise your themes or plugins for your Geeklog CMS
7
5
Quote
Status: offline
worldfooty
Forum User
Full Member
Registered: 01/13/09
Posts: 162
Location:Mostly Adelaide, South Australia, Australia
Quote by: cordiste
Hello Worldfooty,
To delete medias in an album go to media manager, select medias and press delete button.
See # Manage Media Items on this page.
::Ben
Ah, I hadn't thought to look there. Thanks.
7
10
Quote
Status: offline
worldfooty
Forum User
Full Member
Registered: 01/13/09
Posts: 162
Location:Mostly Adelaide, South Australia, Australia
Quote by: 1000ideen
There is a typo, no double slash //convert !
Anyway there must be a bis misunderstanding. 8 MB for a jpg pic is huge. Normally they are no more than 0.5 -2 MB.
As far as I understand not the memory limit is important but the upload_max_filesize.
Quote by: worldfooty
File(/usr/local/bin//convert)
There is a typo, no double slash //convert !
Anyway there must be a bis misunderstanding. 8 MB for a jpg pic is huge. Normally they are no more than 0.5 -2 MB.
As far as I understand not the memory limit is important but the upload_max_filesize.
The double slash must come from having a slash at the end of the path. But going without the slash gives much the same error:
Text Formatted Code
2 - file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/bin/convert) is not within the allowed path(s): (/home/world:/usr/lib/php:/usr/local/lib/php:/tmp) @ /home/world/public_html/admin/plugins/mediagallery/envcheck.php line 94But when I asked my webhost if imagemagik and NetPBM are installed and what the path is, he said they are, but forgot to tell me the path. So I'll try again.
In terms of 8 MB, no the photos are much smaller, around 800 kb. I think that limit of 8 Mb is the limit for the process to suck the photo in, re-size it and produce a thumbnail. I assume that's what it means anyway.
9
6
Quote
Status: offline
suprsidr
Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
open_basedir restriction
This is a server configuration to ensure your site stays within its "playground" so to say.
Ask your host to add the IM and Netpbm path(s) to your allowed open_basedir path.
OR
Upload your own precompiled Netpbm binaries to a path within your site's playground and use those.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
12
10
Quote
Status: offline
worldfooty
Forum User
Full Member
Registered: 01/13/09
Posts: 162
Location:Mostly Adelaide, South Australia, Australia
But when I asked my webhost if imagemagik and NetPBM are installed and what the path is, he said they are, but forgot to tell me the path. So I'll try again.
So I asked for what the path was, and he said:
Damn good question..
If you look at the bottom of cpanel (home) you can see Installed Perl Modules and path..
Path to PERL /usr/bin/perl
/world/bin/per
If you look at the bottom of cpanel (home) you can see Installed Perl Modules and path..
Path to PERL /usr/bin/perl
/world/bin/per
I'm not sure what that has to do with my question! He actually hosts us for free, beggars can't be choosers, so I won't hassle him anymore.
So I'll either install the binaries as suggested, or maybe just live with GD - it seems to work as long as I limit images to less than 700 kb and 800 pixels wide.
10
9
Quote
Status: offline
worldfooty
Forum User
Full Member
Registered: 01/13/09
Posts: 162
Location:Mostly Adelaide, South Australia, Australia
Yeah, that's where I've been adjusting the path, but it doesn't find it, or I guess those basedir errors.
5
8
Quote
All times are EST. The time is now 11:46 am.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content