• So if you are like me and had the dreaded http error pop up during an image upload you were probably pretty upset. The Interwebs is full of solutions. Some of them may work for you, some of them will not.

    I tried it all. Edited .htaccess files, used a plugin, disable all plugins, fresh install, changed permissions (not a solution I might add), drank a bottle of whiskey, then performed some voodoo on my server. Alas the problem remained.

    I kept thinking that the issue had something to do with Mod_security, it did not.

    I couldn’t understand why every edit I made into an .htaccess file would simply not result in anything. Then I realized why. My server actually uses Mod_security2, and it doesn’t give a crap about .htaccess files. Disabling Mod_securty2 provided no results either.

    My php configuration was fine, max_upload size is set to 500MB, max post size is fine, safe mode is not on, etc.. The error wasn’t with .htaccess, nor was it with php.ini. It was in Apache, specifically, http.conf.

    HTTP.CONF used to set a value for FcgidMaxRequestLen somewhere in the neighborhood of 1gb by default, which it no longer does in newer versions. The new default is 131072 bytes. that value is overiding your value in php.ini, so you Must change this to match your settings in php_max uploads so you don’t pull your hair out.

    If you have access to WHM, changing it is simple….

    Log into WHM, under service configuration, select “Apache Configuration”, then click on “include editor”. On the drop down menu under “pre main include” select “all versions” and simply put..

    FcgidMaxRequestLen “your value minus the quotation marks here”

    Remember the value needs to be in Bytes. so if you want an upload limit of say, 500Mb, the you would write,

    FcgidMaxRequestLen 52428800.

    Obviously this won’t work for everyone, simply because every server setup is different, but it has solved my issue, and I hope it solves yours also.

Viewing 4 replies - 1 through 4 (of 4 total)
  • solved my issue too, good job! aravoth, with the recent updates to apache i was seeing this issue on some of my vps, i was just about to bother my host with this hehehe, thanks.

    I found that if I add this to my .htaccess it also works:

    <IfModule mod_security.c>
    <Files async-upload.php>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </Files>
    </IfModule>

    Worth a try if you’ve failed with other solutions.

    P

    Its works for me to edit FcgidMaxRequestLen 52428800.

    But I want to know how much memory supported in Apache. I want it more 1GB. It that ok. Also I need to know how much memory enough for me?

    If you have a virtual host with WHM, you can enable FastCGI like this:

    1. Main >> Service Configuration >> Configure PHP and SuExec
    2. set PHP 5 Handler to: fcgi
    3. set Apache suEXEC to: on
    4. press the “Save New Configuration” button

    Now, to overcome 500 errors (Internal Server Error) when uploading themes, large images, etc. do this:

    1. Main >> Service Configuration >> Apache Configuration >> Include Editor
    2. under “Post VirtualHost Include” select “All Versions”
    3. put this code in the textarea: FcgidMaxRequestLen 52428800
    NOTE: the default value is only: 131072
    4. press the “Update” button
    5. press the “Restart Apache” button

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Resolution to the dreaded HTTP error during media uploads’ is closed to new replies.