Lars,
Lars Marowsky-Bree wrote:
> I still think that the dopd is sort-of the wrong approach, btw. This
> should probably integrate somehow with the drbd RA, using the
> notifications made available to it.
How does Heartbeat feed DRBD the information that the DRBD
replication link (which normally is also a Heartbeat link, and that's
highly recommended, but this isn't strictly a requirement) just died?
While we're at it, can we discuss the drbd OCF RA a little bit? There's
a few things that have always sort of bugged me about it, and maybe this
is the right time to sort them out.
1. "Floating peers" and the fact that the RA does drbdadm up/down.
I've always considered the fact that the RA does a "drbdadm down" on
resource stop something of a misfeature, as it means that DRBD
replication stops when a node goes to standby mode. I guess that's
undesirable for the majority of use cases. If this behavior is required
for keeping "floating peers" functionality, my suggestion would be the
following logic:
if [ ${OCF_RESKEY_clone_overrides_hostname} -eq 1 ]; then
# do drbdadm down on stop
# anything but an unconfigured DRBD dev means the resource is running
else
# do drbdadm secondary on stop
# anything but a Primary resource means $OCF_NOT_RUNNING
fi
2. drbd_update_prefs
It seems odd to me that drbd_update_prefs only tests for connection
state, which is of lesser importance in terms of whether a resource
should become a DRBD Primary. Disk state is much more important; a DRBD
resource whose local disk state is "Inconsistent" should get a strongly
negative preference (and, just to mention this for completeness' sake,
it can never be promoted if the connection state is StandAlone or
WFConnection). An "Outdated" resource can never be promoted.
3. Obsolete sanity check
The RA tests for OCF_RESKEY_master_max and requires that it is set to 1.
That is obsolete as of DRBD 8 which supports dual-Primary mode, so both
1 and 2 should be accepted values.
Your thoughts?
Cheers,
Florian
--
: Florian G. Haas
: LINBIT Information Technologies GmbH
: Vivenotgasse 48, A-1120 Vienna, Austria
LINBIT® and DRBD® are registered trademarks of LINBIT.
_______________________________________________________
Linux-HA-Dev: [email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/