35 lines
1.3 KiB
Diff
35 lines
1.3 KiB
Diff
Index: git/scripts/drbd.ocf
|
|
===================================================================
|
|
--- git.orig/scripts/drbd.ocf
|
|
+++ git/scripts/drbd.ocf
|
|
@@ -418,6 +418,29 @@ drbd_condition() {
|
|
rc=$OCF_DATA_OUTDATED
|
|
ocf_log info "${OCF_RESKEY_drbd_resource} outdated"
|
|
;;
|
|
+ Inconsistent)
|
|
+ case "${DRBD_CSTATE}" in
|
|
+ StandAlone)
|
|
+ rc=$OCF_DATA_STANDALONE
|
|
+ if [ $status -eq $OCF_SUCCESS ]
|
|
+ then
|
|
+ ocf_log info "${OCF_RESKEY_drbd_resource} standby standalone, attempting to reconnect."
|
|
+ do_drbdadm connect ${OCF_RESKEY_drbd_resource}
|
|
+ else
|
|
+ ocf_log info "${OCF_RESKEY_drbd_resource} standalone"
|
|
+ fi
|
|
+ ;;
|
|
+ StartingSyncT | WFBitMapT | WFSyncUUID | SyncTarget | \
|
|
+ PausedSyncT)
|
|
+ rc=$OCF_DATA_SYNC
|
|
+ ocf_log info "${OCF_RESKEY_drbd_resource} sync"
|
|
+ ;;
|
|
+ *)
|
|
+ rc=$OCF_DATA_INCONSISTENT
|
|
+ ocf_log info "${OCF_RESKEY_drbd_resource} inconsistent"
|
|
+ ;;
|
|
+ esac
|
|
+ ;;
|
|
*)
|
|
case "${DRBD_CSTATE}" in
|
|
StandAlone)
|