Mail Archives: cygwin-developers/2002/01/09/11:57:31
--VywGB/WGlW4DM4P8
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Norman,
On Wed, Jan 09, 2002 at 11:39:56AM -0500, Norman Vine wrote:
> OK -- using snapshots from cygwin.com
>
> postgres runs fine using snapshot DLL dated 20011231
> crashes for me with all DLL's dated 20020104 and later
>
> I have a locally built DLL 20020103 that also crashes
Please try to determine what specific Cygwin change is causing the
postmaster problem. Since the date range is small, searching cygwin-cvs
should not take too long.
> FWIW
> In an attempt to see if this was just an introduced 'incompatability'
> with previous cygwin dlls I tried building postgres from scratch
> with todays Cygwin CVS files
> make check failed for me with < failed to createdb >
> This could be do to local error however as I am not all that
> familiar with the postgres build
> < I used script from Cygwin postgres distribution >
See attached for how to fix the above make check problem. I normal would
use an URL, but the PostgreSQL archvies are "under construction" right
now. Please read the README regarding other known make check problems.
Thanks,
Jason
--VywGB/WGlW4DM4P8
Content-Type: message/rfc822
Content-Disposition: inline
Return-Path: <tgl AT sss DOT pgh DOT pa DOT us>
Received: from mh12-tx.mail.home.com ([65.10.73.160])
by femail5.sdc1.sfba.home.com
(InterMail vM.4.01.03.20 201-229-121-120-20010223) with ESMTP
id <20020103220555 DOT RRWC27 DOT femail5 DOT sdc1 DOT sfba DOT home DOT com AT mh12-tx DOT mail DOT home DOT com>
for <jtishler AT mail DOT etntwn1 DOT nj DOT home DOT com>;
Thu, 3 Jan 2002 14:05:55 -0800
Received: from mx12-tx.mail.home.com (mx12-tx.mail.home.com [65.10.73.156])
by mh12-tx.mail.home.com (8.9.3/8.9.0) with ESMTP id OAA10665
for <jtishler AT home DOT com>; Thu, 3 Jan 2002 14:05:54 -0800 (PST)
Received: from lmg04.affinity.com (lmg.affinity.com [207.150.192.13])
by mx12-tx.mail.home.com (8.11.1/8.11.1) with ESMTP id g03M5sx17963
for <jtishler AT home DOT com>; Thu, 3 Jan 2002 14:05:54 -0800 (PST)
Received: from internal by lmg.ahnet.net with cust_req_fwding id <320102-12785>; Thu, 3 Jan 2002 13:56:31 +0000
Received: from sss.pgh.pa.us ([192.204.191.242]) by lmg.ahnet.net with ESMTP id <342596-12787>; Thu, 3 Jan 2002 13:55:48 +0000
Received: from sss2.sss.pgh.pa.us (tgl AT localhost [127.0.0.1])
by sss.pgh.pa.us (8.11.4/8.11.4) with ESMTP id g03Ltjg27632;
Thu, 3 Jan 2002 16:55:46 -0500 (EST)
To: Jason Tishler <jason AT tishler DOT net>
cc: Pgsql-Patches <pgsql-patches AT postgresql DOT org>
Subject: Re: [PATCHES] pg_regress.sh startup failure patch
In-reply-to: <20020103192842 DOT GA1380 AT dothill DOT com>
References: <20020103115553 DOT GA496 AT dothill DOT com> <12844 DOT 1010071685 AT sss DOT pgh DOT pa DOT us> <20020103164215 DOT GA1836 AT dothill DOT com> <13227 DOT 1010076426 AT sss DOT pgh DOT pa DOT us> <20020103192842 DOT GA1380 AT dothill DOT com>
Comments: In-reply-to Jason Tishler <jason AT tishler DOT net>
message dated "Thu, 03 Jan 2002 14:28:42 -0500"
Date: Thu, 03 Jan 2002 16:55:45 -0500
Message-ID: <27629 DOT 1010094945 AT sss DOT pgh DOT pa DOT us>
From: Tom Lane <tgl AT sss DOT pgh DOT pa DOT us>
Jason Tishler <jason AT tishler DOT net> writes:
> I just checked one of my old favorites, "The UNIX Programming
> Environment," by Kernighan and Pike, 1984. It appears that "until"
> is understood by the Bourne shell back then, so its use should be OK.
Yeah, that's what I thought. I ended up applying the attached patch;
this not only avoids the timing problem but has more reliable detection
of postmaster startup failure than the original code.
regards, tom lane
*** src/test/regress/pg_regress.sh.orig Sun Sep 16 12:11:11 2001
--- src/test/regress/pg_regress.sh Thu Jan 3 16:52:05 2002
***************
*** 353,358 ****
--- 353,379 ----
"$bindir/postmaster" -D "$PGDATA" -F $postmaster_options >"$LOGDIR/postmaster.log" 2>&1 &
postmaster_pid=$!
+ # Wait till postmaster is able to accept connections (normally only
+ # a second or so, but Cygwin is reportedly *much* slower). Don't
+ # wait forever, however.
+ i=0
+ max=60
+ until "$bindir/psql" $psql_options template1 </dev/null 2>/dev/null
+ do
+ i=`expr $i + 1`
+ if [ $i -ge $max ]
+ then
+ break
+ fi
+ if kill -0 $postmaster_pid >/dev/null 2>&1
+ then
+ : still starting up
+ else
+ break
+ fi
+ sleep 1
+ done
+
if kill -0 $postmaster_pid >/dev/null 2>&1
then
echo "running on port $PGPORT with pid $postmaster_pid"
***************
*** 363,371 ****
echo
(exit 2); exit
fi
-
- # give postmaster some time to pass WAL recovery
- sleep 3
else # not temp-install
--- 384,389 ----
--VywGB/WGlW4DM4P8--
- Raw text -