On Thu, Jun 9, 2011 at 4:58 AM, Alessandro Iurlano
<alessandro.iurl...@gmail.com> wrote:
> Hello.
>
> I'm trying to setup an highly available OpenVZ cluster. As OpenVZ only
> supports disk quota on ext3/4 local filesystems  (nfs and gfs/ocfs2
> don't work),
> I have setup two iscsi volumes on an highly available storage where
> VMs will be stored.
> I would like to use three servers, two active and one spare, for this
> cluster. That's because OpenVZ expects all the VMs to be under /vz or
> /var/lib/vz directory. This leads to the constraint that each server
> can have only on iscsi volume attached and mounted on /vz.
> Also, as the ext3 fs is not a cluster filesystem, each iscsi volume
> has to be mounted on a single server at time.
>
> So I need to map two iscsi volumes to three servers. I have created a
> pacemaker configuration with two groups, group-iscsi1 and
> group-iscsi2, that take care of connecting the iscsi devices and
> mounting the filesystems on /vz. A negative colocation directive
> forbids the two groups from being active on the same cluster node at
> the same time.
>
> So far things are working. The problem is with the resource that
> controls OpenVZ. It is a lsb:vz primitive that needs to be a clone (I
> can't make it into separate lsb-vz1 or lsb-vz2 primitives as the
> cluster sees both active on every node because they refer to the same
> /etc/init.d/vz script).
> After creating the clone clone-vz, I defined the location constraints
> as location vz-on-iscsi inf: group-iscsi1 clone-vz and did the same
> for group-iscsi2.
> The clone resource needs to be started after filesystems are mounted,
> so I need two order constraints like order vz-after-fs1 inf:
> group-iscsi1:start clone-vz:start and order vz-after-fs2 inf:
> group-iscsi2:start clone-vz:start
> This works perfectly when both iscsi volumes are up. But if one of
> them is stopped, clone-vz is not starting. I guess this is because the
> two order constraints create dependencies for clone-vz on both the
> iscsi groups so that the clone is started only when group-iscsi1 AND
> group-iscsi2 have started.
>
> Is there a way I can tell pacemaker to start clone-vz on a node if
> that node has resource group-iscsi1 OR group-iscsi2?

Not yet I'm afraid.  Resource sets will eventually allow this but I
don't think its there yet.

> The complete pacemaker configuration is here:
> http://nopaste.info/8c2ba79159.html
>
> Thanks,
> Alessandro
> _______________________________________________
> Linux-HA mailing list
> Linux-HA@lists.linux-ha.org
> http://lists.linux-ha.org/mailman/listinfo/linux-ha
> See also: http://linux-ha.org/ReportingProblems
>
_______________________________________________
Linux-HA mailing list
Linux-HA@lists.linux-ha.org
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems

Reply via email to