Export a large MySQL table as multiple smaller files

前端 未结 7 1354
你的背包
你的背包 2020-12-28 09:26

I have a very large MySQL table on my local dev server: over 8 million rows of data. I loaded the table successfully using LOAD DATA INFILE.

I now wish to export thi

7条回答
  •  难免孤独
    2020-12-28 10:08

    Use mysqldump to dump the table into a file. Then use tar with -z option to zip the file. Transfer it to your remote server (with ftp, sftp or other file transfer utility). Then untar the file on remote server Use mysql to import the file.

    There is no reason to split the original file or to export in multiple files.

提交回复
热议问题