Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1] 2   Go Down

Author Topic: The previous file could not be placed.  (Read 10099 times)

0 Members and 1 Guest are viewing this topic.

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
The previous file could not be placed.
« on: January 08, 2006, 12:47:57 am »

I just installed and setup cpg143, it seems to work perfectly until I go to upload larger pics.  I have adjusted the "Max size for uploaded files (KB)" to 10000 and "Max width or height for uploaded pictures/videos (pixels)" is set to 1024 and "Auto resize images that are larger than max width or height" is set to "yes everyone".  Are larger pics not supported?  Its a small site for myself and my family, we all have 7+ megpixel cameras so I don't really know what to do here.  Is there a setting I'm missing?   

Its on a Linux webhost from 1&1 which has php 4.4.1 installed and GD support with versions 2.0+ is enabled.  Like I said I threw a smaller pic up there that was like 37k and it worked great but when I put up my real pics which are all 2-4mb it just gives me the message " The previous file could not be placed." no other info is given and of course the file doesn't make it into an album, I can see it on my ftp though.  I have also set the "album" and "include" folders to 777.   This was not an upgrade, its a complete fresh install.

Any help would be appreciated. 
Logged

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Re: The previous file could not be placed.
« Reply #1 on: January 08, 2006, 01:28:13 am »

Please search before posting.  This comes up all the time - it takes a huge amount of resources to resize large dimension images.  Your host simply doesn't give PHP enough memory to accomplish this task.  Resize your images prior to uploading them, or ask your host to increase memory limits.  Read the FAQ.
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: The previous file could not be placed.
« Reply #2 on: January 08, 2006, 01:58:45 am »

Thanks for the answer, I'll call my provider.  I did search, both the FAQ and the forum, it must come up as something else, or be called something else because I sure can't find it and I'd have no way of knowing what else it would be titled, named or called so posting was really the only thing I could do. 

(https://forum.coppermine-gallery.net/proxy.php?request=http%3A%2F%2Fxs62.xs.to%2Fpics%2F06010%2Fcpg143a.png&hash=40e088c6e6608d0c1d2428e34ee7e41288b566b8)

(https://forum.coppermine-gallery.net/proxy.php?request=http%3A%2F%2Fxs62.xs.to%2Fpics%2F06010%2Fcpg143b.png&hash=8ba29fa95a8ae1a1f54919cb50f0580fc7db9c2a)

But again thanks for the quick answer.  You may want to consider adding this to the FAQ if it comes up so often.  Please leave this thread up as long as possible as I'll be e-mailing my provider and giving them the link to this thread so that hopefully they can resolve this issue. 

Thanks.
« Last Edit: January 08, 2006, 02:10:32 am by ss3vegeta »
Logged

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Re: The previous file could not be placed.
« Reply #3 on: January 08, 2006, 04:38:06 am »

The general troubleshooting portion of the FAQ contains the PHP memory settings.

http://coppermine-gallery.net/demo/cpg14x/docs/faq.htm#uploadGeneralTroubleshooting
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The previous file could not be placed.
« Reply #4 on: January 08, 2006, 04:23:09 pm »

if a search doesn't come up with results, re-phrase your search term - should be obvious.
Logged

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: The previous file could not be placed.
« Reply #5 on: January 10, 2006, 09:34:30 pm »

You were dead on, it seems to be my host doesn't give me much for resources.  They told me I could create a php.ini file in my root directory that I could adjust all those settings in.  I however do not know the commands to put in it?  Could you please give me the code to include, he said I can adjust every setting for php, so if someone could help that would be awesome, but please keep in mind these are very large photos that I'm uploading.

Logged

Bacchus

  • Contributor
  • Coppermine regular visitor
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 70
  • Sith Marauder
    • Solitude
Re: The previous file could not be placed.
« Reply #6 on: January 10, 2006, 10:22:25 pm »

You need to download php here: http://www.php.net/downloads.php

and this is the documentation in various language: http://www.php.net/docs.php
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The previous file could not be placed.
« Reply #7 on: January 10, 2006, 10:36:45 pm »

You need to download php here: http://www.php.net/downloads.php
not true



just read http://www.php.net/ini.core#ini.memory-limit - your php.ini doesn't have to contain every single setting - only the stuff you want to override has to be mentioned. In fact you just create a plain text file, name it php.ini, edit it with a text editor like notepad.exe and put
Code: [Select]
memory_limit = 16Minto it. Save the file into your webroot. I'm not sure if the server needs to be restarted though.
Logged

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: The previous file could not be placed.
« Reply #8 on: January 11, 2006, 12:47:48 am »

Thanks GauGau,

My default level is already set to (without touching them):

Code: [Select]
memory_limit = 40M
post_max_size = 8M
upload_max_filesize = 20M

So I'm guessing that isn't it, could it be one of these settings (the defaults are)?

Code: [Select]
max_execution_time = 30
max_input_time = -1


If an admin is willing I'd be happy to pm you a link to my info.php so you can see all the settings as well as set up a test admin account so someone could look at my settings.  I just don't think it would be very wise to give the info.php out to anybody who may want to take a peak.  I've adjusted the above limits to extreme numbers and it still won't work, as far as I can tell it should be working because the info.php file shows the modifications I've made.  I even did a complete re-install, I'm lost. 
« Last Edit: January 11, 2006, 06:54:14 am by ss3vegeta »
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The previous file could not be placed.
« Reply #9 on: January 11, 2006, 10:40:21 am »

may be wishful thinking, I don't think that your webhost will let you configure your virtual host with these settings, as it would have an impact on all other domains hosted on the server, so I guess your settings are just ignored. Try finding out if the settings you specify in your php.ini are actually taken into account. Write a test script, using memory_get_usage(), or contact your webhost again.
« Last Edit: January 11, 2006, 08:47:44 pm by GauGau »
Logged

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: The previous file could not be placed.
« Reply #10 on: January 11, 2006, 06:02:17 pm »

Well I don't really know php so I'll have to figure out how to make a script, but I'll try. 

Ok so I made a test.php and put the line
Code: [Select]
<?=memory_get_usage();?>in it, what i got back was - 14592

or is this not what you told me to do?

So I tried:

Code: [Select]
<?=ini_get('memory_limit');?>
And got back 100M

I've called my host and they tell me I should have plenty to resize any pic, and that I control what i have for resources through my php.ini.  I'm lost. 
« Last Edit: January 11, 2006, 08:10:17 pm by ss3vegeta »
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Logged

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: The previous file could not be placed.
« Reply #12 on: January 11, 2006, 11:06:18 pm »

Quote
The file 'albums/userpics/10001/IMG_0931~1.jpg' can't be inserted in the album

The image you have uploaded is corrupted or can't be handled by the GD library

I tried several pics, my assumption is they can't all be corrupted so I guess teh GD library can't handle it.  Mine is GD support with versions 2.0+, so where does that leave me, what do I need to do?
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The previous file could not be placed.
« Reply #13 on: January 11, 2006, 11:10:15 pm »

do as suggested here: http://coppermine-gallery.net/demo/cpg14x/docs/index.htm#upload_trouble
Re-read carefully and do as suggested if you want help, I won't repeat this again.
Logged

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: The previous file could not be placed.
« Reply #14 on: January 11, 2006, 11:25:10 pm »

Ok I'm not sure which part you mean, I did a search and read through all of the topics I could find.  It apears to be a GDI problem, I see that.  If you mean a link, well here it is

kayongo.net
test
password

I also called them again and was told that the only thing on there end it could be is a cpu usage issue, they only allow an 8 second 100% burst, would that cause this issue. 
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The previous file could not be placed.
« Reply #15 on: January 11, 2006, 11:36:10 pm »

uploading a 2048 x 1024 file worked fine, see http://kayongo.net/displayimage.php?pos=-2
Logged

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: The previous file could not be placed.
« Reply #16 on: January 12, 2006, 12:10:10 am »

strange, my default camera pic size is 2592 x 1944 and i can't get it to work at all, can someone try a larger pic and see what happens. 
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The previous file could not be placed.
« Reply #17 on: January 12, 2006, 07:34:53 am »

I tried a 3000 x 2000 pixel pic, which didn't work - the script probably times out. Not sure what to suggest except resizing pics on the client before uploading. Uploading pics with such a ridiculously large resolution just doesn't make sense anyway.
« Last Edit: January 12, 2006, 05:24:20 pm by GauGau »
Logged

ss3vegeta

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: The previous file could not be placed.
« Reply #18 on: January 12, 2006, 03:49:52 pm »

The script times out?  So does that mean its a coppermine issue or my webhost?  Uploading pics at that size is necessary as there are several photographers in my family, the purpose of the site would be so that someone can take high quality photos from anywhere in the world and upload them to the site from a net café or library.  Resizing the pics before upload just isn't plausible, then you'd have to keep a hard copy with you and couldn't wipe the memory cards, which would make the site pointless.  I've got 30GB of webspace dedicated to this site so I really would like to know if it’s a coppermine issue or a webhost issue so I know where to go from here.  What I mean is if it’s a coppermine issue I can try to find a different photo album to use, if its my host then I'll have words with them since I pay for far more than a basic package so I may need to find a host that isn't robbing me blind.   
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: The previous file could not be placed.
« Reply #19 on: January 12, 2006, 05:27:15 pm »

webserver issue, so (from your point of view) a webhost issue. If you have premium support, ask them to install ImageMagick for you and make it available for you (you'll need to know the path to ImageMagick's convert executable).
Logged
Pages: [1] 2   Go Up
 

Page created in 0.04 seconds with 19 queries.