php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #42704 Memory exhausted with --with-sybase=/usr/local/freetds and --enable-soap used
Submitted: 2007-09-18 19:16 UTC Modified: 2007-09-19 21:32 UTC
Votes:4
Avg. Score:5.0 ± 0.0
Reproduced:3 of 3 (100.0%)
Same Version:2 (66.7%)
Same OS:2 (66.7%)
From: carl dot washburn at iridium dot com Assigned:
Status: Not a bug Package: Sybase (dblib) related
PHP Version: 5.2.4 OS: Solaris 10
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
18 + 9 = ?
Subscribe to this entry?

 
 [2007-09-18 19:16 UTC] carl dot washburn at iridium dot com
Description:
------------
I have seen this problem in both 5.2.3 and 5.2.4. 
If I compile php with:
--with-sybase=/usr/local/freetds
--enable-soap, 
I receive the following when calling sybase_query:
"Allowed memory size of 104857600 bytes exhausted (tried to allocate 4722688 bytes)"

If I use:
ini_set("memory_limit","-1");
ini_set("max_execution_time","-1");
I receive from the same call to sybase_query:
"Out of memory (allocated 8156348416) (tried to allocate 370671616 bytes)" .

The query returns requested information if I do not enable soap extensions.

Expected result:
----------------
Query to return the same information as without --enable-soap.

Actual result:
--------------
Query fails.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-09-18 23:10 UTC] carl dot washburn at iridium dot com
Added info:

This is 64 bit php build. 32 bit has not been tested.

Code that reproduces bug:
<?php
$btime=mktime(0,0,0,09,17,2007);
$etime=mktime(23,59,59,09,18,2007);
sybase_connect('OURhost','OURuser','OURpass');
sybase_select_db("OURdb");
$querytxt="SELECT COUNT(MT_ID_) FROM MTTS_MaintenanceTicket WHERE
(Creation_Date_Time__Submit__ BETWEEN CONVERT(INT,'$btime') AND
CONVERT(INT,'$etime') OR Modified_Date_Time_ BETWEEN CONVERT(INT,'$btime') AND CONVERT(INT,'$etime')) AND CONVERT(VARCHAR,Priority__code_) like '%' AND CONVERT(VARCHAR,MT_State_) like '%' AND Assigned_to__Login_Name_ LIKE '%' AND MT_ID_ like '%' AND(Ownership_Server_ LIKE '%' OR To_Server LIKE '$server' or Current_Server LIKE '$server') ORDER BY Creation_Date_Time__Submit__";
$mttsq=sybase_query("$querytxt");
?>
 [2007-09-19 13:32 UTC] jani@php.net
Since ext/soap has absolutely nothing to do with ext/sybase it sounds a bit far fetched that simply disabling ext/soap in the build would have any effect on this. Are you sure you don't have some prepend/append stuff set in your php.ini that might be doing something with soap? What is the full configure line that causes the problem? And what is the full configure line that works?
 [2007-09-19 14:31 UTC] carl dot washburn at iridium dot com
Currently doing a recompile to have apples to apples comparison with and without soap. Will post config lines when finished.

Soap Section of php.ini:
[soap]
soap.wsdl_cache_enabled=1
soap.wsdl_cache_dir="/tmp"
soap.wsdl_cache_ttl=86400
 [2007-09-19 21:32 UTC] carl dot washburn at iridium dot com
Mea Culpa.
When compiling multiple configurations I discovered that the freetds drivers were different versions between my production and test servers. After regressing to libsybdb.so.4.0.0 the issue was resolved. Thank you for your help.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 15:01:28 2024 UTC