Last active
January 24, 2022 23:16
-
-
Save rubi022/bb1214b22b928a5c560151b82167204a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 14gb file mysql | |
` | |
mysql -u root -p | |
set global net_buffer_length=1000000; --Set network buffer length to a large byte number | |
set global max_allowed_packet=1000000000; --Set maximum allowed packet size to a large byte number | |
SET foreign_key_checks = 0; --Disable foreign key checking to avoid delays,errors and unwanted behaviour | |
source file.sql --Import your sql dump file | |
SET foreign_key_checks = 1; --Remember to enable foreign key checks when procedure is complete! | |
` | |
https://stackoverflow.com/questions/13717277/how-can-i-import-a-large-14-gb-mysql-dump-file-into-a-new-mysql-database |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Over mariadb, max values are checked : set global net_buffer_length=1048576; set global max_allowed_packet=1073741824;
Link Stackoverflow