<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif">Hi Mark,</div><div class="gmail_default" style="font-family:verdana,sans-serif">thanks for your suggestion. I use Debian disto, so I can&#39;t use sudo. What kind of script did Gervais use?</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">Do you have a tutorial?</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">Thanks in advance.</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_default" style="font-family:verdana,sans-serif">Alessio</div></div><div class="gmail_extra"><br><div class="gmail_quote">On 7 April 2015 at 09:14, Mark Kirkwood <span dir="ltr">&lt;<a href="mailto:mark.kirkwood@catalyst.net.nz" target="_blank">mark.kirkwood@catalyst.net.nz</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On 07/04/15 19:04, Yugo Nagata wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi Mephysto,<br>
<br>
On Tue, 7 Apr 2015 08:50:33 +0200<br>
Mephysto &lt;<a href="mailto:mephystoonhell@gmail.com" target="_blank">mephystoonhell@gmail.com</a>&gt; wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi there,<br>
I am trying for the first time to configure watchdog for pgpool-II 3.4.1.<br>
After doing some base settings in pgpool.conf, I tried to start pgpool, but<br>
I received some errore messages and watchdog are not working done. This is<br>
the log:<br>
<br>
<br>
<br>
2015-04-05 18:32:35: pid 5094: DETAIL:  ping data: PING localhost<br>
(127.0.0.1) 56(84) bytes of data.<br>
<br>
         --- localhost ping statistics ---<br>
         3 packets transmitted, 3 received, 0% packet loss, time 1999ms<br>
         rtt min/avg/max/mdev = 0.014/0.030/0.041/0.012 ms<br>
<br>
2015-04-05 18:32:35: pid 5094: LOG:  failed to create watchdog sending<br>
socket<br>
2015-04-05 18:32:35: pid 5094: DETAIL:  connect() reports failure<br>
&quot;Connection refused&quot;<br>
2015-04-05 18:32:35: pid 5094: HINT:  You can safely ignore this while<br>
starting up.<br>
2015-04-05 18:32:35: pid 5094: LOG:  watchdog sending packet for nodes<br>
2015-04-05 18:32:35: pid 5094: DETAIL:  packet for &quot;postgres-2:9000&quot; is<br>
canceled<br>
2015-04-05 18:32:38: pid 5094: DEBUG:  watchdog executing ping<br>
2015-04-05 18:32:38: pid 5094: DETAIL:  failed to ping &quot;192.168.56.249&quot;<br>
exit code: 1<br>
2015-04-05 18:32:38: pid 5094: LOG:  watchdog escalation<br>
2015-04-05 18:32:38: pid 5094: DETAIL:  escalating to master pgpool<br>
SIOCSIFADDR: Permission denied<br>
SIOCSIFFLAGS: Permission denied<br>
SIOCSIFNETMASK: Permission denied<br>
<br>
<br>
I&#39;m using postgres user to run pgpool process, so I presume these errors<br>
due to postgres user permission. I would not use root to run pgpool<br>
process, so I ask you if exists a manner to run watchdog without using root<br>
user.<br>
</blockquote>
<br>
You can use setuid. This tutorial would be helpful. Alhough<br>
this is using apache user instead of postgres user, the manner<br>
is the almost the same.<br>
<a href="http://www.pgpool.net/pgpool-web/contrib_docs/watchdog_master_slave_3.3/en.html#config_setuid" target="_blank">http://www.pgpool.net/pgpool-<u></u>web/contrib_docs/watchdog_<u></u>master_slave_3.3/en.html#<u></u>config_setuid</a><br>
<br>
</blockquote>
<br></div></div>
Personally I&#39;d advise against adding setuid - as it complicates installs (easy to forget) and is just one more security hole.<br>
<br>
Both myself and Gervais de Montburn have recently posted to this list methods to avoid this (sudo in my case and custom scripts in his). Either of these a) work and b) are preferable.<br>
<br>
Cheers<span class="HOEnZb"><font color="#888888"><br>
<br>
Mark<br>
<br>
<br>
</font></span></blockquote></div><br></div>