[DRBD-user] drbd_set_status_variables() outputs `This command will ignore resource names!'

Hiroshi Fujishima h-fujishima at sakura.ad.jp
Mon Jun 29 10:14:10 CEST 2015

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


> I notice the following error message.
> 
> Jun 26 13:41:01 sac-tkh-sv001 pacemaker_remoted[32149]: notice: operation_finished: res_drbd_r0_monitor_10000:25537:stderr [ This command will ignore resource names! ]
> 
> This messages is generated by drbd_set_status_variables().
> 
> http://git.drbd.org/gitweb.cgi?p=drbd-utils.git;a=blob;f=scripts/drbd.ocf;h=0481a32a97a3b5fb814871e46d48024ea112abf4;hb=HEAD#l311
> 
> [root at sac-tkh-sv001 ~]# drbdadm -c /etc/drbd.conf sh-status r0 > /devnull
> This command will ignore resource names!
> 
> I think "$DRBD_RESOURCE" argument is not required.

Is using drbd-utils-8.9.3 with drbd-8.4.6 supported?
drbd-8.9.2 with drbd-8.4.6 does not cause error.

# diff -u drbd-utils-8.9.[23]/scripts/drbd.ocf
--- drbd-utils-8.9.2/scripts/drbd.ocf   2015-03-26 19:11:30.000000000 +0900
+++ drbd-utils-8.9.3/scripts/drbd.ocf   2015-06-14 21:20:25.000000000 +0900
@@ -308,7 +308,7 @@
        DRBD_DSTATE_LOCAL=()
        DRBD_DSTATE_REMOTE=()

-       eval "$($DRBDSETUP "$DRBD_RESOURCE" sh-status)"
+       eval "$($DRBDADM sh-status "$DRBD_RESOURCE")"

        # if there was no output at all, or a weird output
        # make sure the status arrays won't be empty.
@@ -916,11 +916,11 @@
        check_binary $DRBDSETUP
        # XXX I really take cibadmin, sed, grep, etc. for granted.

-       local VERSION DRBDADM_VERSION_CODE=0
+       local VERSION DRBD_KERNEL_VERSION_CODE=0
        if VERSION="$($DRBDADM --version 2>/dev/null)"; then
                eval $VERSION
        fi
-       if (( $DRBDADM_VERSION_CODE >= 0x080400 )); then
+       if (( $DRBD_KERNEL_VERSION_CODE >= 0x080400 )); then
                DRBD_HAS_MULTI_VOLUME=true
        fi
        check_crm_feature_set
@@ -1037,6 +1037,7 @@
        for i in $OCF_RESKEY_adjust_master_score; do
                [[ $i = *[!0-9]* ]]   && fallback=true && ocf_log err "BAD adjust_master_score value $i ; falling back to default"
                [[ $j && $i -lt $j ]] && fallback=true && ocf_log err "BAD adjust_master_score value $j > $i ; falling back to default"
+               j=$i
                n=$(( n+1 ))
        done
        [[ $n != 4 ]] && fallback=true && ocf_log err "Not enough adjust_master_score values ($n != 4); falling back to default"
# drbdsetup r0 sh-status
_minor=0
_res_name=r0
_volume=0
_known=Configured

_cstate=Connected
_role=Secondary
_peer=Primary
_disk=UpToDate
_pdsk=UpToDate

_flags_susp=
_flags_aftr_isp=
_flags_peer_isp=
_flags_user_isp=

_resynced_percent=

_sh_status_process

-- 
Hiroshi Fujishima



More information about the drbd-user mailing list