当前位置:网站首页>Keepalived setting does not preempt resources
Keepalived setting does not preempt resources
2022-07-03 17:48:00 【Brother Xing plays with the clouds】
keepalived do HA when , We often encounter preemptive master and backup Switch between
example:
Usually if master After the service died backup Will become master, But when master When the service is better again master Preemption occurs VIP, In this way, there will be two switches, which is not good for busy websites . So we need to add... To the configuration file nopreempt non-preemptive , But this parameter can only be used for state by backup, So we're using HA It's the best time to master and backup Of state Set up backup Let it go through priority To compete .
Be careful : After this configuration , We should pay attention to starting keepalived The order of services , Suppose I want A Become backup Then you can't start it first A Of keepalived service .
Here is the combination MHA Architecture master 、 Standby database configuration example
Main library
[[email protected] ~]# more /etc/keepalived/keepalived.conf #20140916 #!/bin/bash
global_defs { router_id mysqlmha }
vrrp_script check_run { script "/etc/keepalived/check_mysql.sh" interval 1 }
vrrp_instance VI_1 { state BACKUP -- The status here is specified as backup interface eth0 virtual_router_id 151 priority 100 advert_int 1 nopreempt -- Set up nopreempt Prevent preemption of resources authentication { auth_type PASS auth_pass 1111 }
track_script { check_run } virtual_ipaddress { 192.168.66.53 } }
For the library
[[email protected] ~]# more /etc/keepalived/keepalived.conf ! Configuration File for keepalived
global_defs { router_id mysqlmha }
vrrp_script check_run { script "/etc/keepalived/check_mysql.sh" interval 1 }
vrrp_instance VI_1 { state BACKUP interface eth0 virtual_router_id 151 priority 90 advert_int 1 authentication { auth_type PASS auth_pass 1111 }
track_script { check_run }
virtual_ipaddress { 192.168.66.53 } }
边栏推荐
- MySQL has been stopped in the configuration interface during installation
- Getting started with deops
- Vs2013 has blocked the installer, and ie10 needs to be installed
- The gbase 8A database does not support the DB2 function value (column_name, 0) cluster syntax
- [set theory] order relation: summary (partial order relation | partial order set | comparable | strictly less than | covering | hasto | total order relation | quasi order relation | partial order rela
- BFS - topology sort
- [combinatorics] generating function (linear property | product property)
- (9) Opencv Canny edge detection
- How to train mask r-cnn model with your own data
- Internet Hospital his Management Platform source, online Inquiry, appointment Registration Smart Hospital Small program source
猜你喜欢

Five problems of database operation in commodity supermarket system

List的stream中Long对象与long判等问题记录

互联网医院HIS管理平台源码,在线问诊,预约挂号 智慧医院小程序源码

QT learning diary 9 - dialog box

Leetcode 538 converts binary search tree into cumulative tree -- recursive method and iterative method

聊聊支付流程的設計與實現邏輯

How to purchase Google colab members in China

How to install PHP on Ubuntu 20.04

Baiwen.com 7 days Internet of things smart home learning experience punch in the next day

Applet setting multi account debugging
随机推荐
List of financial products in 2022
Discussion sur la logique de conception et de mise en oeuvre du processus de paiement
Leetcode540: a single element in an ordered array
UE4 official charging resources, with a total price of several thousand
[RT thread] NXP rt10xx device driver framework -- pin construction and use
微服务组件Sentinel控制台调用
Tensorboard quick start (pytoch uses tensorboard)
Postfix 技巧和故障排除命令
一入“远程”终不悔,几人欢喜几人愁。| 社区征文
鸿蒙第三次培训
ArrayList分析3 : 删除元素
TensorBoard快速入门(Pytorch使用TensorBoard)
Qt调节Win屏幕亮度和声音大小
Micro service component sentinel console call
[combinatorics] recursive equation (special solution form | special solution solving method | special solution example)
Research on Swift
A day's work list of an ordinary programmer
Keepalived 设置不抢占资源
PS screen printing brush 131, many illustrators have followed suit
1146_ SiCp learning notes_ exponentiation