<br><br><div class="gmail_quote">On Thu, Oct 13, 2011 at 4:29 AM, Lars Ellenberg <span dir="ltr"><<a href="mailto:lars.ellenberg@linbit.com">lars.ellenberg@linbit.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div><div></div><div class="h5">On Wed, Oct 12, 2011 at 07:41:20PM -0600, Serge Dubrouski wrote:<br>
> On Wed, Oct 12, 2011 at 9:20 AM, Amar Prasovic <<a href="mailto:amar@linux.org.ba">amar@linux.org.ba</a>> wrote:<br>
><br>
> > Thank you all for tips and suggestions. I managed to configure postgres so<br>
> > it actually starts.<br>
> ><br>
> > First, I updated resource-agents (Florian thanks for the tip, still don't<br>
> > know how did I manage to miss that :) )<br>
> > Second, I deleted postgres primitive, cleared all failcounts and configure<br>
> > it again like this:<br>
> ><br>
> > primitive postgres_res ocf:heartbeat:pgsql \<br>
> >         params pgctl="/usr/lib/postgresql/8.4/bin/pg_ctl"<br>
> > psql="/usr/bin/psql" start_opt="" pgdata="/var/lib/postgresql/8.4/main"<br>
> > config="/etc/postgresql/8.4/main/postgresql.conf" pgdba="postgres" \<br>
> ><br>
> >         op start interval="0" timeout="120s" \<br>
> >         op stop interval="0" timeout="120s" \<br>
> >         op monitor interval="30s" timeout="30s" depth="0"<br>
> ><br>
> > After that, it all worked like a charm.<br>
> ><br>
> > However, I noticed some strange output in the log file, it wasn't there<br>
> > before I updated the resource-agents.<br>
> ><br>
> > Here is the extract from the syslog:<br>
> ><br>
> > <a href="http://pastebin.com/ybPi0VMp" target="_blank">http://pastebin.com/ybPi0VMp</a><br>
> ><br>
> > (postgres_res:monitor:stderr) [: 647: monitor: unexpected operator<br>
> ><br>
> > This error is actually reported with any operator. I tried to start the<br>
> > script from CLI, I got the same thing with ./pgsql start, ./pgsql status,<br>
> > ./pgsql stop<br>
> ><br>
><br>
> Weird. I don't know what to tell. The RA is basically all right, it just<br>
> misses one nor very important fix. On my system CentOS 5. PosgreSQL 8.4 or<br>
> 9.0 it doesn't produce any errors. If understand you log right the problem<br>
> is in line 647 of the RA which is:<br>
><br>
> [ "$1" == "validate-all" ] && exit $rc<br>
<br>
</div></div> "==" != "="<br>
<br></blockquote><div><br>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? <br>
<br>BTW, other RAs use  "==" operator as well: apache, LVM, portblock, <br> <br></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

Make that [ "$1" = "validate-all" ] && exit $rc<br>
<font color="#888888"><br>
<br>
--<br>
: Lars Ellenberg<br>
: LINBIT | Your Way to High Availability<br>
: DRBD/HA support and consulting <a href="http://www.linbit.com" target="_blank">http://www.linbit.com</a><br>
</font><div><div></div><div class="h5"><br>
_______________________________________________<br>
Pacemaker mailing list: <a href="mailto:Pacemaker@oss.clusterlabs.org">Pacemaker@oss.clusterlabs.org</a><br>
<a href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target="_blank">http://oss.clusterlabs.org/mailman/listinfo/pacemaker</a><br>
<br>
Project Home: <a href="http://www.clusterlabs.org" target="_blank">http://www.clusterlabs.org</a><br>
Getting started: <a href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target="_blank">http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</a><br>
Bugs: <a href="http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker" target="_blank">http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Serge Dubrouski.<br>