免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3489 | 回复: 4
打印 上一主题 下一主题

mysql5.6.13批量插入时慢 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2014-05-04 13:15 |只看该作者 |倒序浏览
innodb批量插入200条数据时耗时3秒左右,哪位高手帮忙分析一下配置问题?
innodb_buffer_pool_size = 36G
innodb_use_sys_malloc
innodb_log_file_size = 1024M
innodb_log_buffer_size = 16M
innodb_flush_log_at_trx_commit = 2
innodb_lock_wait_timeout = 50
innodb_open_files=4096
innodb_data_home_dir = /data/mysql/data
innodb_data_file_path = ibdata1:10M:autoextend
innodb_log_group_home_dir = /data/mysql/data
explicit_defaults_for_timestamp
key_buffer_size = 4096M
# Remove leading # to turn on a very important data integrity option: logging
# changes to the binary log between backups.
log-bin = /data/mysqllog/mysql-bin
relay-log=/data/mysqllog/relay-bin
# These are commonly set, remove the # and set as required.
basedir = /usr/local/mysql
datadir = /data/mysql
port = 3306
server_id = 99
# socket = .....
expire_logs_days = 3
event_scheduler = on

sort_buffer_size = 16M
read_rnd_buffer_size = 16M
net_buffer_length = 32K
read_buffer_size = 4M
myisam_sort_buffer_size = 8M
max_allowed_packet = 512M


innodb_file_per_table
log-bin-trust-function-creators=1
lower_case_table_names=1
max_connections = 15000
log-error=/data/mysqllog/mysql.err.log
max_heap_table_size = 256M
join_buffer_size = 8M
thread_cache_size = 1200
thread_stack = 256K
query_cache_type = 1
query_cache_size = 1024M
query_cache_limit = 4M
tmp_table_size = 128M
#myisam_sort_buffer_size = 64M
back_log = 1024
long_query_time = 10
open_files_limit = 10240
interactive_timeout = 120
wait_timeout = 120
external-locking = FALSE
#table_cache = 1024M
skip_name_resolve
expire_logs_days=3
binlog_format=mixed

long_query_time = 2
slow_query_log_file = /data/mysqllog/slow.log
slow_query_log=on

论坛徽章:
0
2 [报告]
发表于 2014-05-05 13:58 |只看该作者
木有人碰到过么?

论坛徽章:
0
3 [报告]
发表于 2014-05-05 15:37 |只看该作者
@hyong2011

你为什么要导入呢?慢会有什么影响吗?

论坛徽章:
0
4 [报告]
发表于 2014-05-29 10:44 |只看该作者
大量插入的话细查一下query cache,关了试试?

论坛徽章:
0
5 [报告]
发表于 2014-05-29 11:41 |只看该作者
问题已查明,是PDO版本不匹配导致的问题
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP