<div dir="ltr">Thank you. <div>Seems that I all my problems are related to tmp folders being cleared after every reboot. SOme of them, like postgres locks are recreated with old permissions.<div><br></div><div>Will have to write a script to solve this. To my surprise, pgpool install does not take care of this. At least not in 10.04.</div>
<div><br></div><div>Thanks again.</div><div>Gintas</div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Feb 6, 2014 at 4:56 PM, Lachezar Dobrev <span dir="ltr"><<a href="mailto:l.dobrev@gmail.com" target="_blank">l.dobrev@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">  Are you using a Debian or derivative?<br>
  Under Debian /var/run is sym-linked to /run, which is a mounted<br>
temporary in-memory file system, that does not survive between<br>
reboots. Typically such /var/run/whatever stuff is handled by an<br>
/etc/init.d/whatever script that is used to manage the service.<br>
<br>
  What I can suggest as an UGLY work-around is to use /tmp/pgpool/<br>
instead of /var/run/pgpool.<br>
<br>
2014-02-06 16:45 GMT+02:00 Gintautas Sulskus <<a href="mailto:gingaz@gmail.com">gingaz@gmail.com</a>>:<br>
<div class="HOEnZb"><div class="h5">> Well, permissions seem to be fine. This occurs after the first<br>
> post-installation reboot.<br>
> The only action I perform are:<br>
> 1. install & cofing pgool according the tutorial<br>
> 2. install and condig pgpoolAdmin according the tutorial<br>
> 3. set load balancing & replication mode in pgpoolAdmin<br>
> 4. shut down one node to see how pgpool(Admin) behaves<br>
> 5. "sudo reboot"<br>
> 6. kaput :)<br>
><br>
><br>
> Gintas<br>
><br>
><br>
> On Thu, Feb 6, 2014 at 12:06 PM, Gintautas Sulskus <<a href="mailto:gingaz@gmail.com">gingaz@gmail.com</a>> wrote:<br>
>><br>
>> after reboot I perform:<br>
>> sudo mkdir /var/run/pgpool (pgpool dir is deleted after every "sudo<br>
>> reboot")<br>
>> sudo chmod 777 /var/run/pgpool/ -R<br>
>> sudo chown www-data /var/run/pgpool/ -R<br>
>><br>
>> Then pgpool complains about missing pgpool.pid.<br>
>> I think this is not a correct thing to do but I create pid file:<br>
>> sudo touch /var/run/pgpool/pgpool.pid<br>
>> sudo chmod 777 /var/run/pgpool/ -R<br>
>> sudo chown www-data /var/run/pgpool/ -R<br>
>><br>
>> Then it throws "pcp_stop_pgpool command error occurred." error and stops<br>
>> reacting to any command.<br>
>><br>
>> I will take a look at relevant permissions. All this started after reboot.<br>
>><br>
>> Gintas<br>
>><br>
>><br>
>> On Thu, Feb 6, 2014 at 9:50 AM, Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>> wrote:<br>
>>><br>
>>> On Thu, 6 Feb 2014 09:33:42 +0000<br>
>>> Gintautas Sulskus <<a href="mailto:gingaz@gmail.com">gingaz@gmail.com</a>> wrote:<br>
>>><br>
>>> > Thanks, Yugo.<br>
>>> ><br>
>>> > However, now I keep getting  "pgpool start failed. pgpool.pid not<br>
>>> > found" when<br>
>>> > i try to launch pgpool from pgpoolAdmin.<br>
>>> > Any ideas?<br>
>>><br>
>>> Is pid_file_name's value 'var/run/pgpool/pgpool.pid'?<br>
>>><br>
>>> ><br>
>>> > pgpool is not running.<br>
>>> ><br>
>>> > Regards,<br>
>>> > Gintas<br>
>>> ><br>
>>> ><br>
>>> > On Thu, Feb 6, 2014 at 8:25 AM, Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>><br>
>>> > wrote:<br>
>>> ><br>
>>> > > Hi,<br>
>>> > ><br>
>>> > > On Thu, 6 Feb 2014 07:41:22 +0000<br>
>>> > > Gintautas Sulskus <<a href="mailto:gingaz@gmail.com">gingaz@gmail.com</a>> wrote:<br>
>>> > ><br>
>>> > > > Hello,<br>
>>> > > ><br>
>>> > > > whenever I reboot my machine /var/run.pgpool dir gets removed and<br>
>>> > > > is not<br>
>>> > > > recreated on startup.<br>
>>> > > > If I create it manually and perform chmod 755 pgpoolAdmin<br>
>>> > > > complains:<br>
>>> > > ><br>
>>> > > > pgpool start failed. pgpool.pid not found<br>
>>> > > ><br>
>>> > > > 2014-02-06 07:33:31 ERROR: pid 1473: could not open pid file as<br>
>>> > > > /var/run/pgpool/pgpool.pid. reason: Permission denied<br>
>>> > ><br>
>>> > > If you use pgpoolAdmin, apache user should have permission to write<br>
>>> > > to /var/run/pgpool directory.Try<br>
>>> > ><br>
>>> > >  $ chomod 777 /var/run/pgpool<br>
>>> > ><br>
>>> > > or<br>
>>> > ><br>
>>> > >  $ chown apache /var/run/pgpool<br>
>>> > ><br>
>>> > > ><br>
>>> > > > Do you know what is the cause and what is the best way to solve it?<br>
>>> > > ><br>
>>> > > > I'm running Ubuntu 10.04.4 LTS 64 bit.<br>
>>> > > ><br>
>>> > > > Best Regards,<br>
>>> > > > Gintas<br>
>>> > ><br>
>>> > ><br>
>>> > > --<br>
>>> > > Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>><br>
>>> > ><br>
>>> ><br>
>>> ><br>
>>> ><br>
>>> > --<br>
>>> > Best Regards,<br>
>>> > Gintautas Sulskus<br>
>>><br>
>>><br>
>>> --<br>
>>> Yugo Nagata <<a href="mailto:nagata@sraoss.co.jp">nagata@sraoss.co.jp</a>><br>
>><br>
>><br>
>><br>
>><br>
>> --<br>
>> Best Regards,<br>
>> Gintautas Sulskus<br>
><br>
><br>
><br>
><br>
> --<br>
> Best Regards,<br>
> Gintautas Sulskus<br>
><br>
</div></div><div class="HOEnZb"><div class="h5">> _______________________________________________<br>
> pgpool-general mailing list<br>
> <a href="mailto:pgpool-general@pgpool.net">pgpool-general@pgpool.net</a><br>
> <a href="http://www.pgpool.net/mailman/listinfo/pgpool-general" target="_blank">http://www.pgpool.net/mailman/listinfo/pgpool-general</a><br>
><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br>Best Regards,<br>Gintautas Sulskus
</div>