Thread: pqReadData() -- backend closed the channel unexpectedly (huh?)

pqReadData() -- backend closed the channel unexpectedly (huh?)

From
Frank Miles
Date:
Hello all:

    I have a simple database which is now exhibiting some strange symptoms.
The most obviously sick is where I try to delete a record in a table, and
get the response:

    pqReadData() -- backend closed the channel unexpectedly.
            This probably means the backend terminated abnormally
            before or while processing the request.
    The connection to the server was lost. Attempting reset: Failed.

I dropped the database, and restored it from a backup.  Same results.
Vacuum analyze doesn't complain.  I turned on debug messages from the
postmaster, but didn't see anything that pointed to the problem.  For the
record, the log shows:

    StartTransactionCommand
    query: SELECT usesuper FROM pg_user WHERE usename = 'fpm'
    ProcessQuery
    CommitTransactionCommand
    StartTransactionCommand
    query:  select * from units ;
    ProcessQuery
    CommitTransactionCommand
    StartTransactionCommand
    query: delete from units where unit_id = 5;
    ProcessQuery
    /opt/pgsql/bin/postmaster: reaping dead processes...
    /opt/pgsql/bin/postmaster: CleanupProc: pid 21004 exited with status 139
    Server process (pid 21004) exited with status 139 at Tue Nov  7 11:04:56 2000
    Terminating any active server processes...
    Server processes were terminated at Tue Nov  7 11:04:56 2000
    Reinitializing shared memory and semaphores
    shmem_exit(0)
    binding ShmemCreate(key=52e325, size=1104896)
    /opt/pgsql/bin/postmaster: ServerLoop:          handling reading 5
    /opt/pgsql/bin/postmaster: ServerLoop:          handling reading 5
    DEBUG:  Data Base System is starting up at Tue Nov  7 11:04:56 2000
    DEBUG:  Data Base System was interrupted being in production at Tue Nov  7 11:04:40 2000
    /opt/pgsql/bin/postmaster: ServerLoop:          handling writing 5
    The Data Base System is starting up
    /opt/pgsql/bin/postmaster: ServerLoop:          handling writing 5
    DEBUG:  Data Base System is in production state at Tue Nov  7 11:04:56 2000
    proc_exit(0)
    shmem_exit(0)
    exit(0)
    /opt/pgsql/bin/postmaster: reaping dead processes...

Version: 7.0.2.

Any suggestions on how/where to look for the source of the problem?

Thanks....

    -frank



Re: pqReadData() -- backend closed the channel unexpectedly (huh?)

From
Tom Lane
Date:
Frank Miles <fpm@u.washington.edu> writes:
>     query: delete from units where unit_id = 5;
>     ProcessQuery
>     /opt/pgsql/bin/postmaster: reaping dead processes...
>     /opt/pgsql/bin/postmaster: CleanupProc: pid 21004 exited with status 139
>     Server process (pid 21004) exited with status 139 at Tue Nov  7 11:04:56 2000

There should be a core file left over from the backend crash in the
subdirectory for the database.  Can you provide a debugger backtrace
from the corefile?

            regards, tom lane