Wordpress media library http errors...

January 20, 2014 3k views
I'm running Wordpress 3.8 on Ubuntu 12.10 and everything is running smoothly except for the Media Gallery function. Image uploads keep falling over despite having set the upload limit to 30Mb and changed permission on the 'Uploads" folder. Does anyone have a fix for this issue? Cheers.
7 Answers
Access your droplet and navigate to your wordpress installation folder for example /var/www/wordpress. There you will find the folder wp-content and do:
sudo chmod 755 wp-content
If you haven't done this. Or if you changed the folder name go through again every step of the process.
Thanks but unfortunately that didn't solve the problem.
What webserver are you using and what user is it running as (you can find out by running ps wwaux | grep apache or ps wwaux | grep nginx)?
Were you able to figure this out? I'm having the same problem on a lemp server. Usually if I retry, the upload works, but it is annoying to have this many errors, and my media library is cluttered with duplicates.

or all those who experience the http error problem, I would like to share how I figured it out. I realized that I was actually able to upload images with small size - 1kb, 30kb, etc. Larger files like 300 kb or 2 mb gave me an HTTP error in the admin media section.

So, there are several things that I did, as following:

Increased max_execution_time = from default to 5000;
Increased upload_maxfile_size = from default to 200M;
I have applied the two steps above in these files:


After that, ssh login via root account to my droplet and restarted apache via:

service apache2 restart

After that I saw that in my wordpress admin section the limits have been rised up. Unfotunately, I couldn't upload larger images - 1mb in size, for example.

Then, I found this file:

/etc/apache2/mods-available/fcgid.load and saw that it contained this line:

LoadModule fcgid_module /usr/lib/apache2/modules/modfcgid.so

I have changed the content of this file to:
LoadModule fcgid_module /usr/lib/apache2/modules/modfcgid.so
<IfModule fcgid_module>
FcgidMaxRequestLen 204800000

Restarted apache as written above.
Now, I was able to upload larger files.

have checked dir permissions to be 755 even tried 777. When a user tries to upload his avatar from the frontend (eg in WP or in buddypress) or i try via backend i get HTTP error still - strangest part is if i look in FTP the file was actually uploaded - but in WP or BP it is reporting error and does not like always then take you to the Crop Image step

Have another answer? Share your knowledge.