A solution for inexplicable errors in Drupal adding modules (often in large number of modules)

  • 2020-03-31 21:36:47
  • OfStack

The status is as follows:
1. After clicking the "guarantee" button, it cannot be transferred to the page normally, and a blank page appears;
2. Refresh the page, many items in the navigation are not available, and the existing items cannot be clicked into the normal page.
Tested did not find any problem for many times, reshipment, testing for many times, finally there was a error page tip: "drupal Maximum execution time of 30 seconds exceeded the database in/mysqli. Inc", a look at this file, finally found a little bit of light. Baidu found three solutions, one by one, to solve the problem.
Write down these methods:
Method 1: change the php.ini file for PHP to make the value of max_execution_time larger.
Method 2: change with PHP code and set it up by calling ini_set(), such as ini_set('max_execution_time', 1000), which can be added to Drupal settings.php, but it is best to cancel the function after the operation.
Method 3 :(not tried) find the my.ini(my.cnf) file in the root directory of mysql, open it and find the last line
[mysqld]
Port = 3306
Add:
Set -variable = max_allowed_packet= set a little bit larger like 10M

Related articles: