How to Overcome the 2MB Import File Size Limit in PHPMyAdmin?

DDD
Release: 2024-10-27 14:20:29
Original
765 people have browsed it

How to Overcome the 2MB Import File Size Limit in PHPMyAdmin?

Resolving the Import File Size Limit in PHPMyAdmin

Despite modifying the php.ini parameters such as upload_max_filesize and post_max_size, users may encounter a persistent 2MB import file size limit in PHPMyAdmin. This issue stems from an incorrect configuration in the php.ini file.

Resolution:

On your server, locate the php.ini file and proceed with the following steps:

  • Navigate to the php.ini file using your preferred text editor. For example, use "sudo gedit /etc/php5/apache2/php.ini" or "sudo gedit /etc/php/7.0/apache2/php.ini" for Apache2 with PHP5 or PHP7, respectively.
  • Locate the "post_max_size" entry. Enter a value that exceeds the size of the database you intend to import. For example, "post_max_size = 25M" for a 15MB database.
  • Next, locate the "memory_limit" entry and assign it a larger value than post_max_size.
  • Finally, ensure that the "upload_max_filesize" value is less than post_max_size.
  • The values should follow the order from largest to smallest:

    memory_limit
    post_max_size
    upload_max_filesize
    Copy after login
  • Save the php.ini file.
  • Restart Apache using "sudo /etc/init.d/apache2 restart".
  • Note: It is crucial to restart Apache services for the changes to take effect.

Once these steps are complete, you should be able to import files larger than 2MB into PHPMyAdmin.

The above is the detailed content of How to Overcome the 2MB Import File Size Limit in PHPMyAdmin?. For more information, please follow other related articles on the PHP Chinese website!

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!