Re: connection dropped from the backend server

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: armand pirvu <armand(dot)pirvu(at)gmail(dot)com>
Cc: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: connection dropped from the backend server
Date: 2018-03-27 23:11:32
Message-ID: 0b0e0503-0e34-32cd-50a7-9be77601a2a5@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 03/27/2018 04:07 PM, armand pirvu wrote:
> As long as the connection stays up yes data gets fine across
> In pg_stat_activity I see the node ip address where tail -f piped into psql happens

So what does the rest of that record show? In particular for:

state
query
backend_start

and any others you might think are important from here:

https://www.postgresql.org/docs/10/static/monitoring-stats.html#PG-STAT-ACTIVITY-VIEW

>
>
>
> Sent from my iPhone
>
>> On Mar 27, 2018, at 6:03 PM, Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> wrote:
>>
>>> On 03/27/2018 03:36 PM, armand pirvu wrote:
>>> Hi all
>>> I have a process of some data manipulation and ultimate transfer to a postgres database
>>> A DML statement gest concoted with the transformed data and pusshed into a named pipe
>>> The named pipe is tailed -f in the background like this
>>> nohup $SHELL <<EOF &
>>> tail -f /u1/sys_admin/dba/mypipe.fifo | psql -U csidba -d repdb -h rephost
>>> EOF
>>> All good BUT I do notice every say 10 min although I see the tail and psql processes in the ps output, looking in pg_stat_activity there is really nothing the host I run the nohuped tail
>>
>> Could it be that pg_stat_activity shows nothing because the DML has completed when you look?
>>
>> Does the data find its way into the database?
>>
>>> Any suggestions how to approach this/make it better/monitor ?
>>> Thanks
>>> -- Armand
>>
>>
>> --
>> Adrian Klaver
>> adrian(dot)klaver(at)aklaver(dot)com
>

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2018-03-27 23:49:42 Re: connection dropped from the backend server
Previous Message armand pirvu 2018-03-27 23:07:58 Re: connection dropped from the backend server