Sv translation | ||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||
Determine good server Zuerst muss entschieden werden, welcher der "guter" Server ist. Wenn HAPROXY im Betrieb ist, dann ist der guter Master der auf den die Daten derzeit geschrieben werden. HAPROXY umstellen If there is a HAPROXY, then remove the servers on the broken master side from the distribution (also the slave on this side). On BOTH Master Server
Make a backup of the good Master DB on the BROKEN Master Server Previous to Release 3.12:
As of release 3.12 please use the following command:
On the BROKEN master server, reset the slave and restore the backup
On the BROKEN master server, determine the master position from the master.sql, and then reinitialize the slave
On the BROKEN master server Check the slave
Only if everything is OK, and the replication is up to date, then continue. The status can be monitored with the following command:
On the BROKEN master server lock all tables and note master position
The positions of SHOW MASTER STATUS are required in the following command. On the GOOD master server, reposition and start the replication.
Unlock the tables on the BROKEN master server
Check Masters and Slaves On all servers now
and check that everything is running smoothly It is usually not necessary to restore the slaves attached to both masters. If it is, they can be re-initialized with the normal slave recovery procedure. |
Sv translation | ||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||
Guter Server ermitteln Zuerst muss entschieden werden, welcher der "guter" Server ist. Wenn HAPROXY im Betrieb ist, dann ist der guter Master der auf den die Daten derzeit geschrieben werden. HAPROXY umstellen Falls es ein HAPROXY gibt, dann die Server auf der Kaputten Master Seite aus der Verteilung herausnehmen (auch den Slave auf dieser Seite). Auf BEIDE Master Server
Auf den KAPUTTEN Master Server eine Sicherung der guten Master DB anfertigen Vor Release 3.12:
Ab Release 3.12 bitte folgenden Befehl nutzen:
Auf den KAPUTTEN Master Server, den Slave resetten, und Sicherung einspielen
Auf den KAPUTTEN Master Server den Slave Prüfen
Auf den KAPUTTEN Master Server alle Tabellen locken und Master Position notieren
Die Positionen von SHOW MASTER STATUS werden im folgenden Kommando benötigt. Auf den GUTEN Master Server die Replikation neu positionieren und starten
Auf den KAPUTTEN Master Server die Tabellen Locks aufheben
Master und Slaves Prüfen Auf allen Servern nun
Es ist normalerweise nicht nötig, die Slaves die an beide Master hängen ebenfalls zu wiederherstellen. Wenn doch, können diese mit der normalen Prozedur für das Wiederherstellen des Slaves neu initialisiert werden. |
Sv translation | ||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||
Déterminer le bon serveur Il faut d'abord décider quel est le "bon" serveur. Si HAPROXY est en service, alors le bon maître est celui sur lequel les données sont actuellement écrites. Rediffuser HAPROXY S'il y a une HAPROXIE, supprimez les serveurs sur le brisé côté master de la distribution (également l'esclave de ce côté). Sur LES DEUX serveurs master
Faites une sauvegarde de la bonne Master DB sur le Serveur principal BRISÉ Précédent à la version 3.12 :
A partir de la version 3.12, veuillez utiliser la commande suivante :
Dans le Serveur maître BRISÉ, réinitialiser l'esclave et restaurer la sauvegarde
Dans le Serveur maître BRISÉ, déterminer la position du maître à partir du master.sql, puis réinitialiser l'esclave
Dans leServeur maître BRISÉ Vérifier l'esclave
Seulement si tout va bien et que la réplication est à jour, alors continuez. L'état peut être surveillé avec la commande suivante :
Dans le Serveur maître BRISÉ verrouiller toutes les tables et noter la position du maître
Les postes de SHOW MASTER STATUS sont requis dans la commande suivante. Dans le BON serveur maître, repositionner et commencer la réplication.
Déverrouillez les tableaux sur le Serveur maître BRISÉ
Contrôler les maîtres et les esclaves Sur tous les serveurs maintenant
et vérifier que tout fonctionne bien Il n'est généralement pas nécessaire de rétablir les esclaves attachés aux deux maîtres. Si c'est le cas, ils peuvent être réinitialisés avec la procédure normale de récupération des esclaves. |