Re: Problem with pl/python procedure connecting to the internet

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: Igor Sosa Mayor <joseleopoldo1792(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Problem with pl/python procedure connecting to the internet
Date: 2015-08-23 23:45:06
Message-ID: 55DA5B02.4070103@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 08/23/2015 01:15 PM, Igor Sosa Mayor wrote:
> Igor Sosa Mayor <joseleopoldo1792(at)gmail(dot)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(dot)klaver(at)aklaver(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Smith 2015-08-24 00:09:51 Re: fastes way to retrieve segmented without using loop
Previous Message Melvin Davidson 2015-08-23 22:20:34 Re: fastes way to retrieve segmented without using loop