Thread

  1. Postmaster 7.1.2 hanging

    Justin Clift <aa2@bigpond.net.au> — 2001-07-06T04:42:21Z

    Hi all,
    
    Running Mandrake 7.2, personally compiled version of PostgreSQL 7.1.2.
    
    Just did a :
    
    pg_ctl stop -m fast
    
    And the postmaster process won't die.
    
    Waited for about 2 minutes, then sent a normal everyday kill signal to the 
    postmaster process from the root user (just in case).  Haven't done a kill 9.
    
    The last part of the postgresql log is :
    
    pq_recvbuf: unexpected EOF on client connection
    ERROR:  <unnamed> referential integrity violation - key referenced from 
    goods_bought not found in goods
    pq_recvbuf: unexpected EOF on client connection
    pq_recvbuf: unexpected EOF on client connection
    pq_recvbuf: unexpected EOF on client connection
    pq_recvbuf: unexpected EOF on client connection
    Fast Shutdown request at Fri Jul  6 14:33:57 2001
    Aborting any active transaction...
    FATAL 1:  This connection has been terminated by the administrator.
    
    I shutdown the Tomcat process before doing any of this, so I'm thinking 
    that's the cause of the unexpected EOF's just before this.
    
    When using "ps -ef" I get this listing of the PostgreSQL processes :
    
    postgres 16067     1  0 Jul04 ?        00:00:07 
    /opt/postgresql/bin/postmaster -D /opt/postgresql/data -d 0 -i  
    
    So, any ideas what's jamming the database on?
    
    This isn't urgent, it's a development database I have plenty of recent 
    backups of, more to let people know it's happening.
    
    Regards and best wishes,
    
    Justin Clift
    
    
  2. Re: Postmaster 7.1.2 hanging

    Tom Lane <tgl@sss.pgh.pa.us> — 2001-07-06T13:21:38Z

    Justin Clift <aa2@bigpond.net.au> writes:
    > Just did a :
    > pg_ctl stop -m fast
    > And the postmaster process won't die.
    
    Can't duplicate it here.  Can you attach to the postmaster process with
    a debugger and see what it thinks its state is?  The static variables in
    postmaster.c are the things to look at.  Are there still entries
    in BackendList?  Are any of StartupPID, ShutdownPID, CheckPointPID
    nonzero?  What's the value of Shutdown?  Etc.
    
    			regards, tom lane
    
    
  3. Re: Postmaster 7.1.2 hanging

    Justin Clift <justin@postgresql.org> — 2001-07-07T06:08:47Z

    Hi Tom,
    
    I had to kill -9 the postmaster process and go from there about 2
    minutes after sending that email.  Although the data wasn't important,
    the availability of PostgreSQL on the server was.  Had to get it up and
    running again asap.
    
    If it happens again, I'll attach a debugger to the postmaster process as
    you've suggested and see what it thinks is going on.
    
    :-)
    
    Regards and best wishes,
    
    Justin Clift
    
    Tom Lane wrote:
    > 
    > Justin Clift <aa2@bigpond.net.au> writes:
    > > Just did a :
    > > pg_ctl stop -m fast
    > > And the postmaster process won't die.
    > 
    > Can't duplicate it here.  Can you attach to the postmaster process with
    > a debugger and see what it thinks its state is?  The static variables in
    > postmaster.c are the things to look at.  Are there still entries
    > in BackendList?  Are any of StartupPID, ShutdownPID, CheckPointPID
    > nonzero?  What's the value of Shutdown?  Etc.
    > 
    >                         regards, tom lane
    > 
    > ---------------------------(end of broadcast)---------------------------
    > TIP 3: if posting/reading through Usenet, please send an appropriate
    > subscribe-nomail command to majordomo@postgresql.org so that your
    > message can get through to the mailing list cleanly