成都网站建设设计

将想法与焦点和您一起共享

MysqlMHA部署中怎么进行MHA软件安装-创新互联

Mysql MHA部署中怎么进行MHA软件安装,很多新手对此不是很清楚,为了帮助大家解决这个难题,下面小编将为大家详细讲解,有这方面需求的人可以来学习下,希望你能有所收获。

专注于为中小企业提供成都网站制作、网站建设服务,电脑端+手机端+微信端的三站合一,更高效的管理,为中小企业海南州免费做网站提供优质的服务。我们立足成都,凝聚了一批互联网行业人才,有力地推动了超过千家企业的稳健成长,帮助中小企业通过网站建设实现规模扩充和转变。

Mysql MHA部署-MHA软件安装

架构说明:

Mysql MHA部署中怎么进行MHA软件安装

参考: http://www.zhaibibei.cn/mysql/mha/

1 MHA Node安装(rac1,rac2,rac3,rac4)

我们需要在所有机器上安装Node软件(包括管理节点)

安装之前我们需要先安装相关perl的依赖包

下载安装包:

这里使用yum安装,未联网的请使用操作系统ISO中的软件包配置本地yum源

安装包网盘链接: https://pan.baidu.com/s/18H12bTIYHi2H0dXs2DI7NA 提取码: mwkq

[root@rac1 mha]# pwd

/package/mysql/MHA/mha

[root@rac1 mha]# ll -rth

total 700K

-rw-r--r-- 1 root root  400 Mar 14 13:42 download.txt

-rw-r--r-- 1 root root  84K Mar 14 13:42 mha4mysql-manager-0.56-0.el5.noarch.rpm

-rw-r--r-- 1 root root  86K Mar 14 13:42 mha4mysql-manager-0.56-0.el6.noarch.rpm

-rw-r--r-- 1 root root 112K Mar 14 13:42 mha4mysql-manager-0.56.tar.gz

-rw-r--r-- 1 root root  80K Mar 14 13:42 mha4mysql-manager-0.57-0.el7.noarch.rpm

-rw-r--r-- 1 root root 116K Mar 14 13:42 mha4mysql-manager-0.57.tar.gz

-rw-r--r-- 1 root root  36K Mar 14 13:42 mha4mysql-node-0.56-0.el5.noarch.rpm

-rw-r--r-- 1 root root  36K Mar 14 13:42 mha4mysql-node-0.56-0.el6.noarch.rpm

-rw-r--r-- 1 root root  49K Mar 14 13:42 mha4mysql-node-0.56.tar.gz

-rw-r--r-- 1 root root  35K Mar 14 13:42 mha4mysql-node-0.57-0.el7.noarch.rpm

-rw-r--r-- 1 root root  54K Mar 14 13:42 mha4mysql-node-0.57.tar.gz

开始安装:

[root@rac1 mha]# yum install perl-DBD-MySQL

Loaded plugins: fastestmirror, langpacks

Loading mirror speeds from cached hostfile

file:///mnt/repodata/repomd.xml: [Errno 14] curl#37 - "Couldn't open file /mnt/repodata/repomd.xml"

Trying other mirror.

Package perl-DBD-MySQL-4.023-6.el7.x86_64 already installed and latest version

Nothing to do

[root@rac1 mha]# rpm -ivh mha4mysql-node-0.56-0.el6.noarch.rpm

Preparing...                          ################################# [100%]

Updating / installing...

   1:mha4mysql-node-0.56-0.el6        ################################# [100%]

2 MHA Manager安装

我们需要在manager上安装Manager软件

同样安装Manager需要一些依赖包

这里使用yum安装,未联网的请使用操作系统ISO中的软件包配置本地yum源

一些rpm包包含在上面的网盘中

由于依赖有点多,大家可以按照我下面的步骤进行,注意有的命令最后有星号

root用户

rpm -ivh perl-Config-Tiny-2.12-1.el6.rfx.noarch.rpm

rpm -ivh perl-Time-HiRes-1.9724-1.el6.rfx.x86_64.rpm

yum install perl-Params-Validate

rpm -ivh perl-Log-Dispatch-2.26-1.el6.rf.noarch.rpm

yum install perl-Parallel-ForkManager*

rpm -ivh mha4mysql-manager-0.56-0.el6.noarch.rpm

其中perl-Parallel-ForkManager下载地址:

https://centos.pkgs.org/7/epel-aarch74/perl-Parallel-ForkManager-1.18-2.el7.noarch.rpm.html

Binary Packagehttps://download-ib01.fedoraproject.org/pub/epel/7/aarch74/Packages/p/perl-Parallel-ForkManager-1.18-2.el7.noarch.rpm

Source Packagehttps://download-ib01.fedoraproject.org/pub/epel/7/SRPMS/Packages/p/perl-Parallel-ForkManager-1.18-2.el7.src.rpm

或者全部手动安装

rpm -ivh perl-Config-Tiny-2.12-7.1.el6.noarch.rpm

rpm -ivh mha4mysql-node-0.56-0.el6.noarch.rpm

rpm -ivh perl-DBD-MySQL-4.013-3.el6.i686.rpm

rpm -ivh compat-db43-4.3.29-15.el6.x86_64.rpm

rpm -ivh perl-Mail-Sender-0.8.16-3.el6.noarch.rpm

rpm -ivh perl-Parallel-ForkManager-0.7.9-1.el6.noarch.rpm

rpm -ivh perl-TimeDate-1.16-11.1.el6.noarch.rpm

rpm -ivh perl-MIME-Types-1.28-2.el6.noarch.rpm

rpm -ivh perl-MailTools-2.04-4.el6.noarch.rpm

rpm -ivh perl-Email-Date-Format-1.002-5.el6.noarch.rpm

rpm -ivh perl-Params-Validate-0.92-3.el6.

rpm -ivh perl-Params-Validate-0.92-3.el6.x86_64.rpm

rpm -ivh perl-MIME-Lite-3.027-2.el6.noarch.rpm

rpm -ivh perl-Mail-Sendmail-0.79-12.el6.noarch.rpm

rpm -ivg perl-Log-Dispatch-2.27-1.el6.noarch.rpm

rpm -ivh mha4mysql-manager-0.56-0.el6.noarch.rpm

3. 验证安装

到这里我们已经安装完成了,下面来验证下

[root@rac4 mha]# rpm -ql mha4mysql-manager

/usr/bin/masterha_check_repl

/usr/bin/masterha_check_ssh

/usr/bin/masterha_check_status

/usr/bin/masterha_conf_host

/usr/bin/masterha_manager

/usr/bin/masterha_master_monitor

/usr/bin/masterha_master_switch

/usr/bin/masterha_secondary_check

/usr/bin/masterha_stop

/usr/share/man/man1/masterha_check_repl.1.gz

/usr/share/man/man1/masterha_check_ssh.1.gz

/usr/share/man/man1/masterha_check_status.1.gz

/usr/share/man/man1/masterha_conf_host.1.gz

/usr/share/man/man1/masterha_manager.1.gz

/usr/share/man/man1/masterha_master_monitor.1.gz

/usr/share/man/man1/masterha_master_switch.1.gz

/usr/share/man/man1/masterha_secondary_check.1.gz

/usr/share/man/man1/masterha_stop.1.gz

/usr/share/perl5/vendor_perl/MHA/Config.pm

/usr/share/perl5/vendor_perl/MHA/DBHelper.pm

/usr/share/perl5/vendor_perl/MHA/FileStatus.pm

/usr/share/perl5/vendor_perl/MHA/HealthCheck.pm

/usr/share/perl5/vendor_perl/MHA/ManagerAdmin.pm

/usr/share/perl5/vendor_perl/MHA/ManagerAdminWrapper.pm

/usr/share/perl5/vendor_perl/MHA/ManagerConst.pm

/usr/share/perl5/vendor_perl/MHA/ManagerUtil.pm

/usr/share/perl5/vendor_perl/MHA/MasterFailover.pm

/usr/share/perl5/vendor_perl/MHA/MasterMonitor.pm

/usr/share/perl5/vendor_perl/MHA/MasterRotate.pm

/usr/share/perl5/vendor_perl/MHA/SSHCheck.pm

/usr/share/perl5/vendor_perl/MHA/Server.pm

/usr/share/perl5/vendor_perl/MHA/ServerManager.pm

[root@rac4 mha]# rpm -ql mha4mysql-node

/usr/bin/apply_diff_relay_logs

/usr/bin/filter_mysqlbinlog

/usr/bin/purge_relay_logs

/usr/bin/save_binary_logs

/usr/share/man/man1/apply_diff_relay_logs.1.gz

/usr/share/man/man1/filter_mysqlbinlog.1.gz

/usr/share/man/man1/purge_relay_logs.1.gz

/usr/share/man/man1/save_binary_logs.1.gz

/usr/share/perl5/vendor_perl/MHA/BinlogHeaderParser.pm

/usr/share/perl5/vendor_perl/MHA/BinlogManager.pm

/usr/share/perl5/vendor_perl/MHA/BinlogPosFindManager.pm

/usr/share/perl5/vendor_perl/MHA/BinlogPosFinder.pm

/usr/share/perl5/vendor_perl/MHA/BinlogPosFinderElp.pm

/usr/share/perl5/vendor_perl/MHA/BinlogPosFinderXid.pm

/usr/share/perl5/vendor_perl/MHA/NodeConst.pm

/usr/share/perl5/vendor_perl/MHA/NodeUtil.pm

/usr/share/perl5/vendor_perl/MHA/SlaveUtil.pm

看完上述内容是否对您有帮助呢?如果还想对相关知识有进一步的了解或阅读更多相关文章,请关注创新互联-成都网站建设公司行业资讯频道,感谢您对创新互联的支持。


文章标题:MysqlMHA部署中怎么进行MHA软件安装-创新互联
URL分享:http://chengdu.cdxwcx.cn/article/dgoccs.html