[How To] Increase import file size in PHPMyAdmin

By default when you want to import sql file size is 2MB in PHPMyAdmin.
That is PHP’s file upload limit.

To change maximum import file size do following steps.

  1. Find php.ini file
    $ locate php.ini
    /etc/php5/apache2/php.ini
    /etc/php5/cli/php.ini
    /usr/share/doc/php5-common/examples/php.ini-development
    /usr/share/php5/php.ini-production
    /usr/share/php5/php.ini-production-dist
    /usr/share/php5/php.ini-production.cli
    /var/www/php.ini
    [email protected]:/home/gevorgh#
  2. Edit php.ini file
    $ vim /etc/php5/apache2/php.ini
  3. Find following variables and change values as you need:
    post_max_size = 8M
    upload_max_filesize = 2M
    max_execution_time = 30
    max_input_time = 60
    memory_limit = 8M
  4. Restart apache to take effect
    $ service apache restart

In this example we used Ubuntu 11.10

4 Comments

  1. Arjun May 12, 2015 Reply
  2. Aldrin Hartunian January 22, 2016 Reply
  3. Jody Banim May 25, 2016 Reply
  4. Zain October 31, 2018 Reply

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.