Import Large MySQL Databases

METOD TWO: https://www.youtube.com/watch?v=kQSFOhaMss0

Method One: Using BigDump http://www.ozerov.de/bigdump/usage/

Step 1 : Install bigdump: http://www.ozerov.de/bigdump/

  • Make sure the XAMPP is on
  • Extract the bigdump to - the folder look like this: yourdrupalsite/bigdump/bigdump.php
  • Extract the database that to be import
  • Put the database that want to import to the same darectory, so the folder look like this:

yourdrupalsite/bigdump

  • bigdump.php
  • YOUR_DATABASENAME_TO_IMPORT

Edit the bigdump.php file as below: -

// Database configuration

$db_server   = 'localhost';
$db_name     = 'YOUR_DATABASE_NAME(eg: mydatabase1)';  (LOCATION DATABASE)
$db_username = 'root';
$db_password = 'YOUR_DATABASE_PASSWORD'; 

// Connection charset should be the same as the dump file charset (utf8, latin1, cp1251, koi8r etc.)
// See http://dev.mysql.com/doc/refman/5.0/en/charset-charsets.html for the full list
// Change this if you have problems with non-latin letters

$db_connection_charset = 'utf8';

// OPTIONAL SETTINGS 

$filename           = 'YOUR_DATABASE_NAME(eg: mydatabase2.sql)';   (SOURCE DATABASE) // Specify the dump filename to suppress the file selection dialog

Step 2 : Start import by run: http://www.yoursitename/bigdump/bigdump.php. Wait till importing process done  

IMPORTANT: Remove bigdump.php and your dump files from the web server after complete the process


Method Two: Edit the my.imi file on mysql

# The MySQL server
[mysqld]
port= 3306
socket = "D:/xampp/mysql/mysql.sock"
basedir = "D:/xampp/mysql" 
tmpdir = "D:/xampp/tmp" 
datadir = "D:/xampp/mysql/data"
pid_file = "mysql.pid"
# enable-named-pipe
key_buffer = 16M
max_allowed_packet = 64M
sort_buffer_size = 512K
net_buffer_length = 8K
read_buffer_size = 256K
read_rnd_buffer_size = 512K
myisam_sort_buffer_size = 8M ** Change this value to 50M for example
log_error = "mysql_error.log"

After that Stop the Mysql & Start again


other reading:

http://www.c-sharpcorner.com/article/how-to-import-large-sql-database-fi...

http://ourcodeworld.com/articles/read/355/how-to-import-a-mysql-database...