[CentOS-es] Problema cluster al bootear
Maykel Franco Hernandez
maykel en maykel.sytes.net
Mar Abr 5 06:05:53 EDT 2011
Creo que he encontrado la solución a mi problema...Ahora al bootear
se ponen bien como primary/primary, encontré esto e una página:
Dejo
el enlace:
http://realtechtalk.com/DRBD_WFConnection_ProblemSolution-1042-articles
Básicamente explica que a veces el cortafuegos de iptables que viene
configurado por defecto bloquea el tráfico drbd pero yo el iptables lo
tenia off y el selinux en disabled.
He hecho lo que viene abajo y he
añadido algo que no viene ahí que me daba error al ejecutarlo
directamente:
En ambos nodos:
drbdadm detach r0
drbdadm attach r0
drbdadm disconnect r0
drbdadm connect r0
En ambos nodos tambien,
porque es activo/activo ejecutamos:
drbdsetup /dev/drbd0 primary -o
Ahora al reiniciar sincroniza bien y se quedan siempre como
primary/primary
On Tue, 05 Apr 2011 08:03:42 +0200, Maykel Franco
Hernandez wrote:
> Dejo los archivos de confiuracion de drbd y el log
de
> /var/log/messages:
>
> /var/log/messages:
>
> Apr 5 09:02:58
nodo1 kernel:
> block drbd0: conn( StandAlone -> Unconnected )
> Apr 5
09:02:58 nodo1
> kernel: block drbd0: Starting receiver thread (from
drbd0_worker
> [2472])
> Apr 5 09:02:58 nodo1 kernel: block drbd0:
receiver
> (re)started
> Apr 5 09:02:58 nodo1 kernel: block drbd0: conn(
Unconnected
> -> WFConnection )
> Apr 5 09:02:58 nodo1 kernel: block
drbd0: Handshake
> successful: Agreed network protocol version 94
> Apr
5 09:02:58 nodo1
> kernel: block drbd0: Peer authenticated using 20
bytes of 'sha1'
> HMAC
> Apr 5 09:02:58 nodo1 kernel: block drbd0: conn(
WFConnection ->
> WFReportParams )
> Apr 5 09:02:58 nodo1 kernel: block
drbd0: Starting
> asender thread (from drbd0_receiver [2995])
> Apr 5
09:02:58 nodo1 kernel:
> block drbd0: data-integrity-alg:
> Apr 5
09:02:58 nodo1 kernel: block
> drbd0: drbd_sync_handshake:
> Apr 5
09:02:58 nodo1 kernel: block drbd0:
> self
20D19E2060D2FC2B:FE122B51EEDFC379:85D17931A41947EC:0000000000000004
>
bits:8 flags:0
> Apr 5 09:02:58 nodo1 kernel: block drbd0: peer
>
172B1D27641ADE75:FE122B51EEDFC379:85D17931A41947ED:0000000000000004
>
bits:4096 flags:2
> Apr 5 09:02:58 nodo1 kernel: block drbd0:
>
uuid_compare()=100 by rule 90
> Apr 5 09:02:58 nodo1 kernel: block
drbd0:
> helper command: /sbin/drbdadm initial-split-brain minor-0
> Apr
5 09:02:58
> nodo1 kernel: block drbd0: helper command: /sbin/drbdadm
>
initial-split-brain minor-0 exit code 0 (0x0)
> Apr 5 09:02:58 nodo1
>
kernel: block drbd0: Split-Brain detected but unresolved, dropping
>
connection!
> Apr 5 09:02:58 nodo1 kernel: block drbd0: helper
command:
> /sbin/drbdadm split-brain minor-0
> Apr 5 09:02:58 nodo1
kernel: block
> drbd0: helper command: /sbin/drbdadm split-brain minor-0
exit code 0
> (0x0)
> Apr 5 09:02:58 nodo1 kernel: block drbd0: conn(
WFReportParams ->
> Disconnecting )
> Apr 5 09:02:58 nodo1 kernel: block
drbd0: error
> receiving ReportState, l: 4!
> Apr 5 09:02:58 nodo1
kernel: block drbd0:
> asender terminated
> Apr 5 09:02:58 nodo1 kernel:
block drbd0: Terminating
> asender thread
> Apr 5 09:02:58 nodo1 kernel:
block drbd0: Connection
> closed
> Apr 5 09:02:58 nodo1 kernel: block
drbd0: conn( Disconnecting ->
> StandAlone )
> Apr 5 09:02:58 nodo1
kernel: block drbd0: receiver
> terminated
> Apr 5 09:02:58 nodo1
kernel: block drbd0: Terminating
> receiver thread
>
> /etc/drbd.conf:
>
> global {
> usage-count yes;
> }
>
> common
> {
> syncer {
> rate
100M;
> al-extents 257;
> }
> }
>
> resource r0 {
>
> protocol
> C;
>
> startup {
> become-primary-on both; ### For Primary/Primary ###
>
>
degr-wfc-timeout 60;
> wfc-timeout 30;
> }
>
> disk {
> on-io-error
detach;
>
> }
>
> net {
> allow-two-primaries; ### For Primary/Primary
###
>
> cram-hmac-alg sha1;
> shared-secret "mysecret";
>
after-sb-0pri
> discard-zero-changes;
> after-sb-1pri violently-as0p;
>
after-sb-2pri
> violently-as0p;
> }
>
> on nodo1.centos.org {
> device
/dev/drbd0;
> disk
> /dev/sda3;
> address 10.0.0.1:7788;
> meta-disk
internal;
>
> }
>
> on
> nodo2.centos.org {
> device /dev/drbd0;
>
disk /dev/sda3;
> address
> 10.0.0.2:7788;
> meta-disk internal;
> }
> }
>
> Espero me puedan ayudar ya
> que es un tema que me interesa
bastante, gracias.
>
> On Mon, 04 Apr 2011
> 09:08:02 -0500, Ing.
Ernesto PÃ(c)rez EstÃ(c)vez wrote:
>
>> publica el
> archivo de
configuración del drbd
>
>> has puesto alguna condicion para
> manejar
el split-brain? yo pongo una g-left:5px; border-left:#1
> id;
margin-left:5px; width:100%"> qué usas para manejar el heartbeat? debes
ponerle ahi el orden de
http://www.centos.org/docs/5/html/5.2/Cluster_Administration/ [2] [2] --
Oscar Osta Pueyo
> tas en gmail.com [3] [3] _kiakli_ Links: ------ [1]
http://www.centos.org/docs/5/html/5.2/Cluster_Suite_Overview/ [1] [4]
[2] http://www.centos.org/docs/5/html/5.2/Cluster_Administration/ [2]
[5] [3] mailto:oostap.listas en gmail.com [3] [6]
_______________________________________________ CentOS-es mailing list
CentOS-es en centos.org [4] [7]
http://lists.centos.org/mailman/listinfo/centos-es [5] [8]
_______________________________________________ CentOS-es mailing list
CentOS-es en centos.org [6] [9]
http://lists.centos.org/mailman/listinfo/centos-es [7] [10] Links:
------ [1] http://www.centos.org/docs/5/html/5.2/Cluster_Suite_Overview/
[8] [2] http://www.centos.org/docs/5/html/5.2/Cluster_Administration/
[9] [3] mailto:oostap.listas en gmail.com [10] [4]
http://www.centos.org/docs/5/html/5.2/Cluster_Suite_Overview/ [11] [5]
http://www.centos.org/docs/5/html/5.2/Cluster_Administration/ [12] [6]
mailto:http://lists.centos.org/mailman/listinfo/centos-es [13] [9]
mailto:CentOS-es en centos.org [14] [10]
http://lists.centos.org/mailman/listinfo/centos-es [15]
_______________________________________________ CentOS-es mailing list
CentOS-es en centos.org [16]
http://lists.centos.org/mailman/listinfo/centos-es
[17]
Links:
------
[1]
http://www.centos.org/docs/5/html/5.2/Cluster_Suite_Overview/
[2]
http://www.centos.org/docs/5/html/5.2/Cluster_Administration/
[3]
mailto:oostap.listas en gmail.com
[4] mailto:CentOS-es en centos.org
[5]
http://lists.centos.org/mailman/listinfo/centos-es
[6]
mailto:CentOS-es en centos.org
[7]
http://lists.centos.org/mailman/listinfo/centos-es
[8]
http://www.centos.org/docs/5/html/5.2/Cluster_Suite_Overview/
[9]
http://www.centos.org/docs/5/html/5.2/Cluster_Administration/
[10]
mailto:oostap.listas en gmail.com
[11]
http://www.centos.org/docs/5/html/5.2/Cluster_Suite_Overview/
[12]
http://www.centos.org/docs/5/html/5.2/Cluster_Administration/
[13]
mailto:<div>
> -e
</div>/a> [8] <a href=
[14]
mailto:CentOS-es en centos.org
[15]
http://lists.centos.org/mailman/listinfo/centos-es
[16]
mailto:CentOS-es en centos.org
[17]
http://lists.centos.org/mailman/listinfo/centos-es
Más información sobre la lista de distribución CentOS-es