HTTP 413 Request Entity too Large

回眸只為那壹抹淺笑 提交于 2019-12-12 18:12:18

问题


I am currently unable to post very large files using the Drupal FileField Source (remote url option) on a custom file field in drupal 7 (7.15). The file is uploading to the tmp directory successfully but failing when it attempts to post. The file size is 870Mb (A 510mb file has posted successfully.).

I receive the following error in access_log:

83.000.15.200 - - [02/Oct/2012:12:30:14 +0000] "POST /file/ajax/field_video_source/und/0/form-i6gTPc5LlZsQxKpgO43eaLGjh7dgWqHjQ6TPZD9SRmY HTTP/1.1" 500 413

I assume I am interpreting this error correctly as a 413 Request Entity Too Large

I have configured php.ini with the following settings:

post_max_size = 1800M
max_execution_time = 3600 (i know that's overkill)
memory_limit = 1750M
max_input_time = -1 (unlimited)

In addition I have attempted to set the LimitRequestBody value to 0 in php.conf using the following:

<Files *.php>
SetOutputFilter PHP
SetInputFilter PHP
LimitRequestBody 0
</Files>

This didn't appear to help.

The server is running Centos 6.3, Apache/2.2.15, PHP 5.3.3 with 2GB Ram and 40GB disk.

I can't believe it should be struggling with that size file (~800mb) and those server settings?


回答1:


Do you have access to the http.conf if so you could try this.

This has been the issue for me sometimes to upload with over 500mb. Although I strongly suggest you should try and get it working with
the setting SecRequestBodyAccess "On".

I had to edit the Apache config file (http.conf) and change

SecRequestBodyAccess On

to

SecRequestBodyAccess Off

EDIT:

IF i remember correctly you could try the following.

SET

SecRequestBodyNoFilesLimit , the maximum value is 1073741824 (1Gb)


来源:https://stackoverflow.com/questions/12691381/http-413-request-entity-too-large

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!