[Pacemaker] apache on too many nodes?

Jake Smith jsmith at argotec.com
Thu Oct 4 16:27:10 CEST 2012




----- Original Message -----
> From: "Andreas Kurz" <andreas at hastexo.com>
> To: pacemaker at oss.clusterlabs.org
> Sent: Thursday, October 4, 2012 9:50:52 AM
> Subject: Re: [Pacemaker] apache on too many nodes?
> 
> On 10/03/2012 10:47 PM, Jake Smith wrote:
> > 
> > 
> > 
> > ----- Original Message -----
> >> From: marvin at nic.fi
> >> To: pacemaker at oss.clusterlabs.org
> >> Sent: Wednesday, October 3, 2012 4:36:10 PM
> >> Subject: [Pacemaker] apache on too many nodes?
> >>
> >> Hello,
> >>
> >> I'm currently testing out a 2 node system with the simple goal of
> >> providing failover so that the services are run on one node at a
> >> time.
> >> I have some of the mysql and apache configuration files in the
> >> drbd
> >> partition.
> >>
> >> Without apache everything works as expected drbd and mysql start
> >> and
> >> stop properly on the nodes, but as soon as i try to put apache
> >> into
> >> to mix nothing works anymore.
> >>
> >> Using the following configuration:
> >>
> >> primitive drbd ocf:linbit:drbd params drbd_resource="drbd" op
> >> start
> >> interval="0" timeout="240s" op stop interval="0" timeout="100s"
> >> ms drbd_ms drbd meta master-max="1" master-node-max="1"
> >> clone-max="2"
> >> clone-node-max="1" notify="true"
> >> primitive drbd_fs ocf:heartbeat:Filesystem params
> >> device="/dev/drbd0"
> >> directory="/mnt/drbd" fstype="ext3" op start interval="0"
> >> timeout="60" op stop interval="0" timeout="120"
> >> primitive service_mysqld lsb:mysql op monitor interval="15s"
> >> primitive service_apache lsb:apache2 op monitor interval="15s"
> >> group services_group service_mysqld service_apache
> >> colocation lamp_services inf: drbd_fs drbd_ms:Master
> >> services_group
> > 
> > Pretty sure your colocation is the problem - services_group should
> > be first not last...
> > 
> > colocation lamp_services inf: services_group drbd_fs drbd_ms:Master
> 
> It has to be:
> 
> colocation lamp_services inf: drbd_fs services_group drbd_ms:Master
> 

Oooh thanks for the correction Andreas - didn't know that the group would be paired with a primitive to create a set!  And I concur - much clearer/easier if you just put the fs in the group.

Jake

> ... if you really want to use resource-sets, I'd recommend putting
> the
> fs into the services_group on the first position to avoid confusion
> and use:
> 
> colocation lamp_services inf: services_group drbd_ms:Master
> 
> You disabled automatic start via init for apache & mysql? You checked
> the apache LSB script for LSB compliance?
> 
> Regards,
> Andreas
> 
> --
> Need help with Pacemaker?
> http://www.hastexo.com/now
> 
> > 
> > because you want the services group to run on the same node as the
> > drbd filesystem which has to run on the same node as the drbd
> > Master.
> > 
> >> order lamp_order inf: drbd_ms:promote drbd_fs:start
> >> services_group:start
> >>
> >> I think it wants to start apache on both nodes for some reason
> >> (and
> >> fails ofcourse) and promptly stops everything.
> >>
> >> service_apache (lsb:apache2) Started (unmanaged) FAILED[ node1
> >> node2
> >> ]
> >>
> >> I'm probably doing something stupid here. Using debian squeeze.
> >>
> >> :Mrv
> >>
> >>
> >> _______________________________________________
> >> Pacemaker mailing list: Pacemaker at oss.clusterlabs.org
> >> http://oss.clusterlabs.org/mailman/listinfo/pacemaker
> >>
> >> Project Home: http://www.clusterlabs.org
> >> Getting started:
> >> http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> >> Bugs: http://bugs.clusterlabs.org
> >>
> >>
> > 
> > _______________________________________________
> > Pacemaker mailing list: Pacemaker at oss.clusterlabs.org
> > http://oss.clusterlabs.org/mailman/listinfo/pacemaker
> > 
> > Project Home: http://www.clusterlabs.org
> > Getting started:
> > http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> > Bugs: http://bugs.clusterlabs.org
> > 
> 
> 
> 
> 
> 
> _______________________________________________
> Pacemaker mailing list: Pacemaker at oss.clusterlabs.org
> http://oss.clusterlabs.org/mailman/listinfo/pacemaker
> 
> Project Home: http://www.clusterlabs.org
> Getting started:
> http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> Bugs: http://bugs.clusterlabs.org
> 



More information about the Pacemaker mailing list