PHPMYADMIN imports data up to 2M's solution

  • 2020-05-16 06:32:36
  • OfStack

PHPMYADMIN is often use a MySql management tools, backup and restore is an important function of PHPMYADMIN, when restore database often encountered such a situation: PHPMYADMIN restore database uploaded maximum limit: 2048 KB, a few big 1 database will not be able to deal with, or use other backups reduction tools such as the empire of the king, or export volume classification, so is there any way to still use PHPMYADMIN to deal with? Sure, follow these steps.

Taking WINDOWS2003 system as an example, it is divided into three parts: IIS part, PHP part and PHPMYADMIN part.

1. IIS part

1) to solve the problem that large capacity files cannot be uploaded in IIS 6.0:
1. Turn off iis admin service service in the service.
2. Find the metabase.xml file under windows/system32/inetsrv/.
3. Open it with a clipboard, find ASPMaxRequestEntityAllowed and change it to the desired value (default: 204800, i.e. : 200K).
4. Save, then restart iis admin service service and restart IIS.

2) to solve the problem that in IIS 6.0, it is not possible to download the attached steps with more than 4M:
1. Turn off iis admin service service in the service first.
2. Find the metabase.xml file under windows/system32/inetsrv/.
3. Open it with a clipboard, find AspBufferingLimit and change it to the desired value (default: 4194304, that is: 4MB).
4. Save, then restart iis admin service service and restart IIS.

2. PHP part

1. Find post_max_size, which means the maximum value that can be received to PHP from form POST, including all values in the form. The default value is 8M.
2. Find File Uploads, and first confirm file_uploads = on; Whether to allow files to be uploaded via HTTP or not, ON is on by default.
3. Find upload_max_filesize; The maximum file size allowed for upload. The default is 2M.
If you want to upload > 8M file, then only set the above three is still uncertain 1 can be. It is best to set the following parameters as well:
Find max_execution_time = 600; The maximum time value (seconds) for each PHP page to run, 30 seconds by default.
max_input_time = 600; The maximum time required for each PHP page to receive data, 60 seconds by default.
memory_limit = 8 M; Maximum memory consumed per PHP page, 8M by default.

3. PHPMYADMIN part

Open import.php with a clipboard:
1. Find $memory_limit, default is $memory_limit = 2 * 1024 * 1024; Fix it yourself.
2. There is the same statement in the position of the 34 lines below.

Through the modification of the above three parts, the problem that the maximum data imported by PHPMYADMIN is 2M can be solved perfectly.

Related articles: