Hello,
I have a two node cluster running pacemaker/heartbeat and drbd which
is replicating an ext3 disk. Everything works with the following
exception, when the master node "fails" and the slave node is promoted
to master, the disk resource is not mounted automatically on the new
master.
For example:
1) Node alpha is master and /dev/drbd/by-res/r0 is mounted.
2) I stop the heartbeat service on alpha.
3) Alpha becomes a slave and automatically UNmounts /dev/drbd/by-res/r0.
4) Node bravo assumes the master role, but does not automatically
mount /dev/drbd/by-res/r0; I have to do this manually.
Can anyone advise how I get the slave (in this case, "bravo") to
automount the resource after it is promoted to master? See configs
below.
Thanks,
Craig.
cr...@alpha:~$ sudo cat /etc/drbd.d/global_common.conf
global {
usage-count no;
}
common {
protocol C;
handlers {
pri-on-incon-degr "/usr/lib/drbd/notify-pri-on-incon-degr.sh;
/usr/lib/drbd/notify-emergency-reboot.sh; echo b > /proc/sysrq-trigger
; reboot -f";
pri-lost-after-sb "/usr/lib/drbd/notify-pri-lost-after-sb.sh;
/usr/lib/drbd/notify-emergency-reboot.sh; echo b > /proc/sysrq-trigger
; reboot -f";
local-io-error "/usr/lib/drbd/notify-io-error.sh;
/usr/lib/drbd/notify-emergency-shutdown.sh; echo o >
/proc/sysrq-trigger ; halt -f";
}
startup {}
disk {}
net {
cram-hmac-alg sha1;
shared-secret "foobar";
}
syncer {
verify-alg sha1;
rate 100M;
}
}
resource r0 {
device /dev/drbd1;
disk /dev/sdb1;
meta-disk /dev/sdb2[0];
on alpha {
address 192.168.56.101:7789;
}
on bravo {
address 192.168.56.102:7789;
}
}
cr...@alpha:~$ sudo cat /etc/heartbeat/ha.cf
autojoin none
mcast eth0 239.0.0.43 694 1 0
bcast eth0
warntime 5
deadtime 15
initdead 60
keepalive 2
node alpha
node bravo
crm respawn
cr...@alpha:~$ sudo crm configure show
node $id="9f30b106-0f96-483c-9976-5eded7c810df" alpha
node $id="c1f2d7c5-f66d-4dab-8da3-bb10bc6f2046" bravo
primitive drbd_disk ocf:linbit:drbd \
params drbd_resource="r0" \
op monitor interval="30s"
primitive fs_drbd ocf:heartbeat:Filesystem \
params device="/dev/drbd/by-res/r0" directory="/media/data"
fstype="ext3"
ms ms_drbd drbd_disk \
meta master-max="1" master-node-max="1" clone-max="2"
clone-node-max="1" notify="true"
location loc-1 fs_drbd -inf: bravo
location loc-2 drbd_disk -inf: bravo
colocation mnt_on_master inf: fs_drbd ms_drbd:Master
order mount_after_drbd inf: ms_drbd:promote fs_drbd:start
property $id="cib-bootstrap-options" \
dc-version="1.0.8-042548a451fce8400660f6031f4da6f0223dd5dd" \
cluster-infrastructure="Heartbeat" \
no-quorum-policy="ignore" \
stonith-enabled="false" \
expected-quorum-votes="2"
cr...@alpha:~$ sudo crm_verify -L -V
crm_verify[8821]: 2010/08/12_11:29:02 WARN: unpack_rsc_location: No
resource (con=loc-2, rsc=drbd_disk)
Warnings found during check: config may not be valid
cr...@alpha:~$ uname -a
Linux alpha 2.6.32-24-generic #39-Ubuntu SMP Wed Jul 28 06:07:29 UTC
2010 i686 GNU/Linux
cr...@alpha:~$ drbdadm --version
DRBDADM_BUILDTAG=GIT-hash:\ ea9e28dbff98e331a62bcbcc63a6135808fe2917\
build\ by\ bui...@palmer\,\ 2010-06-01\ 10:47:02
DRBDADM_API_VERSION=88
DRBD_KERNEL_VERSION_CODE=0x080307
DRBDADM_VERSION_CODE=0x080307
DRBDADM_VERSION=8.3.7
cr...@alpha:~$ sudo aptitude show drbd8-utils
Package: drbd8-utils
State: installed
Automatically installed: no
Version: 2:8.3.7-1ubuntu2.1
Priority: extra
Section: admin
Maintainer: Ubuntu Developers <[email protected]>
cr...@alpha:~$ sudo aptitude show heartbeat
Package: heartbeat
State: installed
Automatically installed: no
Version: 1:3.0.3-1ubuntu1
Priority: optional
Section: universe/admin
Maintainer: Ubuntu Developers <[email protected]>
cr...@alpha:~$ sudo aptitude show pacemaker
Package: pacemaker
State: installed
Automatically installed: yes
Version: 1.0.8+hg15494-2ubuntu2
Priority: optional
Section: universe/admin
Maintainer: Ubuntu Developers <[email protected]>
_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems