- 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 = 128 M; Maximum amount of memory a script may consume (128 MB)
- ; Maximum size of POST data that PHP will accept.
- Post_max_size = 105 M
- ; Maximum allowed size for uploaded files.
- Upload_max_filesize = 100 M
-
Generally, when uploading files, you must first ensure the upload memory. check the default configuration of PHP. INI. the default value of memory_limit is 128 MB, which can consume memory for one script execution. If the upload limit is 100 MB, the memory size is sufficient (generally speaking, for example, it may not be enough to upload multiple files simultaneously ). II. adjust the execution time set_time_limitMax_execution_time is set to 30 seconds by default. For uploading MB files, it is almost impossible to upload MB files in 30 seconds in terms of network conditions. The bandwidth of 10 Mb is completely symmetric, it also takes one minute and a half minutes to get one megabits per second. Therefore, this setting is difficult to estimate the actual execution time even if it is adjusted, and it is too long for APACHE to be unfriendly. Therefore, we recommend that you do not adjust max_execution_time, but use set_time_limit (0); in the PHP program for temporary adjustment. Set 0 to no time limit. Of course, from the perspective of program execution, setting 0 solves the timeout problem, but it is not a good solution. if the program supports resumable data transfer, setting 600 seconds or 3600 seconds also seems to be a better idea. when a timeout occurs, the data can be resumed automatically. III. restart the APACHE serverService httpd restart articles you may be interested in: breakthrough php file upload size limit configuration method PHP increase file upload size limit how to cancel php file Upload cannot exceed 2 MB limit breakthrough PHP file upload size limit method to modify php file upload size limit method |