From: | Robert Burgholzer <rburghol(at)vt(dot)edu> |
---|---|
To: | Joe Conway <mail(at)joeconway(dot)com> |
Cc: | "Burgholzer, Robert (DEQ)" <Robert(dot)Burgholzer(at)deq(dot)virginia(dot)gov>, Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com>, pgsql-admin(at)postgresql(dot)org |
Subject: | Re: diagnosing a db crash - server exit code 2 |
Date: | 2011-10-03 17:34:20 |
Message-ID: | CACT-NGLpWxh1h7nvHSwptxZ19KBn0UfqLbX7JnjAbj7yhtTZMA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
Thanks Joe - yeah, I am now tracing the postmaster -- will post up shortly.
r.b.
On Mon, Oct 3, 2011 at 1:28 PM, Joe Conway <mail(at)joeconway(dot)com> wrote:
> On 10/03/2011 10:10 AM, Robert Burgholzer wrote:
> > FWIW - I am currently trying this while tracing the process that I
> > assume is the postmaster (/usr/bin/postgres -D /home/postgres/data),
> > since this process number indicates that it was recently restarted -
> > although the other PG processes, writer, wal writer, autovacuum, stats
> > collector all have their older pids indicating that they still survive.
>
> Sounds like you are attaching to the wrong process. Try something like
> the below...
>
> Joe
>
>
>
> Session #1: (connect to db and load PL/R)
> -----------------
> #psql contrib_regression
> psql (9.2devel)
> Type "help" for help.
>
> contrib_regression=# load '$libdir/plr';
> LOAD
>
> Session #2: (use ps to find backend and attach)
> -----------------
> # ps -ef |grep postgres
> postgres 17001 1 0 Sep24 ? 00:00:16
> /usr/local/pgsql-head/bin/postgres -D /usr/local/pgsql-head/data -p 55437
> -i
> postgres 17006 17001 0 Sep24 ? 00:02:18 postgres: writer process
>
> postgres 17007 17001 0 Sep24 ? 00:01:50 postgres: wal writer
> process
> postgres 17008 17001 0 Sep24 ? 00:00:37 postgres: autovacuum
> launcher process
> postgres 17009 17001 0 Sep24 ? 00:00:47 postgres: stats
> collector process
> postgres 26631 17001 0 10:22 ? 00:00:00 postgres: postgres
> contrib_regression [local] idle
>
> #gdb /usr/local/pgsql-head/bin/postgres 26631
> (gdb) continue
> Continuing.
>
>
> Session #1: (run crashing function)
> -----------------
> run your PL/R function that causes the crash
>
>
> --
> Joe Conway
> credativ LLC: http://www.credativ.us
> Linux, PostgreSQL, and general Open Source
> Training, Service, Consulting, & 24x7 Support
>
--
--
Robert W. Burgholzer
http://www.findingfreestyle.com/
On Facebook -
http://www.facebook.com/pages/Finding-Freestyle/151918511505970
Twitter - http://www.twitter.com/findfreestyle
What's a tweeted swim set? A Sweet? No, a #swaiku! Get them by following
http://twitter.com/findfreestyle
From | Date | Subject | |
---|---|---|---|
Next Message | Julien Rouhaud | 2011-10-03 17:48:41 | Re: commiting transaction from outside |
Previous Message | Joe Conway | 2011-10-03 17:28:47 | Re: diagnosing a db crash - server exit code 2 |