[DRBD-user] drbd automatic switch over

Jens Grigel jens.grigel at sskm.de
Fri Oct 14 13:57:33 CEST 2005

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


On Fri, 2005-10-14 at 13:39, Roy vd Berg wrote:
> Hello
> 
> I am setting up a test cluster with heartbeat and drbd
> Heartbeat is working fine. Drbd is also working fine
> 
> When I poweroff node1 the processes are getting migrated from node1 to 
> node 2.
> 
> What is the best way to mount the /data dir on node2 because samba config
> files are located on /data/etc/samba and connected with a static link to
> /etc/samba
> 
> i can switch over by hand: drbdadm primary all
> and mount /dev/drbd0 /data
> 
> but have someone some script who does this automaticly ??
> 
> 

Hi,

with drbd comes a script called "drbddisk". It's usually installed in
/etc/ha.d/ressource.d and should be called by heartbeat as a resource
agent when failing over. It will take care of switching the drbd device
on the standby node to primary mode.
Mounting the device after switching to primary is handled by the
heartbeat resource agent "Filesystem".

Find more infos for drbd and heartbeat on:
http://www.linux-ha.org/DRBD

and especially:
http://www.linux-ha.org/DataRedundancyByDrbd#head-3439fb8bff5c99bf0625e4573e898f2fbd4a4134


Hope that helps,

-- 

Jens Grigel

Citysavingsbank Munich, Germany
Dep. of Network and Security




More information about the drbd-user mailing list