(转)percona的安装、启动、停止

原文:https://blog.csdn.net/tanliqing2010/article/details/78758878


socket=/percona/3307/data/mysql.sock
[root@localhost ~]#
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
2. 定义一个`mysqld3307.service`文件
1
[root@localhost ~]# cat /usr/lib/systemd/system/mysqld3307.service
#
# Systemd service file for Percona Server
#
# # This service file is to start PS just with mysqld_safe
#
[Unit]
Description=MySQL Percona Server
After=network.target
After=syslog.target
[Install]
WantedBy=multi-user.target
Alias=mysql.service
[Service]
# Needed to create system tables etc.
ExecStartPre=/usr/bin/mysql_install_db --defaults-file=/root/my.cnf --user=mysql
# Start main service
ExecStart=/usr/bin/mysqld_safe --defaults-file=/root/my.cnf --user=mysql
# Don't signal startup success before a ping works
ExecStartPost=/usr/bin/mysqladmin --defaults-file=/root/my.cnf
# Give up if ping don't get an answer
TimeoutSec=600
Restart=always
PrivateTmp=false
[root@localhost ~]#
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
3. 我们需要创建这些文件夹和文件
[root@localhost ~]# mkdir -p /percona/3307/{data,log,run}
[root@localhost ~]# touch /percona/3307/log/mysqld.log
[root@localhost ~]# chown -R mysql:mysql /percona/3307
[root@localhost ~]#
1
2
3
4
4. 使用systemctl启动percona服务
---------------------
作者:tanliqing2010
来源:CSDN
原文:https://blog.csdn.net/tanliqing2010/article/details/78758878
版权声明:本文为博主原创文章,转载请附上博文链接!

posted @   liujiacai  阅读(565)  评论(0编辑  收藏  举报
编辑推荐:
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
· 没有源码,如何修改代码逻辑?
· 一个奇形怪状的面试题:Bean中的CHM要不要加volatile?
· [.NET]调用本地 Deepseek 模型
· 一个费力不讨好的项目,让我损失了近一半的绩效!
阅读排行:
· PowerShell开发游戏 · 打蜜蜂
· 在鹅厂做java开发是什么体验
· 百万级群聊的设计实践
· WPF到Web的无缝过渡:英雄联盟客户端的OpenSilver迁移实战
· 永远不要相信用户的输入:从 SQL 注入攻防看输入验证的重要性
历史上的今天:
2018-01-29 (转)50-100台中小规模网站集群搭建实战项目(超实用企业集群)
点击右上角即可分享
微信分享提示