The esql hangs during rolling back a transaction
Posted in 2010
Topics: Connectivity: ESQL/C, 4GL & Embedded SQL, Platform-Specific Issues
We have an application written in esqlc communicating to informix dynamic server 11.50.FC3 on HP-UX 11.23. The client SDK is 3.50.UC7. The application tries to update a row in a table and fails. Then it tries to rollback the transaction and hangs
Here is more information on it. When it fails updating the row, it return
SQLCODE -346, but does not give any ISAM error. We have condition that, if
ISAM error code is greater than 0, dump it in a file, but it is not dumping.The stack trace, when it hangs is taken and it shows as below:
0: 60000000c0361670 : _recv_sys() + 0x30 (/usr/lib/hpux32/libc.so.1)
1: 60000000c0375010 : _recv() + 0x170 (/usr/lib/hpux32/libc.so.1)
2: 60000000c7cf32f0 : recvsocket() + 0x200
(/opt/isv/CSDK_3.50UC7_32bit/lib/libifasf.so)
3: 60000000c7cdf1d0 : tlRecv() + 0xd0
(/opt/isv/CSDK_3.50UC7_32bit/lib/libifasf.so)
4: 60000000c7cdadf0 : slSQIrecv() + 0x690
(/opt/isv/CSDK_3.50UC7_32bit/lib/libifasf.so)
5: 60000000c7cc8be0 : pfRecv() + 0x120
(/opt/isv/CSDK_3.50UC7_32bit/lib/libifasf.so)
6: 60000000c7c9a470 : asfRecv() + 0x30
(/opt/isv/CSDK_3.50UC7_32bit/lib/libifasf.so)
7: 60000000c7c9daa0 : ASF_Call() + 0x2e0
(/opt/isv/CSDK_3.50UC7_32bit/lib/libifasf.so)
8: 60000000c75db6a0 : asf_recv() + 0x60
(/opt/isv/CSDK_3.50UC7_32bit/lib/esql/libifos.so)
9: 60000000c75d4600 : _igetint() + 0x180
(/opt/isv/CSDK_3.50UC7_32bit/lib/esql/libifos.so)
10: 60000000c7527480 : _sqr_messages() + 0x100
(/opt/isv/CSDK_3.50UC7_32bit/lib/esql/libifsql.so)
11: 60000000c7565520 : sqli_trans_rollback() + 0x1a0
(/opt/isv/CSDK_3.50UC7_32bit/lib/esql/libifsql.so)
12: 0000000004070180 : finish_trans() + 0x70 (/catalyst/bin/c01610)
13: 000000000405a480 : inet_addr() + 0x1c20 (/catalyst/bin/c01610)
14: 000000000405e540 : inet_addr() + 0x5ce0 (/catalyst/bin/c01610)
15: 00000000040a7260 : allocate_item() + 0x860 (/catalyst/bin/c01610)
16: 0000000004053020 : rgetlmsg() + 0x420 (/catalyst/bin/c01610)
17: 000000000404f5e0 : typeahead() + 0x1560 (/catalyst/bin/c01610)
18: 0000000004102e70 : o_screen() + 0x590 (/catalyst/bin/c01610)
19: 00000000040506d0 : sqli_curs_fetch() + 0xc0 (/catalyst/bin/c01610)
20: 60000000c0026430 : main_opd_entry() + 0x50 (/usr/lib/hpux32/dld.so)
I am not able to understand this trace. My code is something, the function
allocate_item calls a function to update the data. When update fails, the
function calls another function to log error by calling rgetlmsg(). After
logging error, it calls finish_trans() to rollback the transaction. If the
process is hung during rollback, by this time rgelmsg() would have completed.
Then why it is showing rgetlmsg in the trace? Does these functions invoke
different thread?
This does not hang on all machines. On my development box, it works fine
whereas at customer box, it gets hung. Any help will be appriciated.
Thanks in advance.
Swamy