ricksonnier / buddypress-media

Automatically exported from code.google.com/p/buddypress-media
0 stars 0 forks source link

Big image upload locks the server #52

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
*** YOU MUST ANSWER ALL QUESTIONS. IF A QUESTION IS NOT RELEVANT YOU MUST
WRITE "NOT APPLICABLE" IN THE QUESTION FIELD. ***

[What steps will reproduce the problem? (We need detailed, specific steps.
If we cannot reproduce the defect on a dev machine, we cannot fix it.)]
1.Upload a picture, any format, size etc.
2.NOT APPLICABLE
3.NOT APPLICABLE

[What is the expected output? What do you see instead?]
Server restricts my access for about 10 minutes.

[What version of BP Media are you using?]
1.8

[What version of WordPress are you using?]
3.01

[What version of BuddyPress are you using?]
1.2.5.2

[What version of PHP are you using?]
5.2

[If the problem is layout related (broken page layout, etc) or browser
related (page just freezes, cannot connect to server) ...what happens when
you load the page in AT LEAST TWO of the following browsers:]
1.FireFox - (3.6) I'm still restricted
2.Internet Explorer - (8) I'm still restricted
3.Safari - (Report version number) NOT APPLICABLE
4.Google Chrome - (6) I'm still restricted

[What is the URL of your web host?]
root.lu

[If you are running a public site, what is the URL to a page that shows the
problem?]
http://atat.ro

[Do you know how to use phpMyAdmin?]
yes

[Do you know how to edit PHP code?]
yes

[Please provide any additional information below]
The small images, those that don't need to be resized/cropped are loading just 
fine, nothing 'bad' happens. The problem occurs when I upload big images - I 
suspect the editor/crop tool is somehow restricted by the server to run. For 
example, I cannot access the wordpress' admin if I don't remove the line 
"@ini_set( 'memory_limit', apply_filters( 'admin_memory_limit', '256M' ) );" 
from the admin.php file - the same things happen, the server won't allow me to 
use the ini_set command.

Original issue reported on code.google.com by danielfl...@gmail.com on 2 Oct 2010 at 4:51

GoogleCodeExporter commented 9 years ago
I cannot replicate this on my dev machine for any reasonable sized (<10MB) 
image. If I used a huge 200MB+ image and set the max memory per PHP thread to a 
low value like 256MB it would probably crash the thread or time out. Just set 
your max upload size to something reasonable ...perhaps 3MB... and you should 
be fine.

If you're going to be running an image hosting site, you'll really need to 
become familiar with how all of PHP's various settings work. Especially "Max 
Memory", "Max Execution Time", and "Safe Mode".

Original comment by CarlRoett@gmail.com on 2 Oct 2010 at 2:34

GoogleCodeExporter commented 9 years ago
I run just 2 sites on my server, Wordpress and Osdate. None off them overloaded 
it, ever. I have a 2GHz CPU and 2Gb DDR, plenty of space. About PHP, the max 
upload limit is 5Mb, the "big" files I was trying to upload were below 1Mb (the 
one defined as small was 15Kb); there's a memory limit of 64Mb which should be 
enough, I think, for any decent script; also, a 90" execution time limit and a 
20 maximum files uploads allow simultaniously. The server is not running in 
safe mode.
I really don't see what's wrong with my server, however I apreciate your 
advices and look further for more, if you have other ideas, but I do think 
maybe the script is trying to push something that's restricted, just like 
Wordpress does in the example above (ini_set...).
Server is running Centos 5, by the way, and the PHP is 5.1.6, I was wrong 
above, sorry.
Thanks again!

Original comment by watta...@gmail.com on 5 Oct 2010 at 3:25