How to increase memory size for phpmyadmin

前端 未结 7 1644
谎友^
谎友^ 2021-01-02 11:00

I am facing some problem when I am trying to import magento database on localhost. It just import 18 table but in actual it contain 383 approx table. It gives error given be

相关标签:
7条回答
  • 2021-01-02 11:12

    phpMyAdmin has been blowing memory limits on me lately (and I wasn't even importing/executing large amounts of data) so I've just tried the following in my config.inc.php

    $cfg['MemoryLimit'] = '128M';
    

    https://docs.phpmyadmin.net/en/latest/config.html#cfg_MemoryLimit

    0 讨论(0)
  • 2021-01-02 11:12

    You can change php.ini as other answers have mentioned. It can be ok on you localhost. But on webserver with more virtualhost you probably don't want to increase memory limit for all hosts (that's what directive in php.ini does).

    To increse memory limit only for given virtualhost edit virtualhost settings. For example:

    <VirtualHost *:443>
       #your virtualhost settings
       php_value memory_limit 64M #place any number you need
    </VirtualHost>
    

    Or, you can place the same php_value into your .htaccess file, but your virtualhost must allow to change this values.

    0 讨论(0)
  • 2021-01-02 11:20

    I was the same problem with the migration of database.

    Try to change configuration of export to build file with queries like this:

    INSERT INTO tbl_name VALUES (1,2,3)
    

    When I was creating queries like this one:

    INSERT INTO tbl_name (col_A,col_B) VALUES (1,2,3), (4,5,6), (7,8,9)
    

    queries were too big to allocate them in memory. When I changed it, there were a lot of small queries so there wasn't problem with memory.

    0 讨论(0)
  • 2021-01-02 11:25

    use this :

    c:\mysql\bin\> mysql -u username -p password database_name < filename.sql
    

    to import using command line

    or in php.ini

    memory_limit = 256M
    

    change this to some other larger value. But as Dan said using command line is preferable.

    0 讨论(0)
  • 2021-01-02 11:27

    In my case, it works by specifying pcre.jit=0 in the file php.ini.

    0 讨论(0)
  • 2021-01-02 11:28

    Try this http://dev.mysql.com/doc/refman/5.5/en/mysqlimport.html I was capable to import a 930 MB database.

    0 讨论(0)
提交回复
热议问题