- Max_execution_time = 30; Maximum execution time of each script, in seconds
- Max_input_time = 60; Maximum amount of time each script may spend parsing request data
- ; max_input_nesting_level = 64; Maximum input variable nesting level
- Memory_limit = 128M; Maximum amount of memory a script may consume (128MB)
- ; Maximum size of POST data that PHP would accept.
- Post_max_size = 105M
- ; Maximum allowed size for uploaded files.
- Upload_max_filesize = 100M
Copy CodeIn general, when uploading a file, you first need to ensure that you upload memory, view php.ini default configuration, memory_limit default is 128M, the amount of memory that can be consumed in a script. If the upload limit is 100M, then this large amount of memory is sufficient (or generally, for example, multi-file upload may not be enough). Second, adjust the execution time Set_time_limitmax_execution_time default setting is 30 seconds, for uploading 100M files, the current network situation, 30 seconds to upload 100M files is almost impossible, The 10M bandwidth is completely symmetrical, and a second and a trillion is 1.5. So this setting makes it difficult to estimate the actual execution time even if it is adjusted, and the adjustment is too long to be unfriendly to Apache. Therefore, it is recommended not to adjust the max_execution_time, but only in the PHP program: set_time_limit (0), to make temporary adjustments. Setting 0 means there is no time limit. Of course, from the point of view of program execution, set 0 is to solve the timeout problem, but in fact is not a good solution, if the program supports the continuation of the breakpoint, then set 600 seconds or 3,600 seconds also seems to be a better idea, time-out automatic breakpoint continued to pass. third, restart Apache Server service httpd Restart you may be interested in the article: Breaking the PHP upload file size limit configuration method php increase file upload size limit how to cancel php file upload can not exceed the limit of 2M php file Upload size limit method to modify the php file upload size limit method |