andybest
V2EX  ›  问与答

1.5G的数据往MySQL5.5 InnoDB里导,两天了,还未导完。。。

  •  
  •   andybest · Aug 27, 2013 · 4298 views
    This topic created in 4838 days ago, the information mentioned may be changed or developed.
    root 4096 0.3 0.0 14116 680 ? S Aug26 5:32 \_ /usr/mysql/bin/mysql -f -S /tmp/mysql.sock db

    Aug26 5:32开始导入...

    my.cnf 配置:
    innodb_file_per_table = 1
    innodb_file_format=barracuda
    innodb_buffer_pool_size = 200M
    innodb_log_file_size = 50M
    innodb_data_file_path = ibdata1:10M:autoextend
    innodb_additional_mem_pool_size = 16M
    innodb_file_io_threads = 4
    innodb_thread_concurrency = 8
    innodb_flush_log_at_trx_commit = 0
    innodb_log_buffer_size = 16M
    innodb_log_files_in_group = 3
    innodb_max_dirty_pages_pct = 90
    innodb_lock_wait_timeout = 120

    进mysql看了下进程,数据大概导到一半了。。。这怎么破。。。
    12 replies  •  1970-01-01 08:00:00 +08:00
    alexmercer
    alexmercer
    Aug 27, 2013
    1
    ...再等两天
    halfbloodrock
    halfbloodrock
    Aug 27, 2013❤️1
    2
    show full processlist 看看是不是有一些wait。。
    powerfj
    powerfj
    Aug 27, 2013❤️1
    3
    有索引吧,貌似说load file会好
    andybest
    andybest
    OP
    Aug 27, 2013
    4
    @halfbloodrock 谢谢,没有,就一个进程,一直在insert,服务器没有其他任何进程,独服,CPU 30%左右

    @powerfj 请问怎么load file?
    Showfom
    Showfom
    PRO
    Aug 28, 2013
    7
    这个和硬盘的读写速度有关,换 SSD 吧
    daoluan
    daoluan
    Aug 29, 2013
    8
    其他公司比你大的数量级,他们是如何做到的?是不是机器多?
    welsonla
    welsonla
    Aug 29, 2013
    9
    导出成sql文件,在用source命令导入
    xmbaozi
    xmbaozi
    Aug 29, 2013
    10
    把索引、唯一 先去掉
    likexian
    likexian
    Aug 29, 2013
    11
    肯定是索引了,把索引先删除,导入再重建
    itaotao
    itaotao
    Aug 29, 2013
    12
    我都是直接把那些二进制文件直接拷贝过去
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   4351 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 69ms · UTC 07:20 · PVG 15:20 · LAX 23:20 · JFK 02:20
    ♥ Do have faith in what you're doing.