[Pacemaker] Postgres RA won't start

Serge Dubrouski sergeyfd at gmail.com
Thu Oct 13 08:35:27 EDT 2011


On Thu, Oct 13, 2011 at 4:29 AM, Lars Ellenberg
<lars.ellenberg at linbit.com>wrote:

> On Wed, Oct 12, 2011 at 07:41:20PM -0600, Serge Dubrouski wrote:
> > On Wed, Oct 12, 2011 at 9:20 AM, Amar Prasovic <amar at linux.org.ba>
> wrote:
> >
> > > Thank you all for tips and suggestions. I managed to configure postgres
> so
> > > it actually starts.
> > >
> > > First, I updated resource-agents (Florian thanks for the tip, still
> don't
> > > know how did I manage to miss that :) )
> > > Second, I deleted postgres primitive, cleared all failcounts and
> configure
> > > it again like this:
> > >
> > > primitive postgres_res ocf:heartbeat:pgsql \
> > >         params pgctl="/usr/lib/postgresql/8.4/bin/pg_ctl"
> > > psql="/usr/bin/psql" start_opt="" pgdata="/var/lib/postgresql/8.4/main"
> > > config="/etc/postgresql/8.4/main/postgresql.conf" pgdba="postgres" \
> > >
> > >         op start interval="0" timeout="120s" \
> > >         op stop interval="0" timeout="120s" \
> > >         op monitor interval="30s" timeout="30s" depth="0"
> > >
> > > After that, it all worked like a charm.
> > >
> > > However, I noticed some strange output in the log file, it wasn't there
> > > before I updated the resource-agents.
> > >
> > > Here is the extract from the syslog:
> > >
> > > http://pastebin.com/ybPi0VMp
> > >
> > > (postgres_res:monitor:stderr) [: 647: monitor: unexpected operator
> > >
> > > This error is actually reported with any operator. I tried to start the
> > > script from CLI, I got the same thing with ./pgsql start, ./pgsql
> status,
> > > ./pgsql stop
> > >
> >
> > Weird. I don't know what to tell. The RA is basically all right, it just
> > misses one nor very important fix. On my system CentOS 5. PosgreSQL 8.4
> or
> > 9.0 it doesn't produce any errors. If understand you log right the
> problem
> > is in line 647 of the RA which is:
> >
> > [ "$1" == "validate-all" ] && exit $rc
>
>  "==" != "="
>
>
Theoretically yes "=" is for strings and "==" is for numbers. But why it
would create a problem on Debian and not on CentOS and why nobody else
reported this issue so far?

BTW, other RAs use  "==" operator as well: apache, LVM, portblock,


> Make that [ "$1" = "validate-all" ] && exit $rc
>
>
> --
> : Lars Ellenberg
> : LINBIT | Your Way to High Availability
> : DRBD/HA support and consulting http://www.linbit.com
>
> _______________________________________________
> 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://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker
>



-- 
Serge Dubrouski.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clusterlabs.org/pipermail/pacemaker/attachments/20111013/b4399f47/attachment-0003.html>


More information about the Pacemaker mailing list