RE: [PEAR] Segmentation Fault with Oracle / oci8.php
| From: | Florian Clever | Date: | Mon, 10 Dec 2001 15:58:09 +0000 |
| Subject: | RE: [PEAR] Segmentation Fault with Oracle / oci8.php | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-592@lists.php.net to get a copy of this message | ||
I have experienced probably the same problem without using PEAR.
If I open OCI connections and cursors and call exit(), in one of the
subsequent requests, apache will die.
PS: On windows the dieing of Apache seems to happen faster than on Linux.
Florian
http://fc.clever-soft.com/
> -----Original Message-----
> From: Bertrand Mansion [mailto:bmansion@mamasam.com]
> Sent: Monday, December 10, 2001 1:39 AM
> To: Thies C. Arntzen
> Cc: Karsten Kraus; pear-general@lists.php.net; pear-dev@lists.php.net
> Subject: Re: [PEAR] Segmentation Fault with Oracle / oci8.php
>
>
> le 8/12/01 10:40, Thies C. Arntzen à thies@thieso.net a écrit :
>
> > On Fri, Dec 07, 2001 at 10:41:45AM +0100, Bertrand Mansion wrote:
> >> <Karsten.Kraus@web.de> wrote :
> >>
> >>> Hi list,
> >>>
> >>> perhaps on of you can help me to solve this:
> >>>
> >>> i'm using php 4.0.6 with apache 1.3.19 on linux (kernel 2.2.1x).
> >>> When I turn off autocommit, and try doing an insert statement
> >>> (which could have an error, but that shouldn't be the problem)
> >>> with simple_query, php hangs when it tries to do OCIExecute($sql,
> >>> OCI_DEFAULT)...
> >
> > if you send me a short testcase i'll do a proper fix.
> > the method shown below will cause troube with persistent
> > connection when a script gets terminated abnormally. your
> > open transactions will be committed instead of rolled back -
> > whcih is _NOT_ what you want!!
> >
> > tc
>
> Hi Thies,
>
> Sorry for not replying sooner, I was away this weekend.
>
> I use PHP 4.0.6 on Linux (RedHat or Suse, maybe others) and work
> with Oracle
> 8.1.7 and 9.0.1 SE installed as servers. Apache is 1.3.20 and
> 1.3.22 with 5
> processes (I've also used it with 1 process in order to debug) as
> this will
> cause it to crash quicker. PHP is compiled with oci8 and sigchild enabled.
> All paths are set up correctly before apache starts.
>
> I remember the crash happening when I was using PEAR Auth class
> with a PEAR
> DB container and issued an exit(); or die(); in the drawLogin() method in
> order to get rid of the need to use checkAuth method.
>
> After some tests, I noticed that every time I would issue exit();
> or die();
> after having opened a new connection (and even if I did nothing with it),
> php would log 'failed to rollback outstanding transactions' and
> after a few
> warnings like these, Apache would crash. Oci8 was trying to rollback
> outstanding transactions but there was none.
>
> Somebody else I know does not use PEAR DB but get the same errors.
>
> According to me, just end up one of your scripts, which does not have any
> outstanding transactions, with an exit(); at some time and this should do
> the trick.
>
> If the number of Apache processes is bigger, Apache does not seem to crash
> though. So keep it low.
>
> Another bug I found in oci8.c was with ociInternalDebug. Use it and then
> issue an exit(); and it will make a crash. Haven't looked any
> closer at this
> one.
>
> If that's not enough to get rid of this evil bug, let me know, I
> will try to
> work on a pre-made script but this will take longer as I will
> need to set up
> still another dev environment.
>
> Thanks for your time and for your interest in this.
>
> Bertrand Mansion
> Mamasam
>
>
>
>
>
> --
> PEAR General Mailing List (http://pear.php.net/)
> To unsubscribe, e-mail: pear-general-unsubscribe@lists.php.net
> For additional commands, e-mail: pear-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>