<div dir="ltr"><div><div><div>Hi Arnold,<br><br>I followed the procedure given by this document:<br><a href="http://wiki.postgresql.org/images/0/07/Ha_postgres.pdf" target="_blank">http://wiki.postgresql.org/images/0/07/Ha_postgres.pdf</a><br>
<br></div>I dont think i have missed any of the script you mentioned. Every time, i will create partition (with or without LVM), install DRBD, pacemaker and corosync, create/up/start drbd service. Finally i end with the same problem: DRBD resource agent startup problem / not configured.<br>
<br></div>Today i followed the procedure given by this document:<br><a href="https://wiki.ubuntu.com/ClusterStack/Natty">https://wiki.ubuntu.com/ClusterStack/Natty</a><br></div><div><br><div>With this ubuntu approach, it is working. Difference is, now i installed pacemaker/corosync first and then DRBD.<br>
</div><div><br></div><div>drbd/pacemaker developer has to tell us, whether there are any files they maintain in common and have conflict in version. <br></div><div><div><div><br></div></div></div></div></div><div class="gmail_extra">
<br><br><div class="gmail_quote">On Mon, Mar 17, 2014 at 9:18 AM, Siva Kumar <span dir="ltr"><<a href="mailto:shiv609@gmail.com" target="_blank">shiv609@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr"><div>I am trying to add replication support for my software.<br></div><div>I installed drbd, pacemaker and corosoft. OS used: Ubuntu 12.04.4 server edition.<br></div><div>DRBD: 8.4.4 installed from source.<br>
</div><div>Pacemaker, corosoft installed using apt-get<br></div><div><br></div><div>I tried to add the drbd resource agent to the crm configure command:<br>crm configure primitive drbd_pg ocf:linbit:drbd params drbd_resource="pg" op monitor interval="29s" role="Master" op monitor interval="31s" role="Slave"<br>
</div><div>crm configure ms ms_drbd_pg drbd_pg meta master-max="1" master-node-max="1" clone-max="2" clone-node-max="1" notify="true"<br> <br></div><div>The crm_mon shows the following status:<br>
<div style="margin-left:40px"><i>Last updated: Mon Mar 17 09:02:17 2014</i><br><i>Last change: Sun Mar 16 20:40:04 2014 via cibadmin on umonitor1</i><br><i>Stack: openais</i><br><i>Current DC: umonitor1 - partition with quorum</i><br>
<i>Version: 1.1.6-9971ebba4494012a93c03b40a2c58ec0eb60f50c</i><br><i>2 Nodes configured, 2 expected votes</i><br><i>2 Resources configured.</i><br><i>============</i><br><br><i>Online: [ umonitor1 umonitor2 ]</i><br><br>
<i> Master/Slave Set: ms_drbd_pg [drbd_pg]</i><br>
<i> drbd_pg:0 (ocf::linbit:drbd): Slave umonitor1 (unmanaged) FAILED</i><br><i> drbd_pg:1 (ocf::linbit:drbd): Slave umonitor2 (unmanaged) FAILED</i><br><br><i>Failed actions:</i><br><i> drbd_pg_monitor_0 (node=umonitor1, call=2, rc=6, status=complete): not configured</i><br>
<i> drbd_pg:0_stop_0 (node=umonitor1, call=8, rc=-2, status=Timed Out): unknown exec error</i><br><i> drbd_pg_monitor_0 (node=umonitor2, call=2, rc=6, status=complete): not configured</i><br><i> drbd_pg:1_stop_0 (node=umonitor2, call=19, rc=-2, status=Timed Out): unknown exec error</i><br>
</div><br><br></div><div>OCF tester gives the following results:<br>root@umonitor1:~# ocf-tester -n drbd_pg -o drbd_resource="pg" /usr/lib/ocf/resource.d/linbit/drbd start<br><div style="margin-left:40px"><i>Beginning tests for /usr/lib/ocf/resource.d/linbit/drbd...<br>
/usr/lib/ocf/resource.d/linbit/drbd: 117: /usr/lib/ocf/resource.d/linbit/drbd: [[: not found<br>/usr/lib/ocf/resource.d/linbit/drbd: 1079: /usr/lib/ocf/resource.d/linbit/drbd: Syntax error: end of file unexpected (expecting "}")<br>
* rc=2: Your agent has too restrictive permissions: should be 755<br>* rc=6: Validation failed. Did you supply enough options with -o ?<br>drbd[21719]: WARNING: You may be disappointed: This RA is intended for pacemaker 1.0 or better!<br>
drbd[21719]: ERROR: meta parameter misconfigured, expected clone-max -le 2, but found unset.<br>Aborting tests<br></i></div><br></div><div><br>bash -x result as follows:<br># export OCF_ROOT=/usr/lib/ocf<br># export OCF_RESKEY_drbd_resource="pg"<br>
# bash -x /usr/lib/ocf/resource.d/linbit/drbd start<br> .................<br><div style="margin-left:40px"><i>+ set --</i><br><i>+ local a=0 b=0 c=0</i><br><i>+ (( a > 3 ))</i><br><i>+ (( a == 3 && b > 0 ))</i><br>
<i>+ (( a == 3 && b == 0 && c > 0 ))</i><br><i>+ ocf_log warn 'You may be disappointed: This RA is intended for pacemaker 1.0 or better!'</i><br><i>/usr/lib/ocf/resource.d/linbit/drbd: line 883: ocf_log: command not found</i><br>
<i>+ meta_expect clone-max -le 2</i><br><i>+ local what=clone-max whatvar=OCF_RESKEY_CRM_meta_clone_max op=-le expect=2</i><br><i>+ local val=</i><br><i>+ [[ -n '' ]]</i><br><i>+ ocf_log err 'meta parameter misconfigured, expected clone-max -le 2, but found unset.'</i><br>
<i>/usr/lib/ocf/resource.d/linbit/drbd: line 866: ocf_log: command not found</i><br><i>+ exit</i><br><i>root@umonitor1:~#</i><br><i>root@umonitor1:~# ocf-tester -n drbd_pg -o drbd_resource="pg" -o meta_clone-max=1 /usr/lib/ocf/resource.d/linbit/drbd start</i><br>
<i>Beginning tests for /usr/lib/ocf/resource.d/linbit/drbd...</i><br><i>/usr/lib/ocf/resource.d/linbit/drbd: 117: /usr/lib/ocf/resource.d/linbit/drbd: [[: not found</i><br><i>/usr/lib/ocf/resource.d/linbit/drbd: 1079: /usr/lib/ocf/resource.d/linbit/drbd: Syntax error: end of file unexpected (expecting "}")</i><br>
<i>* rc=2: Your agent has too restrictive permissions: should be 755</i><br><i>/usr/sbin/ocf-tester: 268: export: OCF_RESKEY_meta_clone-max: bad variable name</i><br><i>root@umonitor1:~# ocf-tester -n drbd_pg -o drbd_resource="pg" /usr/lib/ocf/resource.d/linbit/drbd start</i><br>
<i>Beginning tests for /usr/lib/ocf/resource.d/linbit/drbd...</i><br><i>/usr/lib/ocf/resource.d/linbit/drbd: 117: /usr/lib/ocf/resource.d/linbit/drbd: [[: not found</i><br><i>/usr/lib/ocf/resource.d/linbit/drbd: 1079: /usr/lib/ocf/resource.d/linbit/drbd: Syntax error: end of file unexpected (expecting "}")</i><br>
<i>* rc=2: Your agent has too restrictive permissions: should be 755</i><br><i>* rc=6: Validation failed. Did you supply enough options with -o ?</i><br><i>drbd[21719]: WARNING: You may be disappointed: This RA is intended for pacemaker 1.0 or better!</i><br>
<i>drbd[21719]: ERROR: meta parameter misconfigured, expected clone-max -le 2, but found unset.</i><br><i>Aborting tests</i><br></div><br><br>DRBD status<br># cat /proc/drbd<br><div style="margin-left:40px"><i>version: 8.4.4 (api:1/proto:86-101)<br>
GIT-hash: 74402fecf24da8e5438171ee8c19e28627e1c98a build by root@umonitor1, 2014-03-16 19:43:58<br> 0: cs:Connected ro:Primary/Secondary ds:UpToDate/UpToDate C r-----<br> ns:192936 nr:0 dw:0 dr:193600 al:0 bm:23 lo:0 pe:0 ua:0 ap:0 ep:1 wo:f oos:0<br>
</i></div><br></div><div>pg.res file<br><div style="margin-left:40px"><i>resource pg {<br> device /dev/drbd0;<br> disk /dev/sda6;<br> syncer {<br> rate 150M;<br> verify-alg md5;<br>
}<br> on umonitor1 {<br> address <a href="http://192.168.1.33:7788" target="_blank">192.168.1.33:7788</a>;<br> meta-disk internal;<br> }<br> on umonitor2 {<br> address <a href="http://192.168.1.44:7788" target="_blank">192.168.1.44:7788</a>;<br>
meta-disk internal;<br> }<br>}<br></i></div><br></div><div><br></div><div>I am completely new to this linux HA cluster. I have been trying to solve this problem for a past couple of days.<br></div>
<div>
Kindly help me solving this problem.<br><br><br></div></div>
</blockquote></div><br><br clear="all"><br>-- <br>You are failed only when you giveup your trying.
</div>