Nginx upload parameter problem, need to pay special attention to client_max_body_size this parameter, otherwise it will interrupt the request in Nginx.
General PHP configuration for file upload parameters php.ini file is as follows:
File_uploads on whether to allow the switch to upload files over HTTP. The default is on is the open upload_tmp_dir– file upload to the server to store temporary files, if not specified will be the system default temporary folder Upload_max_filesize 8m business, that is, the maximum size allowed to upload files. The default is 2mpost_max_size 8m refers to the maximum value that can be received by the form Post to PHP, including all values in the form. Default is 8M
Description
Generally, set up the above four parameters, in the network normal situation, upload <=8m files is not a problem
However, if you want to upload a large volume of >8m files, only set the above four items will certainly be able to pass. Unless your network really has a 100m/s upload speed, you still have to set the following parameters.
Max_execution_time 600 Maximum time value per php page (seconds), default 30 seconds Max_input_time 600 the maximum time per PHP page to receive data, default 60 seconds Memory_limit 8m Maximum memory consumed per PHP page, default 8M
No effect, because the webserver with Nginx, in the Nginx conf added a parameter:
The default is 1M, you need to increase the words.
Add a sentence in the nginx.conf
Client_max_body_size 30m;
Restart can
30m indicates the maximum upload 30M, how much to set the size of