Advanced search  

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

Pages: [1]   Go Down

Author Topic: The dreaded "Unable to create thumbnail or reduced size image"  (Read 7330 times)

0 Members and 1 Guest are viewing this topic.

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10

Yes the folder perms (777) are correct album, edit & userpics dirs (as the files end up in the userpics), and using GD2.x

I turned on notices with the debug and got:

Quote
/upload.php
    * Notice line 2191: Undefined index: user1
    * Notice line 2192: Undefined index: user2
    * Notice line 2193: Undefined index: user3
    * Notice line 2194: Undefined index: user4
/include/picmgmt.inc.php
    * Warning line 276: imagecreatetruecolor(): Invalid image dimensions
    * Warning line 277: imagecopyresampled(): supplied argument is not a valid Image resource
    * Warning line 281: imagejpeg(): supplied argument is not a valid Image resource
    * Warning line 283: imagedestroy(): supplied argument is not a valid Image resource
    * Warning line 289: getimagesize(): Read error!
So, looks like my issue is totally different to many other people's??

Any ideas?
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #1 on: August 07, 2008, 05:43:23 pm »

No, in fact it looks the same as that of many similar postings, where people asked for support on upload issues and failed to read the corresponding section of the docs that clearly explains what you need to do when asking for support. In this aspect, your posting doesn't differ from 90% or all other postings on this sub-board: the first reply by a supporter is always the same: read the docs and do as suggested there. Guess why: there's a reason why we ask for the information you need to post (details: the section "asking for support on upload issues" yadda yadda). We're sick to be forced to repeat to every new thread starter what he needs to do to get support, so we wrote the corresponding section in the docs and put up a sticky thread on this sub-board that tells you just the same thing. Yet 90% of all thread starters don't read it and then are frustrated about the harsh reply they get by supporters (which usually is shorter than my rant here).
Please, do the both of us a favor: read the docs closely. If you already have, read the section I'm refering to again. Really - I mean it. Then do as suggested there.
This reply is not meant to boss you around or sound disrespectful - it's meant to sound sad and frustrated.

Joachim
Logged

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #2 on: August 07, 2008, 06:20:04 pm »

Sorry that 'got' your goat,.... but I did RTFM, as you quite nicely put it in your other posts........ and I also did what TFM told us to do!  Changed the php.ini.....and guess what... same error! :-\
Logged

phill104

  • Administrator
  • Coppermine addict
  • *****
  • Country: gb
  • Offline Offline
  • Gender: Male
  • Posts: 4885
    • Windsurf.me
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #3 on: August 07, 2008, 07:35:18 pm »

What Joachim is asking is that you read the docs here

http://coppermine-gallery.net/demo/cpg14x/docs/index.htm#upload_trouble

and then do what is asked especially what is written in red once you have applied the settings suggested.

You have to understand that if 9 out of 10 people don't do this then that is a lot of time wasted by the support team asking you to do so. On a very busy board like this that adds up. The team do all this work for free and develop the software in their spare time for free. It is not a lot to ask that those who use it put some effort in themselves and read the docs thereby making life a lot easier for the devs.
Logged
It is a mistake to think you can solve any major problems just with potatoes.

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #4 on: August 07, 2008, 08:16:02 pm »

What Joachim is asking is that you read the docs here
http://coppermine-gallery.net/demo/cpg14x/docs/index.htm#upload_trouble
and then do what is asked especially what is written in red once you have applied the settings suggested.
Well I did all that in one go..... folders were 777 as always.....

Heres a test login if required:

http://www.reemicks.co.uk/copmine/index.php
both details are test

and fwiw:
Quote
[php.ini]
file_uploads : On   On
max_input_time :  120  120
memory_limit: 32M  32M
upload_max_filesize   2M   2M
upload_tmp_dir   /tmp/   /tmp/

[permissions]
drwxrwxrwx 5 10013 2523 1024 Aug  7 18:43 albums

drwxrwxrwx 2 10013 2523 1024 Aug  7 18:43 edit
drwxrwxrwx 2 10013 2523 1024 Aug  7 14:34 images
drwxrwxrwx 2 10013 2523 5120 Aug  7 18:43 userpics
Logged

phill104

  • Administrator
  • Coppermine addict
  • *****
  • Country: gb
  • Offline Offline
  • Gender: Male
  • Posts: 4885
    • Windsurf.me
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #5 on: August 07, 2008, 09:20:59 pm »

Did you read the bit about your settings?

   [num_file_upload] => 5
    [num_URI_upload] => 3

Setting these as suggested in the docs means there are more details about the error provided in the debug.

Well done on being up to date with your coppermine install though.
« Last Edit: August 07, 2008, 09:29:24 pm by phill104 »
Logged
It is a mistake to think you can solve any major problems just with potatoes.

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #6 on: August 07, 2008, 09:50:51 pm »

it says URL = 0 and files = 1
Quote
#
# Set the upload form configuration for all groups to "Single file uploads only"

   1. set File upload boxes to "1" (1)
   2. set URI upload boxes to "0" (2)
   3. set No. of boxes to "fixed" (3)
Logged

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #7 on: August 07, 2008, 09:52:54 pm »

it says URL = 0 and files = 1
well   now it does......hmmm
Logged

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #8 on: August 07, 2008, 10:54:55 pm »

Just a quick update......Just thought, it wouldnt be anything to do with the file permissions would it, as my server doesnt actually use the correct user:group for files created/uploaded via php (blame gay Plesk for not including suPHP)..... I see the script uses chmod on files, but it'll fail as the file isnt under the same user:group as the calling php file.....

?
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #9 on: August 08, 2008, 07:47:31 am »

It took 7 postings before you finally set up coppermine as suggested for upload troubleshooting and supporting purposes, which is quite too much in my opinion. Arguing with supporters about the need to do some things the way they need to be done is just very annoying for supporters.
When I went to your site and logged in with the test user account that it took so long to provide I realized that there was not album where the test user could upload to, so I had to create one for him first, which proves that you never bothered to even try for yourself and log in with the test user account and try uploading using that account. This is not what I would call thorough preparation of a support request.
Anyway, I created that album and went on to upload, finally with the needed settings in place (after 7! postings on this thread). On a first attempt I got
Quote
The size of file you have uploaded is too large (maximum allowed is 400 x 400) !
when trying to test-upload with my "usual 640x480 pixel test file. On the second attempt, trying to upload a file with smaller resolutions than the low-spec dimensions you require I got
Quote
The file 'albums/userpics/flower.jpg' can't be inserted in the album

Unable to create thumbnail or reduced size image.

File: /var/www/vhosts/reemicks.co.uk/httpdocs/copmine/db_input.php - Line: 402
, which usually indicates that there is something wrong permissions-wise on file system level. However, there are more things to check: 777 doesn't necessarilly have to be the correct setting that is needed on your webserver: some webservers fail to work with 777, but need 755. Please contact your webhost on this issue. Judging from your postings, you seem to know a lot about it (much more than the average user looking for support on this board), so you might be self-hosted as well or at least have shell access. If this is the case, review carefully for hardening patches. Usually, on many webservers you mustn't grant the world/nobody write access (which is for example the case on my webhosting account) - I have to chmod 755; if I chmod to 777, all I get are error messages. You should as well look into PHP'S temporary upload folder and make sure that it exists and that it has the needed permissions as well.
And yes: we're aware that the script can only perform PHP's chmod command if it has the priviledge to do so, which is hardly ever the case, so the chmod command issued by the script doesn't do anything particularly usefull in 99% of the times. However, it won't hurt and is beneficial for the small minority with exotic permissions setup, that's why it's there and has been added in the first place. Ignore it for now.

Joachim
Logged

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #10 on: August 11, 2008, 10:42:29 pm »

I've tried this script on a FRESH server (php5, mysql5, gd2)......and guess what........ same results....... ::)
Logged

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #11 on: August 11, 2008, 11:14:29 pm »

.....even fails when i change the folders user to apache:apache............. so..... er.... yeah.....  :'(
Logged

Peter Laws

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #12 on: August 12, 2008, 02:17:01 am »

Thank god
Logged

Hein Traag

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: nl
  • Offline Offline
  • Gender: Male
  • Posts: 2166
  • A, B, Cpg
    • Personal website - Spintires.nl
Re: The dreaded "Unable to create thumbnail or reduced size image"
« Reply #13 on: August 12, 2008, 06:27:30 am »

Thank god

Your welcome.. son?   ;) Or could you perhaps elaborate on what it is that you are thankfull about?
Logged
Pages: [1]   Go Up
 

Page created in 0.297 seconds with 20 queries.