当前位置:首页 > 服务器系统 > Centos > 正文内容

centos_7 mariadb 优化参数

一二三4年前 (2022-05-13)Centos1013
最大链接数
输入show variables like 'max_connections';一、修改mariadb.service
vim /usr/lib/systemd/system/mariadb.service
在[Service]下面加入以下内容

LimitNOFILE=30000
LimitNPROC=30000

二、修改/etc/my.cnf
vim /etc/my.cnf
在[mysqld]下,加入以下内容

max_connections=30000

输入show variables like 'max_connections';
优化超时时间
max_allowed_packet = 64M
wait_timeout = 2880000
interactive_timeout = 2880000
connect_timeout = 120


扫描二维码至手机访问

扫描二维码推送至手机访问。

版权声明:本文由一二三博客发布,如需转载请注明出处。

分享给朋友:
返回列表

上一篇:CENTOS7开机自启动脚本

没有最新的文章了...

相关文章

Linux(CENTOS7) 安装 Docker + 部署OnlyOffice

1、安装dockeryum install docker -y2、启动docker服务systemctl start docker3、查看docker...

Centos7 mariadb 10.5集群式部署

Centos7 mariadb 10.5集群式部署

1、环境准备准备三台虚拟机,分别安装CentOS7-7.7。服务器A:10.88.1.14 node1服务器B:10.88.1.15 node2服务器C:10.88.1.16 node3三台虚机上关闭...

CentOS查看端口使用情况

netstat -ntlp   //列出所有netstat -ntlp |grep 80    //显示80端口使用信息。...

Centos7 使用scp命令进行数据迁移

复制文件(本地>>远程):scp -P 33699 /etc/nginx/conf.d/default.conf root@10.88.1.23:/...

CentOS7 配置163 yum源

1、下载repo文件 wget http://mirrors.163.com/.help/CentOS7-Base-163.repo2、备份并替换系统的repo文件 cp Cent...

Centos 同步网络时间

Centos 同步网络时间yum install ntpdate -yntpdate ntp1.aliyun.com...