前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >mysql 迁移7

mysql 迁移7

作者头像
franket
发布2022-03-22 11:54:47
1.4K0
发布2022-03-22 11:54:47
举报
文章被收录于专栏:技术杂记

修改zabbix统计数据过期时间

代码语言:javascript
复制
[root@new-master mysql]# vim  /var/lib/zabbix/percona/scripts/get_mysql_stats_wrapper.sh
[root@new-master mysql]# grep 120  /var/lib/zabbix/percona/scripts/get_mysql_stats_wrapper.sh
    if [ `expr $TIMENOW - $TIMEFLM` -gt 120 ]; then
[root@new-master mysql]# 

修改之前是300,也就是5分钟,这个监控粒度太粗,所以改为120


安装percona-xtrabackup

代码语言:javascript
复制
[root@slave01 percona56]# rpm -ivh  percona-xtrabackup-2.3.2-1.el6.x86_64.rpm
warning: percona-xtrabackup-2.3.2-1.el6.x86_64.rpm: Header V4 DSA/SHA1
Signature, key ID cd2efd2a: NOKEY
error: Failed dependencies:
	libev.so.4()(64bit) is needed by percona-xtrabackup-2.3.2-1.el6.x86_64
[root@slave01 percona56]# yum install libev
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.opencas.cn
 * epel: mirrors.opencas.cn
 * extras: mirror.bit.edu.cn
 * updates: mirrors.opencas.cn
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package libev.x86_64 0:4.03-3.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

=========================================================================================================================
 Package                    Arch                        Version
Repository                 Size
=========================================================================================================================
Installing:
 libev                      x86_64                      4.03-3.el6
epel                      113 k

Transaction Summary
=========================================================================================================================
Install       1 Package(s)

Total download size: 113 k
Installed size: 151 k
Is this ok [y/N]: y
Downloading Packages:
libev-4.03-3.el6.x86_64.rpm
| 113 kB     00:00     
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Warning: RPMDB altered outside of yum.
** Found 11 pre-existing rpmdb problem(s), 'yum check' output follows:
Percona-Server-devel-51-5.1.73-rel14.11.603.rhel6.x86_64 has missing requires
of libmysqlclient.so.16()(64bit)
Percona-Server-devel-51-5.1.73-rel14.11.603.rhel6.x86_64 has missing requires
of libmysqlclient_r.so.16()(64bit)
perl-DBD-MySQL-4.013-3.el6.x86_64 has missing requires of
libmysqlclient.so.16()(64bit)
perl-DBD-MySQL-4.013-3.el6.x86_64 has missing requires of
libmysqlclient.so.16(libmysqlclient_16)(64bit)
php-mysql-5.3.3-40.el6_6.x86_64 has missing requires of
libmysqlclient.so.16()(64bit)
php-mysql-5.3.3-40.el6_6.x86_64 has missing requires of
libmysqlclient.so.16(libmysqlclient_16)(64bit)
2:postfix-2.6.6-6.el6_5.x86_64 has missing requires of
libmysqlclient.so.16()(64bit)
2:postfix-2.6.6-6.el6_5.x86_64 has missing requires of
libmysqlclient.so.16(libmysqlclient_16)(64bit)
2:postfix-2.6.6-6.el6_5.x86_64 has missing requires of mysql-libs
sysbench-0.4.12-5.el6.x86_64 has missing requires of
libmysqlclient_r.so.16()(64bit)
sysbench-0.4.12-5.el6.x86_64 has missing requires of
libmysqlclient_r.so.16(libmysqlclient_16)(64bit)
  Installing : libev-4.03-3.el6.x86_64
1/1 
  Verifying  : libev-4.03-3.el6.x86_64
1/1 

Installed:
  libev.x86_64 0:4.03-3.el6                                                                                              

Complete!
[root@slave01 percona56]# rpm -ivh  percona-xtrabackup-2.3.2-1.el6.x86_64.rpm
warning: percona-xtrabackup-2.3.2-1.el6.x86_64.rpm: Header V4 DSA/SHA1
Signature, key ID cd2efd2a: NOKEY
Preparing...                ########################################### [100%]
	file /usr/bin/innobackupex from install of
percona-xtrabackup-2.3.2-1.el6.x86_64 conflicts with file from package
xtrabackup-1.6.7-356.rhel6.x86_64
	file /usr/bin/xtrabackup from install of
percona-xtrabackup-2.3.2-1.el6.x86_64 conflicts with file from package
xtrabackup-1.6.7-356.rhel6.x86_64
[root@slave01 percona56]# rpm -qa | grep backup
xtrabackup-1.6.7-356.rhel6.x86_64
[root@slave01 percona56]# rpm -e xtrabackup-1.6.7-356.rhel6.x86_64 
[root@slave01 percona56]# rpm -ivh  percona-xtrabackup-2.3.2-1.el6.x86_64.rpm
warning: percona-xtrabackup-2.3.2-1.el6.x86_64.rpm: Header V4 DSA/SHA1
Signature, key ID cd2efd2a: NOKEY
Preparing...                ########################################### [100%]
   1:percona-xtrabackup     ########################################### [100%]
[root@slave01 percona56]# 
[root@slave01 percona56]# innobackupex --version
innobackupex version 2.3.2 Linux (x86_64) (revision id: 306a2e0)
[root@slave01 percona56]# 

slave上确保安装好 percona-xtrabackup 软件

本文系转载,前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文系转载前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
目录
  • 修改zabbix统计数据过期时间
  • 安装percona-xtrabackup
相关产品与服务
云数据库 MySQL
腾讯云数据库 MySQL(TencentDB for MySQL)为用户提供安全可靠,性能卓越、易于维护的企业级云数据库服务。其具备6大企业级特性,包括企业级定制内核、企业级高可用、企业级高可靠、企业级安全、企业级扩展以及企业级智能运维。通过使用腾讯云数据库 MySQL,可实现分钟级别的数据库部署、弹性扩展以及全自动化的运维管理,不仅经济实惠,而且稳定可靠,易于运维。
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档