X-Original-To: pgsql-admin@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 2C27B475843 for ; Mon, 17 Feb 2003 18:45:30 -0500 (EST) Received: from mta2.adelphia.net (unknown [64.8.50.178]) by postgresql.org (Postfix) with ESMTP id 8880E47580B for ; Mon, 17 Feb 2003 18:45:29 -0500 (EST) Received: from bingo ([68.70.98.78]) by mta2.adelphia.net (InterMail vM.5.01.05.25 201-253-122-126-125-20021216) with ESMTP id <20030217234531.MLEX16878.mta2.adelphia.net@bingo>; Mon, 17 Feb 2003 18:45:31 -0500 Content-Type: text/plain; charset="iso-8859-1" From: Ed Loehr To: Laurette Cisneros , Tom Lane Subject: Re: server won't shutdown Date: Mon, 17 Feb 2003 16:46:05 -0700 User-Agent: KMail/1.4.3 Cc: pgsql-admin@postgresql.org References: In-Reply-To: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200302171646.05331.ed@LoehrTech.com> X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200302/288 X-Sequence-Number: 7486 I've been seeing the same problem intermittently over the past 2 years=20 among ~30 production clusters. Today I saw it happen with 3-4 of the=20 7.2.3 clusters on the same host (PostgreSQL 7.2.3 on=20 i686-pc-linux-gnu, compiled by GCC 2.96 with 2.4.18-4bigmem kernel).=20=20 Each cluster had a number of long-idle connections, no current=20 activity. Will try to gather a little more data... Ed On Monday February 17 2003 3:56, Laurette Cisneros wrote: > Ok, my production server had this problem (again). So, here's the > info. you requested. There's a lot of postgres processes still > left running: > > postmaster (proc id 1457): > (gdb) print Shutdown > $1 =3D 2 > > Other backends (postgres) still hanging around: > postgres 1458 1457 0 Feb06 ? 00:22:41 postgres: stats > buffer process InterruptPending: $1 =3D 0 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 0 > ImmediateInterruptOK =3D $4 =3D 0 > InterruptHoldoffCount =3D $5 =3D 0 > CritSectionCount =3D $6 =3D 0 > > postgres 1459 1458 2 Feb06 ? 05:31:38 postgres: stats > collector process InterruptPending: $1 =3D 0 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 0 > ImmediateInterruptOK =3D $4 =3D 0 > InterruptHoldoffCount =3D $5 =3D 0 > CritSectionCount =3D $6 =3D 0 > > postgres 1468 1457 0 Feb06 ? 00:04:57 postgres: nbadmin > db1 111.123.123.244 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK =3D $4 =3D 0 > InterruptHoldoffCount =3D $5 =3D 0 > CritSectionCount =3D $6 =3D 0 > > postgres 1461 1457 0 Feb06 ? 00:02:06 postgres: nbadmin > db2 111.123.123.253 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 1478 1457 0 Feb06 ? 00:04:13 postgres: nbadmin > db3 111.123.124.244 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 9818 1457 0 Feb06 ? 00:00:01 postgres: nbadmin > db4 111.123.123.244 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 15677 1457 0 Feb06 ? 00:00:04 postgres: nbadmin > db5 111.123.123.253 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 30207 1457 0 Feb09 ? 00:00:00 postgres: nbadmin > db6 111.123.123.244 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 7316 1457 0 Feb11 ? 00:00:01 postgres: nbadmin > db7 111.123.123.244 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 10440 1457 0 Feb12 ? 00:00:00 postgres: nbadmin > db8 111.123.123.253 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 10441 1457 0 Feb12 ? 00:02:15 postgres: nbadmin > db9 111.123.123.253 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 27355 1457 0 Feb13 ? 00:00:00 postgres: nbadmin > db10 111.123.123.253 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 28491 1457 0 Feb13 ? 00:00:03 postgres: nbadmin > db11 111.123.123.253 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 30021 1457 0 Feb14 ? 00:00:01 postgres: nbadmin > db12 111.123.123.244 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 10663 1457 0 Feb14 ? 00:00:00 postgres: nbadmin > db13 111.123.123.244 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > postgres 10665 1457 0 Feb14 ? 00:00:00 postgres: nbadmin > db13 111.123.123.244 idle InterruptPending: $1 =3D 65537 > proc_exit_inprogress: $2 =3D 0 > ProcDiePending: $3 =3D 1 > ImmediateInterruptOK: $4 =3D 0 > InterruptHoldoffCount: $5 =3D 0 > CritSectionCount: $6 =3D 0 > > Thank again, > > Laurette > > On Thu, 13 Feb 2003, Tom Lane wrote: > > Laurette Cisneros writes: > > > Ok, it reproduced today on my development server. > > > > Boy, it sure looks like everything's just sitting idle waiting > > for client input, and hasn't noticed your shutdown request at > > all. You sure you used "-m fast"? Could you attach to the > > postmaster and see what its Shutdown variable contains, and to > > the backends and see what the variables manipulated by die() > > contain? (InterruptPending, proc_exit_inprogress, > > ProcDiePending, ImmediateInterruptOK, InterruptHoldoffCount, > > CritSectionCount) > > > > regards, tom lane