Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Maximum execution time of 120 seconds exceeded in yii2 [duplicate]

Tags:

I upload an excel file with 1000 rows, by default I have just 2 min in execution time, with that time I can upload 400 records. I get this error Maximum execution time of 120 seconds exceeded

How i can modify this period in yii2 framework ?

like image 728
Malki Mohamed Avatar asked May 09 '16 18:05

Malki Mohamed


People also ask

What is the maximum execution time of 30 seconds exceeded?

The easiest solution to this problem is increasing the time limit. Changing it to 300 seconds (5 minutes) is often more than enough. If that doesn't help, you can try setting even higher values for maximum execution time.

What is Max_execution_time in PHP INI?

max_execution_time int. This sets the maximum time in seconds a script is allowed to run before it is terminated by the parser. This helps prevent poorly written scripts from tying up the server. The default setting is 30 . When running PHP from the command line the default setting is 0 .


1 Answers

You need to change that in the php.ini:

max_execution_time = 500 

or in your php script:

set_time_limit(500); //  
like image 101
ScaisEdge Avatar answered Oct 07 '22 22:10

ScaisEdge