mysql高可用方案探究
1 前言........................................................................................................................................... 3
2 lvs keepalived mysql单点写入主主同步高可用方案 ...................................................... 3
2.1 方案简介 ....................................................................................................................... 3
2.2 方案架构图 ................................................................................................................... 3
2.3 方案优缺点 ................................................................................................................... 4
2.4 方案实战 ....................................................................................................................... 4
2.4.1 适用场景 ........................................................................................................... 4
2.4.2 实战环境介绍 ................................................................................................... 4
2.4.3 mysql的安装和配置 ........................................................................................ 4
2.4.4 mysql的主主同步配置 .................................................................................... 4
2.4.5 lvs的安装 ........................................................................................................ 4
2.4.6 keepalived的安装 .......................................................................................... 5
2.4.7 keepalived的配置 .......................................................................................... 5
2.4.8 master和backup的realserver的配置 ...................................................... 7
2.4.9 master和backup的启动 ................................................................................ 8
2.4.10 高可用方案测试 .............................................................................................. 9
3 lvs keepalived mysql单点写入读负载均衡主主同步高可用方案 .................................. 9
3.1 方案简介 ....................................................................................................................... 9
3.2 方案架构图 ................................................................................................................... 9
3.3 方案优缺点 ................................................................................................................... 9
3.4 适用场景 ..................................................................................................................... 10
3.5 方案实战 ..................................................................................................................... 10
3.5.1 实战环境介绍 ................................................................................................. 10
3.5.2 mysql的安装和配置 ...................................................................................... 10
3.5.3 mysql的主主同步配置 .................................................................................. 10
3.5.4 lvs的安装 ...................................................................................................... 10
3.5.5 keepalived的安装 ........................................................................................ 11
3.5.6 keepalived的配置 ........................................................................................ 11
3.5.7 master和backup的realserver的配置 .................................................... 15
3.5.8 master和backup的启动 .............................................................................. 16
4 heartbeat高可用mysql主主同步方案 .............................................................................. 16
4.1 方案简介 ..................................................................................................................... 16
4.2 方案优缺点 ................................................................................................................. 16
4.3 方案架构图 ................................................................................................................. 17
4.4 适用场景 ..................................................................................................................... 17
4.5 方案实战 ..................................................................................................................... 17
4.5.1 实战环境介绍 ................................................................................................. 17
4.5.2 mysql的安装和配置 ...................................................................................... 17
4.5.3 mysql的主主同步配置 .................................................................................. 17
4.5.4 heardbeat的安装 .......................................................................................... 17
4.5.5 heartbeat的配置 .......................................................................................... 18
4.5.6 heartbeat的启动 .......................................................................................... 19
文档被以下合辑收录
评论