Drbd

De Admin -- TALEVAS.
/etc/init.d/drbd start
[root@data01 ~]# cat /proc/drbd
version: 8.2.6 (api:88/proto:86-88)
GIT-hash: 3e69822d3bb4920a8c1bfdf7d647169eba7d2eb4 build by buildsvn@c5-x8664-build, 2008-10-03 11:30:17
0: cs:StandAlone st:Secondary/Unknown ds:Consistent/DUnknown   r---
   ns:0 nr:0 dw:0 dr:0 al:0 bm:65 lo:0 pe:0 ua:0 ap:0 oos:483328
[root@data01 ~]# drbdadm connect SERVICE
[root@data01 ~]# cat /proc/drbd
version: 8.2.6 (api:88/proto:86-88)
GIT-hash: 3e69822d3bb4920a8c1bfdf7d647169eba7d2eb4 build by buildsvn@c5-x8664-build, 2008-10-03 11:30:17
0: cs:StandAlone st:Secondary/Unknown ds:Consistent/DUnknown   r---
   ns:0 nr:0 dw:0 dr:0 al:0 bm:65 lo:0 pe:0 ua:0 ap:0 oos:483328


data02-P ~ #drbdadm create-md SERVICE
Valid meta data seems to be in place.
Do you really want to overwrite?     
[need to type 'yes' to confirm] yes  
Writing meta data...
initialising activity log
NOT initialized bitmap   
New drbd meta data block sucessfully created.
data02-P ~ # drbdadm attach SERVICE
data02-P ~ # /etc/init.d/drbd start 
Starting DRBD resources:    [ d(SERVICE) s(SERVICE) n(SERVICE) ].
..........                                                       
***************************************************************  
DRBD's startup script waits for the peer node(s) to appear.     
- In case this node was already a degraded cluster before the   
  reboot the timeout is 10 seconds. [degr-wfc-timeout]          
- If the peer was available before the reboot the timeout will  
  expire after 20 seconds. [wfc-timeout]                        
  (These values are for resource 'SERVICE'; 0 sec -> wait forever)
To abort waiting enter 'yes' [  20]:    


data01-P ~ # drbdadm connect SERVICE


data02-P ~ # drbdsetup /dev/drbd0 syncer -r 90M

data02-P ~ # dstat 1

data02-P ~ # watch cat /proc/drbd


Les machines sont en primaire / primaire pour permettre de lire/écrire des 2 cotés. Autrement les data du secondaire ne sont pas accessibles.