Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
PHP warnings, about filesize
12-03-2014, 06:12 AM,
#1
PHP warnings, about filesize
I wanted to upload a large file with PHP (serendipity software), but it would not let me do that.

There were a few things I had to change.

Setup: Apache with vhosts.

File 1 to change:
php.ini (the one of my virtual host)

Code:
max_input_time = 1200  # To allow more time to upload
max_execution_time = 1200  # To allow more time to upload
upload_max_filesize = 25M # my file is just above 20M
post_max_size = 25M # Needed
File 2 to change: The current active httpd.include
Code:
FcgidMaxRequestLen 25000000
Both were needed.

Check the error in error_log when uploading a large file. First the message about File 2 was there, and when that was resolved, the message about file1 was stated.

Message1:
Code:
[Tue Dec 02 20:41:21 2014] [warn] [client 77.248.252.19] mod_fcgid: HTTP request length 16783955 (so far) exceeds MaxRequestLen (16777216), referer: .....
Message2:
Code:
[Tue Dec 02 20:58:46 2014] [warn] [client 77.248.252.19] mod_fcgid: stderr: PHP Warning:  POST Content-Length of 20583784 bytes exceeds the limit of 8388608 bytes in Unknown on line 0, referer
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)