Solution: phpMyAdmin cannot import database files larger than 2 MB

Source: Internet
Author: User
Tags ini safe mode zip import database phpmyadmin

When we use phpMyAdmin to import backup database files, only files smaller than 2 MB can be uploaded by default. But usually our database backup files are larger than 2 MB. What should I do? In fact, you only need to modify a parameter in the php. Ini file.

Solution 1: You have the server modification permission.

Taking the WAMP environment built using USB webserver as an example, the php. Ini file exists in two places: USB webserversettings and USB webserver 8php.

Edit php. ini and find:

The code is as follows: Copy code

Upload_max_filesize = 2 M

Increase 2 m to 20 m or a greater value.

Save the file, restart the USB webserver, or run Mysql again. You can see that the maximum limit has been increased ......

Slow down, not 20 M, but 8 M. As shown in the following figure:

Three good citizens do not know the reason. It is enough for the moment. If you know anything, please explain it to three good citizens. Thank you!

Solution 2: If you do not have the server modification permission, we only need to find another solution.

 

I. Use EmpireBak to back up data
1. First download and install EmpireBak)
Empire backup King download address: http://www.phome.net/ebak2010/EmpireBak2010.zip
Step 2: upload the package
Decompress the downloaded package and upload all files and directories in the upload Directory of the installation package to the server. VM users can upload files to the website root directory (delete after use ), for some users who have their own servers or VPS, you can also independently set a second-level domain name or use the domain name and Port method for installation (this process will not be emphasized here ).
Step 2: Set directory properties
Before using EmpireBak, you must set related directory properties so that the data files can be correctly read and written by EmpireBak. Log on to your server using FTP, and set the following file/directory attribute on the server to 777.
Directory file name description
Bdata backup directory
Data backup directory in bdata/safemod safe mode
Class/config. php configuration file
Setsave save settings directory
Setsave/def default backup setting file
Zip package storage directory
Tmp temporary file directory
Step 2: log on to the background
Run index. php in the browser to access http: // your domain name/installation directory/index. php.
(The default administrator account and password are admin and 123456 respectively)
After logon, you can complete the installation by changing the account password, verifying the random code, and setting the database.
2. Go to EmpireBak to set parameters and back up
Step 2: Set parameters. As shown in the following figure:
Step 2: Start data backup. You can configure parameters as needed. The default value is used here. As shown in the following figure:
Step 2. After setting the parameters, click start backup at the bottom of the page and click OK.
Step 5: back up the database. If the data volume is large, be patient.
Step 2. Manage the backup directory and package and download it to your local device. As shown in the following figure:
The whole site database backup is complete!
II. Use EmpireBak to restore data
Step 2,
Open the menu to go to the recover data column.
Recover data source directory: Select the directory of your latest backup database.
Database to be imported: Select the database to be restored.
Click Start Recovery, and then click OK!
As shown in the following figure:
Step 2,
After you click "OK" to start recovery, wait patiently for recovery. If the data volume is large, it may take a little longer.
Then it is restored. Open your website to check whether the data is normal.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.