Simple Machines Community Forum

SMF Support => Server Performance and Configuration => Topic started by: Oldiesmann on May 03, 2011, 01:14:49 PM

Title: mod_fcgid and MaxRequestLen
Post by: Oldiesmann on May 03, 2011, 01:14:49 PM
Has anyone here ever run into issues with FastCGI's "MaxRequestLen" directive?

I recently moved to a new VPS, and users were getting internal server errors every time they tried to upload things to the gallery. After several days of racking my brain trying to figure out what was going on (nothing was being logged in the account-level server error log), I finally decided to check the global error log (/usr/local/apache/logs/error_log), and this lead me to the following warning:

[Mon May 02 13:21:18 2011] [warn] [client my.ip.address.here] mod_fcgid: HTTP request length 135024 (so far) exceeds MaxRequestLen (131072), referer: <url to add an item to my album in the gallery>

I got around this by modifying the pre-virtualhost include file to override MaxRequestLen (using an <IfModule mod_fcgid.c> block), but I'm wondering if there's a better way to do this. I didn't run into this at all on my old VPS, which also had PHP running in FastCGI mode (though I was running PHP 5.3.5 there, and 5.3.6 on this server).