Oci_close does not release the connection when using DRCP

Hello everyone,
we are currently testing the deplyment of DRCP with 11g. I have the whole thing setup (correctly to my best knowledge), but I am facing an issue. The call to oci_close does not seem to release the connection to the pool as I would expect and therefore we see similar behavior like we were getting without using the DRCP.
Our setup is using two RAC instances running 11.1.0.6.0, I am using PHP 5.1.6 with PECL installed oci8 1.3.4. The DRCP pool is configured and started, each with 100 max servers.
When the webserver is idle it looks, well, idle.
SQL> SELECT INST_ID,NUM_BUSY_SERVERS FROM GV$CPOOL_STATS;
INST_ID NUM_BUSY_SERVERS
1 0
2 0
The script is as simple as it gets:
<?php
$c = oci_pconnect('scott','tiger','IWPPOOLED');
$s = oci_parse($c, 'select * from emp');
$r = oci_execute($s, OCI_DEFAULT);
oci_close($c);
sleep(30);
?>
What I would expect is that the script would connect to the pool, do the work for a tiny moment and then release the connection for usage by other script.
But after I point the browser to the script, I get a 30 second loading time (as expected) but the server is busy all the time, like this:
SQL> SELECT INST_ID,NUM_BUSY_SERVERS FROM GV$CPOOL_STATS;
INST_ID NUM_BUSY_SERVERS
1 0
2 1
After the 30 second sleep, it is released and busy servers are back to 0.
If I load the server with ab using 256 connections:
ab -n 1000000 -c 256 -k http://mywebserver/ocitest.php
the pool is maxed out and the connects are stalling:
SQL> SELECT INST_ID,NUM_BUSY_SERVERS FROM GV$CPOOL_STATS;
INST_ID NUM_BUSY_SERVERS
1 95
2 95
My network config for this service is following:
IWPPOOLED =
(DESCRIPTION =
(LOAD_BALANCE=ON)
(FAILOVER=ON)
(ADDRESS = (PROTOCOL = tcp)(HOST = 10.1.16.33)(PORT = 1521))
(ADDRESS = (PROTOCOL = tcp)(HOST = 10.1.16.34)(PORT = 1521))
(CONNECT_DATA =
(SERVICE_NAME = IWP)
(SERVER=POOLED)
(FAILOVER_MODE=
(TYPE=SELECT)
(METHOD=BASIC)
(RETRIES=5)
(DELAY=3)
The phpinfo() look like this:
OCI8 Support enabled
Version 1.3.4
Revision $Revision: 1.269.2.16.2.38.2.20 $
Active Persistent Connections 1
Active Connections 1
Oracle Instant Client Version 11.1
Temporary Lob support enabled
Collections support enabled
Directive Local Value Master Value
oci8.connection_class IWPAPP IWPAPP
oci8.default_prefetch 100 100
oci8.events On On
oci8.max_persistent -1 -1
oci8.old_oci_close_semantics Off Off
oci8.persistent_timeout -1 -1
oci8.ping_interval -1 -1
oci8.privileged_connect Off Off
oci8.statement_cache_size 20 20
I am using the instant client for 11g
Any ideas?
Thanks!
Michal

Don't forget to use oci_free_statement($s); See "Closing Oracle Connections" in The Underground PHP and Oracle Manual. (I was just simplifying this example today for the next release of the manual).
You may also see the "dedicated optimization", where a pooled server in a non- maxed-out pool is retained (unless needed by another PHP process) under the assumption that the initial PHP process might become active again. See http://www.oracle.com/technology/tech/php/pdf/php-scalability-ha-twp.pdf
Feel free to email me offline (see my profile) if there are questions/data you don't want to post.
cj
Edited by: cj2 on Oct 16, 2008 8:12 AM

Similar Messages

  • EJB3 : suspend JTA transaction does not release the connection in the XA DS

    Hi all,
    I did a test and after suspending a JTA transaction I note that in the xa datasource the activeconnection = 1.
    So is it normal because I was thinking that when I suspend the transaction the teh connection is released and then after a transaction resume I could continue the transaction with another connection of the xa datasource ?
    Thank you for all..
    Christophe.

    It's a long time ago, but did you ever solve this problem?
    I'm having the same issue with OSB writing to a WLS8.1 JMS queue.
    I have a development OSB server which works fine.
    Pete

  • I want to mirror an iOS device to my computer for demonstration and training purposes.  I cannot use Airserver as my company VPN does not allow the connection.  Is there a hardware solution instead?

    I want to mirror an iOS device to my computer for demonstration and training purposes.  I cannot use Airserver as my company VPN does not allow the connection.  Is there a hardware solution instead?

    Shoeb, hi.
    Thanks for replying and apologies for my tardiness in responding. I have just completed a re-creation of my web page using CSS/HTML rather than XML/XSLT and now I find that when saving in MHT format the watermark/background image is saved, which is nice, but trying to save it as 'webpage complete' under 'save as' in the browser still does not work. (For those who are new to Firefox, MHT files are not supported by the browser, but using the FF extention UnMHT one can open such files and save web documents as MHT files, meaning no accompanying folder is required to properly view the file.)

  • I took video using my Iphone 4S and uploaded it into my Macbookpro iphoto.  When I open imovie it does not recognize the video when I import it manually it is distorted.

    I took video using my Iphone 4S and uploaded it into my Macbookpro iphoto.  When I open imovie it does not recognize the video when I import it manually it is distorted.

    Did you ever get an answer to this? I just experienced the distortion when I imported a video from my iPhone 4 to iPhoto.

  • HT4623 my ipad 2 is "stuck" with a connect to itunes on the screen ... and itunes says it could not restore the os ... so now itunes does not recognize the ipad when connected to the pc ... i have updated all software on the pc and disabled Norton as the

    my ipad 2 is "stuck" with a connect to itunes on the screen ... and itunes says it could not restore the os ... so now itunes does not recognize the ipad when connected to the pc ...i have updates all the software on the pc and disabled Norton as the troubleshoot instructions suggested; however itunes still does not recognize the ipad .... help!

    iPad: Basic troubleshooting
    http://support.apple.com/kb/TS3274
    Update and restore alert messages on iPhone, iPad, and iPod touch
    http://www.buybuyla.com/tech/view/012953a0d412000e.shtml
    iOS: Resolving update and restore alert messages
    http://support.apple.com/kb/TS1275
    iPad: Unable to update or restore
    http://support.apple.com/kb/ht4097
    iTunes: Specific update-and-restore error messages and advanced troubleshooting
    http://support.apple.com/kb/TS3694
    iPad not appearing in iTunes
    http://www.apple.com/support/ipad/assistant/itunes/
    iOS: Device not recognized in iTunes for Mac OS X
    http://support.apple.com/kb/TS1591
    iOS: Device not recognized in iTunes for Windows
    http://support.apple.com/kb/TS1538
    iTunes for Windows: Device Sync Tests
    http://support.apple.com/kb/HT4235
    IOS: Syncing with iTunes
    http://support.apple.com/kb/HT1386
    Apple - Support - iPad - Syncing
    http://www.apple.com/support/ipad/syncing/
    iTunes 10.5 and later: Troubleshooting iTunes Wi-Fi Syncing
    http://support.apple.com/kb/ts4062
     Cheers, Tom

  • I just purchased a new Linksys E2500 router.  It will connect to all my other devices, but does not recognize the password when sent from the PowerBook G4.

    I just purchased a new Linksys E2500 router.  It will connect to all my other devices, but does not recognize the password when sent from the PowerBook G4.  When I try it responds that the password is invalid.  I have connected my MacBook Pro, iPad and iPod Touch with the same password. 

    Charles Swigart wrote:
    It will connect to all my other devices, but does not recognize the password when sent from the PowerBook G4.
    Try putting $ (a dollar sign) in front of the password.

  • HELP - PC Suite does not support the connected pho...

    After trying numerous times now I cannot get my question to you via your website. In utter frustration I am posting my problem here.
    My problem is as follows
    When I connect my phone via cable to my laptop I get the following error message. 'PC Suite does not support the connected phone. Install a correct version of PC Suite and try again'. I have already uninstalled the version that previously worked fine and downloaded the version recommended by your website which is 6.80.22. This is actually the version I already had which previously did work. I amd still getting the same error message despite uninstalling and reinstalling numerous times. And when I plug my phone into my partners computer it works fine. He has the same operating system and version of PC Suite. I am using Windows XP Home Service Pack. I have a Nokia 6131

    Thanks for the descriptive posting, unfortunately there are still many things that can be wrong.
    You should try the things that are suggested here in many places: go to control panel - add/remove programs and select first Nokia PC Connectivity Solution and run a repair to it by selecting change - repair. Then same thing for Nokia PC Suite, run a repair to it.
    Then boot PC.
    Then check the PC Suite manage connections icon to make sure that the DKU-2, CA-53 USB connection is activated.

  • JInternalFrame is closed, but does not release the memory

    Hi,
    I have problem with using of JInternalFrame.
    I create a new internal frame, and close it."setClosed(true);dispose();"
    The frame does not release the memory (after gc the allocated memory is the same)
    Before close I removed all listeners, and closed all reference to other object. (I think so :-) )
    Do You have any idees?
    regards
    G�bor

    Hi,
    I think u will have to release all the associated used objects. or you can also call the finalize() method in order to release the memory.
    Regards,
    Balaji.SN

  • PC Suite does not support the connected phone........

    Hi...
    I have a big problem in the delivery of mobile and my type is N70 with Computer shows a message saying that some files missing from the mobile and this is the message that appears when connectivity.
    PC Suite does not support the connected phone. PC Suite settings file is missing from the phone. Switch off your phone, switch it on, and try again.
    Please assist in this matter, I can either send a site that I downloaded through by mobile phone.
    thank you very much..
    Moderator note: telephone number removed. It is not advised to publish personal contact information on a publically-accessible web forum.
    Message Edited by michaels on 14-Feb-2008 08:40 PM

    Hi Guys,
    It always better to give more information when you are posting your issues....Please try to give your system info, versions of the pc suite you are facing the issue :-( so that it may help others to narrow down ur issues :-)

  • Ovi Suite/PC Suite does not recognize the connecte...

    Error message: "Ovi Suite/PC Suite does not recognize the connected phone.Ovi Suite/Pc Suite cannot read the required information from the phone.Check that the connected phone is supported by Ovi Suite/PC Suite".
    You can try this which can solve your problem.
    1. Disconnect your phone from PC if connected.
    2 .Open Control Panel and go to ‘Programs and Features’
    3. From the list of available programs, choose ‘Nokia Connectivity Cable Driver’
    4. Click on the ‘Change’ button on top toolbar. 
    5. In the setup dialog box that pops up next, choose ‘Repair’ and select ok. Wait for setup to complete.
    6. Restart the computer if prompted.
    7. Now connect your phone to the PC. Driver installation should complete and PC/Ovi suite (hopefully) should detect your mobile properly now.
    Please THANK me by clicking on the ****WHITE STAR** ( Giving KUDOS) the big GREEN BOX to your LEFT .
    It will help me to serve you better !!!!!
    Thanking You

    @ Omarbooyaka,
    Welcome to the forum! You should use Nokia Suite to update your device to Belle. If still the same, please go to control panel > printer and devices > right click the phone icon > remove the device. Then try to connet again. Also try all the steps provided by magovoru. Could you also report the issue here if connection still does not work.
    Hope this helps!
    Jampe
    If the answer solves your issue, please click the ACCEPT AS SOLUTION button so other users can benefit from it as well. Giving a kudos (the white star) if my answer has helped will be appreciated.

  • My I Pod touch 4th gen does not display as connected when I enter i Tunes

    My I Pod touch 4th gen does not display as connected when I enter i Tunes, although my battery is being charged and my computer recognizes it, the problem persists. I have also tried the apple troubleshoot for this, but it hasn't worked.

    What Apple troubleshooting did you try?  This one?
    iOS: Device not recognized in iTunes for Windows
    B-rock

  • Live type files look grainy and do not fill the background when used for green screen backgrounds.

    live type files look grainy and do not fill the background when used for green screen backgrounds. Ideas?

    What I want to do is somehow make my entire iMovie project smaller by compressing it somehow but without losing any footage or audio or quality. At the moment the project is a 56GB iMovie project lasting approx 1hr. I have a mixture of miniDV footage, titles created in Live Type (they are better quality than anything available in iMovie) and audio.
    The miniDV footage is automatically compressed when it transfers from my camcorder to my Mac, no worries there.
    The LiveType titles contain a motion background (imported into LT) and then text which appears and disappears at set points. The titles vary in length but are about 5 seconds each.
    The file size for the LT titles is approx 180MB per clip, the movie requires about 20 or so of these clips, making a very large file size overall.
    Is there a way that I can save something in LT so that the file size is smaller yet still keep the quality and use the clip in my iMovie ?

  • Log onto incoming mail server (POP3): Your server does not support the connection encryption type you have specified. Try changing the encryption method. Contact your mail server administrator or Internet service provider (ISP) for additional assistance.

    Hi All,
    This is my first post to ms exchange forum am getting  Log onto incoming mail server (POP3): Your server does not support the connection encryption type you have specified. Try changing the encryption method. Contact your mail server administrator
    or Internet service provider (ISP) for additional assistance. in my outlook clients, till last Sunday (12.04.15) my exchange was well & good, Monday morning suddenly the problem started like none of our outlook pop3 clients are able to communicate
    with exchange (rest  IMAP, SMTP & Exchange accounts are working fine). i have tried with all port no but no luck. please help me to get raid of this one.
    Exchange 2013 CU6 with server 2012 Std 64Bit
    Thanks,
    Murali 

    Dear All,
    I have found the solution for above problem, the problem has occur due to PopProxy inactivity
    please find relevant exchange management shell commends below.
    1. Get-ServerComponentstate -Identity <yourmailserver.com> 
    Server Component State
    yourmailserver.com ServerWideOffline Active
    yourmailserver.com HubTransport Active
    yourmailserver.com FrontendTransport Active
    yourmailserver.com Monitoring Active
    yourmailserver.com RecoveryActionsEnabled Active
    yourmailserver.com AutoDiscoverProxy Active
    yourmailserver.com ActiveSyncProxy Active
    yourmailserver.com EcpProxy Active
    yourmailserver.com EwsProxy Active
    yourmailserver.com ImapProxy Active
    yourmailserver.com OabProxy Active
    yourmailserver.com OwaProxy Active
    yourmailserver.com PopProxy Inactive
    yourmailserver.com PushNotificationsProxy Active
    yourmailserver.com RpsProxy Active
    yourmailserver.com RwsProxy Active
    yourmailserver.com RpcProxy Active
    yourmailserver.com UMCallRouter Active
    yourmailserver.com XropProxy Active
    yourmailserver.com HttpProxyAvailabilityGroup Active
    yourmailserver.com ForwardSyncDaemon Active
    yourmailserver.com ProvisioningRps Active
    yourmailserver.com MapiProxy Active
    yourmailserver.com EdgeTransport Active
    yourmailserver.com HighAvailability Active
    yourmailserver.com SharedCache Active
    2. Set-ServerComponentState -Identity <yourmailserver.com> -Component PopProxy -Requester HealthAPI
    -State Active
    3. Get-ServerComponentstate -Identity <yourmailserver.com> 
    Server Component State
    yourmailserver.com ServerWideOffline Active
    yourmailserver.com HubTransport Active
    yourmailserver.com FrontendTransport Active
    yourmailserver.com Monitoring Active
    yourmailserver.com RecoveryActionsEnabled Active
    yourmailserver.com AutoDiscoverProxy Active
    yourmailserver.com ActiveSyncProxy Active
    yourmailserver.com EcpProxy Active
    yourmailserver.com EwsProxy Active
    yourmailserver.com ImapProxy Active
    yourmailserver.com OabProxy Active
    yourmailserver.com OwaProxy Active
    yourmailserver.com PopProxy Active
    yourmailserver.com PushNotificationsProxy Active
    yourmailserver.com RpsProxy Active
    yourmailserver.com RwsProxy Active
    yourmailserver.com RpcProxy Active
    yourmailserver.com UMCallRouter Active
    yourmailserver.com XropProxy Active
    yourmailserver.com HttpProxyAvailabilityGroup Active
    yourmailserver.com ForwardSyncDaemon Active
    yourmailserver.com ProvisioningRps Active
    yourmailserver.com MapiProxy Active
    yourmailserver.com EdgeTransport Active
    yourmailserver.com HighAvailability Active
    yourmailserver.com SharedCache Activ
    Replace yourmailserver.com with your server host name.
    Thanks

  • Msi x99 gaming 9 ack does not detect capture card when using with xsplit

    msi x99 gaming 9 ack does not detect capture card when using with xsplit
    i install every but still it does not work.

    Hi
    It wasn&#39;t hard to find your motherboard version:
    http://www.msi.com/support/mb/Z68AGD80_B3.html#down-bios
    Since your BIOS is v20.1, it couldn&#39;t be G3 
    Apart from checking BIOS, you can only check motherboard or moth...

  • JMF Does not release the RTP ports

    Hi,
    I am working on a program that simply listens RTP messages from the network and play them on a PC. My datasource is created as follows:
    String url2= "rtp://127.0.0.1:10000/audio/1";
    medialocator=new MediaLocator(url2);
    ds=Manager.createDataSource(medialocator);
    This ds will later be given to a player for the local playback. It has a flow like this: DS->Processor->DS->Player.
    Everything works fine for the first execution. The stream is played. However when I stop the player, processor and even the ds, JMF does not realease the RTP ports. I still can see them in the netstat output. Heres how I try to release the resources:
    public void releaseResources(){
    try{
    if(player!=null){
    player.stop();
    player.deallocate();
    player=null;
    if(ds2!=null){
    ds2.stop();
    ds2.disconnect();
    ds2=null;
    if(processor!=null){
    processor.stop();
    processor.removeControllerListener(this);
    processor.deallocate();
    medialocator=null;
    ds=null;
    Because of this problem, when I try to do the same thing on the same url after sometime, it gives the error "Cannot create the RTP Session: Can't open local data port: 10000". The ports are released after I shutdown the JVM.
    Does anyone have an idea on how to release this ports in the same JVM session?
    Thanks a lot,
    Murat

    DataSource objects open a connection to their source, in your case, a connection to an RTP port. You need to call
    ds.disconnect()
    on both datasources, but SPECIFICLLY on ds (as opposed to ds2) if you want it to release the port.

Maybe you are looking for

  • My US ATV in the UK isn't working properly. Can anyone advise please?

    My friend bought me an ATV from the US, but I can't seem to get it to work properly. It's plugged into a US-UK adaptor, powers up fine, got past the point where I connect to my network. It's just when I get to the main menu screen, it freezes up - st

  • Upgrade from Sol10U3 - U4 causes crash

    So I updated my box to Sol10U4 (Sparc sun4v T1000) and on reboot I get the following: Boot device: disk File and args: SunOS Release 5.10 Version Generic_120011-14 64-bit Copyright 1983-2007 Sun Microsystems, Inc. All rights reserved. Use is subject

  • Spry accordion not collapsing

    Hi, I am having trouble getting spry to work properly in Internet Explorer and Firefox. It works perfectly in Safari. Please see the link on my test server: http://deptart2.memphis.edu/~jwilcoxen/web_portfolio/home.php . I would appreciate any help y

  • Error :CIM_ERR_FAILED:HTTP response code:501 Not Implemented_Unsupporte

    Hello gurus iam facing the below error when trying to do the initial Setup on PI 7.1 running on Windows 64bit,Oracle Error :CIM_ERR_FAILED:HTTP response code:501 Not Implemented_Unsupported-protocol version i have checked the following notes 1115280,

  • Pages error

    Hello. I have a problem with pages. I get the message : can not open document, when i try to open my pages file. Can anybody help. Svein H