美文网首页
重要参数

重要参数

作者: 古飞_数据 | 来源:发表于2021-07-31 16:33 被阅读0次
    max_connections
    max_user_connextions
    back_log
    thread_pool_max_threads 
    innodb_thread_concurrency
    innodb_concurrency_tickets
    sync_binlog    
    innodb_flush_log_at_trx_commit
    

    最大连接数,默认151,有效范围 1-100000,主从都需要单独设置

    max_connections = 3000
    max_user_connextions = 2980
    

    256-64M 超出临时文件

    innodb_buffer_pool

    256k3000 = 760M
    64M
    3000 =192G

    100台 300qps 20ms

    300/50 =6个连接

    back_log TCP/IP 三次握手

    sysctl.conf

    Innodb线程并发数
    thread_pool_max_threads = 2000 //线程池 ,企业版,percona,Mariadb
    innodb_thread_concurrency = 32 // 默认 0 ,看cpu个数

    show engine innodb status;
    show processlist;

    innodb_concurrency_tickets = 5000 // CPU切片轮询数
    双一参数,保证数据一致性
    sync_binlog = 1
    innodb_flush_log_at_trx_commit = 1
    ==============================================================

    相关文章

      网友评论

          本文标题:重要参数

          本文链接:https://www.haomeiwen.com/subject/qsdpmltx.html