Re: Problem with pl/python procedure connecting to the internet - Mailing list pgsql-general

From Adrian Klaver
Subject Re: Problem with pl/python procedure connecting to the internet
Date
Msg-id 55DA5B02.4070103@aklaver.com
Whole thread Raw
In response to Re: Problem with pl/python procedure connecting to the internet  (Igor Sosa Mayor <joseleopoldo1792@gmail.com>)
List pgsql-general
On 08/23/2015 01:15 PM, Igor Sosa Mayor wrote:
> Igor Sosa Mayor <joseleopoldo1792@gmail.com> writes:
>
>> My question is therefore:
>> 1. is there a way to permit the pl/python to connect to the internet all
>>     the time and with a better configuration?
>> 2. or should I forget the procedure and write a python script outside
>>     the database?
>
> I want to update the situation in this email following up my own email.
> Sorry for not answering every question (in any case: I don't have
> SElinux or similar).
>
> The situation is very strange. It works now perfectly BUT ONLY after
> restarting PG. I'm playing with the log options in PG and I don't see in
> the logs nothing strange (PG starts without problems).

As I understand it you are running everything on a laptop.

Are you saying the laptop has been running non-stop the three days this
discussion has been going on and Postgres was never shut down till now?


>
> But I see that the log options in PG are really rich. Could maybe
> someone tell me which could be the best options to find the problem? I
> will be offline now during 24h, but I will try to make some experiments
> in the meantime.

 From here:
http://www.postgresql.org/docs/9.4/interactive/runtime-config-logging.html#RUNTIME-CONFIG-LOGGING-WHAT

I would at least log:

log_connections
log_disconnections

log_statement 'mod'

log_line_prefix %u %m %p


So does looking back in the logs, either Postgres or system, show anything?


>
> Thanks again for your help.
>
>


--
Adrian Klaver
adrian.klaver@aklaver.com


pgsql-general by date:

Previous
From: Melvin Davidson
Date:
Subject: Re: fastes way to retrieve segmented without using loop
Next
From: Tom Smith
Date:
Subject: Re: fastes way to retrieve segmented without using loop