From: Craig Ringer <ringerc@ringerc.id.au>
To: c k <shreeseva.learning@gmail.com>
Cc: Adrian Klaver <adrian.klaver@gmail.com>
Cc: pgsql-general@postgresql.org
Subject: Re: postgresql server crash on windows 7 when using plpython
Date: Thu, 11 Aug 2011 08:07:35 +0800
Message-ID: <4E431D47.6060609@ringerc.id.au> (raw)
In-Reply-To: <CAN2Y=uPDc_n1_rCahkX7bHCO28P=WKqNr5ziGM-2JRecK=_yPg@mail.gmail.com>
References: <CAN2Y=uMs3SwWwogKpazMPKFTbuJZngOhaDLxYg+XReJK=BzpPA@mail.gmail.com>
<CANf5jyPA2Sq1vaHGk0VCT6yPGyiiHspuxFyK3eWYV+xsGR04TA@mail.gmail.com>
<CAN2Y=uNbpzZ=z_KHBOwf_4qcOuZNp+PrPYMaF7qvQ_Wi7YOJLA@mail.gmail.com>
<201108100704.44907.adrian.klaver@gmail.com>
<CAN2Y=uPDc_n1_rCahkX7bHCO28P=WKqNr5ziGM-2JRecK=_yPg@mail.gmail.com>
On 11/08/2011 1:00 AM, c k wrote:
> I have renamed uuid-ossp.dll to 0uuid-ossp.dll in postgresql's lib
> directory. But it is also found that postgresql's bin directory is not
> included in the path.
It doesn't have to be. On Windows, the directory containing the current
executable is implicitly the first path entry. Since postgres.exe lives
in the same directory as uuid-ossp.dll, that's the copy of the DLL
that'll be called.
> Then started the postgresql again, called the same plpython function
> again and again server crashed without any details in the log.
> Also searched for the above dll or similar in python's installation but
> not founf, one available was not dll but was .py file.
OK, so maybe Python doesn't use uuid-ossp but its own implementation in
pure Python. I'll pull out a Windows box and check.
> Recent log contains following lines.
> *Fatal Python error: PyThreadState_Get: no current thread*
Hmm, that's interesting. Thanks for supplying the error message; looks
like I was probably on entirely the wrong track because I was forced to
guess with not enough information.
If I get a chance I'll have a play with the function you posted and see
if I can reproduce the crash on my Win7 box.
In the mean time, if you want you can try to collect some more
information about the crash according to these instructions:
http://wiki.postgresql.org/wiki/Getting_a_stack_trace_of_a_running_PostgreSQL_backend_on_Windows
--
Craig Ringer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-admin@postgresql.org
Cc: ringerc@ringerc.id.au, shreeseva.learning@gmail.com, adrian.klaver@gmail.com, pgsql-general@postgresql.org
Subject: Re: postgresql server crash on windows 7 when using plpython
In-Reply-To: <4E431D47.6060609@ringerc.id.au>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox