[Pacemaker] why pacemaker can't clone CIFS Filesystem resource

Qiu Zhigang qiuzhigang at fronware.com
Fri Dec 23 03:49:06 EST 2011


Hi,

I want to mount CIFS storage on every node of pacemaker cluster, so I use
clone like following:

    <clone id="cifs-clone">
      <meta_attributes id="cifs-clone-meta_attributes">
        <nvpair id="cifs-clone-meta_attributes-target-role"
name="target-role" value="Started"/>
      </meta_attributes>
      <primitive class="ocf" id="Mount_cifs" provider="heartbeat"
type="Filesystem">
        <instance_attributes id="Mount_cifs-instance_attributes">
          <nvpair id="Mount_cifs-instance_attributes-device" name="device"
value="//192.168.1.40/xxxx"/>
          <nvpair id="Mount_cifs-instance_attributes-directory"
name="directory" value="/mnt/cifs"/>
          <nvpair id="Mount_cifs-instance_attributes-fstype" name="fstype"
value="cifs"/>
          <nvpair id="Mount_cifs-instance_attributes-options" name="options"
value="username=admin,password=xxxx,rw"/>
        </instance_attributes>
      </primitive>
    </clone>

However when I start cifs-clone, some error occurred, start failed,
following is the log.

Dec 21 18:50:24 h10_150 Filesystem[2935]: INFO: Running start for
192.168.1.40:/mnt/test/nfs/xxxx on /mnt/nfs
Dec 21 18:50:24 h10_150 Filesystem[2935]: ERROR: DANGER! cifs on
192.168.1.40:/mnt/test/nfs/xxxx is NOT cluster-aware!
Dec 21 18:50:24 h10_150 Filesystem[2935]: ERROR: DO NOT RUN IT AS A CLONE!
Dec 21 18:50:24 h10_150 Filesystem[2935]: ERROR: Politely refusing to
proceed to avoid data corruption.
Dec 21 18:50:24 h10_150 crmd: [2083]: info: process_lrm_event: LRM operation
Mount_cifs:0_start_0 (call=13, rc=6, cib-update=103, confirmed=true) not
configured

So I read the Filesystem script code, find following code before start
resource.

case $FSTYPE in
ocfs2)  ocfs2_init
        ;;
nfs|smbfs|none|gfs2)    : # this is kind of safe too
        ;;
*)      if [ -n "$OCF_RESKEY_CRM_meta_clone" ]; then
                ocf_log err "$OCF_RESKEY_CRM_meta_clone"
                ocf_log err "DANGER! $FSTYPE on $DEVICE is NOT
cluster-aware!"
                ocf_log err "DO NOT RUN IT AS A CLONE!"
                ocf_log err "Politely refusing to proceed to avoid data
corruption."
                exit $OCF_ERR_CONFIGURED
        fi
        ;;
Esac

I want to know why CIFS isn't the kind of safe FSTYPE, but smbfs is
considered safe ? They are not the same as it ?

PS:

I could start CIFS resource directly instead of clone.


Best Regards,
Qiu Zhigang





More information about the Pacemaker mailing list