From 6b3e6875197d004005d37e859fc80692631eb438 Mon Sep 17 00:00:00 2001 From: Gerhard Seidel Date: Fri, 18 Oct 2024 10:42:13 +0200 Subject: [PATCH 1/3] fix: keepalived weights --- tutorials/configure-cloud-ha-keepalived/01.de.md | 2 +- tutorials/configure-cloud-ha-keepalived/01.en.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tutorials/configure-cloud-ha-keepalived/01.de.md b/tutorials/configure-cloud-ha-keepalived/01.de.md index 52b7e1216..84279646b 100644 --- a/tutorials/configure-cloud-ha-keepalived/01.de.md +++ b/tutorials/configure-cloud-ha-keepalived/01.de.md @@ -177,7 +177,7 @@ Die hier gezeigte Konfiguration entspricht einem Beispiel anhand eines HA Webser vrrp_script chk_nginx { script "/usr/bin/pgrep nginx" interval 2 - weight 101 + weight -101 } vrrp_instance VI_1 { diff --git a/tutorials/configure-cloud-ha-keepalived/01.en.md b/tutorials/configure-cloud-ha-keepalived/01.en.md index fd5ec035e..fa111b2d3 100644 --- a/tutorials/configure-cloud-ha-keepalived/01.en.md +++ b/tutorials/configure-cloud-ha-keepalived/01.en.md @@ -176,7 +176,7 @@ The configuration shown here corresponds to an example using an HA web server (n vrrp_script chk_nginx { script "/usr/bin/pgrep nginx" interval 2 - weight 101 + weight -101 } vrrp_instance VI_1 { From 908c0327a76a4519671fef112d8aa870136e2698 Mon Sep 17 00:00:00 2001 From: Gerhard Seidel Date: Fri, 18 Oct 2024 10:57:41 +0200 Subject: [PATCH 2/3] fix: renaming slave to backup --- .../configure-cloud-ha-keepalived/01.de.md | 14 +++++++------- .../configure-cloud-ha-keepalived/01.en.md | 16 ++++++++-------- .../images/{slave.png => backup.png} | Bin 3 files changed, 15 insertions(+), 15 deletions(-) rename tutorials/configure-cloud-ha-keepalived/images/{slave.png => backup.png} (100%) diff --git a/tutorials/configure-cloud-ha-keepalived/01.de.md b/tutorials/configure-cloud-ha-keepalived/01.de.md index 84279646b..9e6669745 100644 --- a/tutorials/configure-cloud-ha-keepalived/01.de.md +++ b/tutorials/configure-cloud-ha-keepalived/01.de.md @@ -204,9 +204,9 @@ vrrp_instance VI_1 { } ``` -> **Hinweis:** Die umrandeten Werte `[]` sind durch eigene Angaben auszutauschen. Für `auth_pass` kann ein beliebiges Passwort gewählt werden. Für den Master und den Slave sollte aber dasselbe Passwort angegeben werden. +> **Hinweis:** Die umrandeten Werte `[]` sind durch eigene Angaben auszutauschen. Für `auth_pass` kann ein beliebiges Passwort gewählt werden. Für den Master und den Backup sollte aber dasselbe Passwort angegeben werden. -**Konfiguration auf dem Slave Server** +**Konfiguration auf dem Backup Server** `/etc/keepalived/keepalived.conf` @@ -218,11 +218,11 @@ vrrp_script chk_nginx { vrrp_instance VI_1 { interface [cloud_private_network_adapter] - state SLAVE + state BACKUP priority 100 virtual_router_id 30 - unicast_src_ip [slave_private_IP] + unicast_src_ip [backup_private_IP] unicast_peer { [master_private_IP] } @@ -240,7 +240,7 @@ vrrp_instance VI_1 { } ``` -> **Hinweis:** Die umrandeten Werte `[]` sind durch eigene Angaben auszutauschen. Für `auth_pass` kann ein beliebiges Passwort gewählt werden. Für den Master und den Slave sollte aber dasselbe Passwort angegeben werden. +> **Hinweis:** Die umrandeten Werte `[]` sind durch eigene Angaben auszutauschen. Für `auth_pass` kann ein beliebiges Passwort gewählt werden. Für den Master und den Backup sollte aber dasselbe Passwort angegeben werden. **Inhalt der `failover.sh` auf beiden Servern** @@ -284,9 +284,9 @@ Im Normalbetrieb übernimmt der Master Webserver alle Anfragen. ![](images/master.png) -Sobald dieser ausfällt gibt es ein Failover auf den Slave Webserver. +Sobald dieser ausfällt gibt es ein Failover auf den Backup Webserver. -![](images/slave.png) +![](images/backup.png) Sobald der Master Webserver wieder erreichbar ist wird wieder auf diesen gewechselt. diff --git a/tutorials/configure-cloud-ha-keepalived/01.en.md b/tutorials/configure-cloud-ha-keepalived/01.en.md index fa111b2d3..2bac483dd 100644 --- a/tutorials/configure-cloud-ha-keepalived/01.en.md +++ b/tutorials/configure-cloud-ha-keepalived/01.en.md @@ -187,7 +187,7 @@ vrrp_instance VI_1 { virtual_router_id 30 unicast_src_ip [master_private_IP] unicast_peer { - [slave_private_IP] + [backup_private_IP] } authentication { @@ -203,9 +203,9 @@ vrrp_instance VI_1 { } ``` -> **Note:** The outlined values `[]` are to be replaced by your own specifications. For `auth_pass`, you can pick any random password. However, make sure to use the same password for the master and the slave. +> **Note:** The outlined values `[]` are to be replaced by your own specifications. For `auth_pass`, you can pick any random password. However, make sure to use the same password for the master and the backup. -**Configuration file on the slave server** +**Configuration file on the backup server** `/etc/keepalived/keepalived.conf` @@ -217,11 +217,11 @@ vrrp_script chk_nginx { vrrp_instance VI_1 { interface [cloud_private_network_adapter] - state SLAVE + state BACKUP priority 100 virtual_router_id 30 - unicast_src_ip [slave_private_IP] + unicast_src_ip [backup_private_IP] unicast_peer { [master_private_IP] } @@ -239,7 +239,7 @@ vrrp_instance VI_1 { } ``` -> **Note:** The outlined values `[]` are to be replaced by your own specifications. For `auth_pass`, you can pick any random password. However, make sure to use the same password for the master and the slave. +> **Note:** The outlined values `[]` are to be replaced by your own specifications. For `auth_pass`, you can pick any random password. However, make sure to use the same password for the master and the backup. **Contents of `failover.sh` on both servers** @@ -283,9 +283,9 @@ In normal operation, the master web server handles all requests. ![](images/master.png) -As soon as this fails, there is a failover to the slave web server. +As soon as this fails, there is a failover to the backup web server. -![](images/slave.png) +![](images/backup.png) As soon as the master web server is reachable again, it is switched back to. diff --git a/tutorials/configure-cloud-ha-keepalived/images/slave.png b/tutorials/configure-cloud-ha-keepalived/images/backup.png similarity index 100% rename from tutorials/configure-cloud-ha-keepalived/images/slave.png rename to tutorials/configure-cloud-ha-keepalived/images/backup.png From 50da0bb6c9e334c9dd3c11a4c8901907a393dc4e Mon Sep 17 00:00:00 2001 From: "svenja.michal" Date: Thu, 7 Nov 2024 14:59:09 +0100 Subject: [PATCH 3/3] Small fix --- tutorials/configure-cloud-ha-keepalived/01.de.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tutorials/configure-cloud-ha-keepalived/01.de.md b/tutorials/configure-cloud-ha-keepalived/01.de.md index 9e6669745..f54db514f 100644 --- a/tutorials/configure-cloud-ha-keepalived/01.de.md +++ b/tutorials/configure-cloud-ha-keepalived/01.de.md @@ -188,7 +188,7 @@ vrrp_instance VI_1 { virtual_router_id 30 unicast_src_ip [master_private_IP] unicast_peer { - [slave_private_IP] + [backup_private_IP] } authentication {