View Comments
Estou enfrentando uns paus com o DRBD. Do nada ele mata o sync e fode com tudo. Meu MySQL vai para o saco, CVS para de funcionar, etc... No log mostra um split-brain error e só consigo matar o DRBD rebootando a máquina(éca, mas fazer o que?)... o que eu fiz: no drbd.conf, tem 3 linhas do arquivos de configuração em resource, net:
after-sb-0pri disconnect;
after-sb-1pri disconnect;
after-sb-2pri disconnect;
mudei para:
after-sb-0pri discard-younger-primary;
after-sb-1pri consensus;
after-sb-2pri disconnect;
segundo a documentação do DRBD:
# In case the nodes of your cluster nodes see each other again, after
# an split brain situation in which both nodes where primary
# at the same time, you have two diverged versions of your data.
#
# In case both nodes are secondary you can control DRBD's
# auto recovery strategy by the "after-sb-0pri" options. The
# default is to disconnect.
# "disconnect" ... No automatic resynchronisation, simply disconnect.
# "discard-younger-primary"
# Auto sync from the node that was primary before
# the split brain situation happened.
# "discard-older-primary"
# Auto sync from the node that became primary
# as second during the split brain situation.
# "discard-least-changes"
# Auto sync from the node that touched more
# blocks during the split brain situation.
# "discard-node-NODENAME"
# Auto sync to the named node.
after-sb-0pri disconnect;
# In one of the nodes is already primary, then the auto-recovery # strategie is controled by the "after-sb-1pri" options. # "disconnect" ... always disconnect # "consensus" ... discard the version of the secondary if the outcome # of the "after-sb-0pri" algorithm would also destroy # the current secondary's data. Otherwise disconnect. # "discard-secondary" # discard the version of the secondary. # "panic-primary" Always honour the outcome of the "after-sb-0pri" # algorithm. In case it decides the the current # secondary has the right data, it panics the # current primary. # "suspend-primary" ??? after-sb-1pri disconnect; # In case both nodes are primary you control DRBD's strategy by # the "after-sb-2pri" option. # "disconnect" ... Go to StandAlone mode on both sides. # "panic" ... Honor the outcome of the "after-sb-0pri" algorithm # and panic the other node. after-sb-2pri disconnect;
vamos ver se da resultado. eu aviso :)