Problem with i5_pclose after Zend Server upgrade

Problem with i5_pclose after Zend Server upgrade

Postby bran5102 on Wed Oct 12, 2016 7:36 am

Hi,

We have just upgraded our system operating system from V6R1 to V7R2 and at the same time moved from Zend Core to Zend Server 8.5

When a php program is called it creates a persistent connection using i5_pconnect, does some work, displays results, and then closes connection using i5_pclose.

This works fine first time php program is run.

When it is next run we get the error after the i5_pclose of;

SQLSTATE='' and Message: '', indicating that this PHP job's associated database job is no longer running.

As part of the move to Zend Server we have added in the php programs the include of the Compatibility Wrapper to allow the i5_ functions to work.

Any help would be appreciated as for now we have commented out the i5_pclose, which has caused problems of its own in that the php programs get slower as the day goes on.

Brandon
bran5102
 
Posts: 9
Joined: Thu Dec 03, 2015 4:41 pm

Re: Problem with i5_pclose after Zend Server upgrade

Postby bran5102 on Wed Oct 12, 2016 8:05 am

As note regarding performance of just having i5_pconnect with no i5_pclose,

We noticed that each time the PHP application used other i5_ functions like i5_program_prepare, an information message was added to the QSQSRVR job dealing with it and then we could see a Zend related processes doing a DSPJOBLOG of the QSQSRVR job, which we assume was for it to check for success.

During the course of the day we could see that the job log of the QSQSRVR job contained thousands of messages and therefore the DSPJOBLOG took seconds to do.

Brandon
bran5102
 
Posts: 9
Joined: Thu Dec 03, 2015 4:41 pm

Re: Problem with i5_pclose after Zend Server upgrade

Postby aseiden on Wed Oct 12, 2016 5:48 pm

Brandon, the i5_pclose ends the persistent database connection underneath. To allow PHP to regenerate the connection, add this line to /usr/local/zendsvr6/conf.d/ibm_db2.ini, then restart Zend Server:
ibm_db2.i5_check_pconnect = 1

Alan Seiden
http://www.seidengroup.com
aseiden
 
Posts: 868
Joined: Thu Apr 09, 2009 5:45 pm

Re: Problem with i5_pclose after Zend Server upgrade

Postby bran5102 on Mon Nov 07, 2016 3:32 pm

Hi Alan,

Still getting the error message "Error: SQLSTATE='' and Message: '',
indicating that this PHP job's associated database job is no longer
running."

The php scripts typically do a i5_pconnect, then a number of
i5_program_prepare & i5_program_call, followed by an i5_pclose

It appears to be the next i5_pconnect which is failing.

Some of the scripts also have some SQL in them and use db2_connect then
db2_exec...

Could it be the mixing of the 2 different connections in the same script?

Brandon
bran5102
 
Posts: 9
Joined: Thu Dec 03, 2015 4:41 pm


Return to New Toolkit

Who is online

Users browsing this forum: No registered users and 2 guests

cron