[OpenSIPS-Users] db_mysql_convert_rows says no rows but there is one

Calvin Ellison calvin.ellison at voxox.com
Sun Mar 15 22:40:52 EST 2020


This does not happen on every query response but will happen on every
response for the same query. CLI mysql and mariadb clients show the result
row correctly, and pcaps confirm that opensips is getting the row response
(attached).

I recompiled opensips against libmariadbclient (Ubuntu
libmariadbclient-dev-compat) but that did not change the behavior. Debug
for a working and non-working query below.

Pcap:
https://drive.google.com/file/d/1Un8dx8T3eFEhe8_jYIONrLVGhiQ6Xhj6/view?usp=sharing

opensips -V
version: opensips 2.4.7 (x86_64/linux)
flags: STATS: On, DISABLE_NAGLE, USE_MCAST, SHM_MMAP, PKG_MALLOC, F_MALLOC,
FAST_LOCK-ADAPTIVE_WAIT
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16,
MAX_URI_SIZE 1024, BUF_SIZE 65535
poll method support: poll, epoll, sigio_rt, select.
git revision: 9e1fcc915
main.c compiled on  with gcc 7

Mar 14 20:18:57 localhost /usr/sbin/opensips[2158]:
DBG:avpops:ops_async_dbquery: query [call
lrn.fulldataz('6198077359',curdate())]
Mar 14 20:18:57 localhost /usr/sbin/opensips[2158]: DBG:core:db_init_async:
>>    1/220 transfers: (6 - 0x7fb7cc2f5ec8)
Mar 14 20:18:57 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:mysql_raise_event: MySQL status has not changed: connected
Mar 14 20:18:57 localhost /usr/sbin/opensips[2158]: DBG:tm:t_handle_async:
placing async job into reactor
Mar 14 20:18:57 localhost /usr/sbin/opensips[2158]: DBG:tm:io_watch_add:
[UDP_worker] io_watch_add op (6 on 12) (0x5605efdf65a0, 6, 16,
0x7fb78c103358,1), fd_no=4/104857
Mar 14 20:18:57 localhost /usr/sbin/opensips[2158]:
DBG:core:destroy_avp_list: destroying list (nil)
Mar 14 20:18:57 localhost /usr/sbin/opensips[2158]: DBG:core:receive_msg:
cleaning up
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]: DBG:tm:t_resume_async:
resuming on fd 6, transaction 0x7fb78c1001a0
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_async_resume: mysql_read_query_result: 0, 00000 - ""
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]: DBG:core:db_new_result:
allocate 48 bytes for result set at 0x7fb7cc2f4ac8
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: 15 columns returned from the query
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:core:db_allocate_columns: allocate 420 bytes for result columns at
0x7fb7cc2f6878
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f68f0)[0]=[number]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6900)[1]=[lrn]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6910)[2]=[port type]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_INT result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6920)[3]=[state]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6930)[4]=[network]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6940)[5]=[ocn]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6950)[6]=[ratecenter]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6960)[7]=[class]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6970)[8]=[lata]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6980)[9]=[country]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f6990)[10]=[reachable]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_BIGINT result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f69a0)[11]=[reason]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_STRING result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f69b0)[12]=[dnc]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_INT result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f69c0)[13]=[good]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_BIGINT result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: RES_NAMES(0x7fb7cc2f69d0)[14]=[delay]
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_get_columns: use DB_DOUBLE result type
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:db_mysql:db_mysql_convert_rows: no rows returned from the query
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:core:db_store_async_con: >> restore conn 0x7fb7cc2f5ec8
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:avpops:resume_async_dbquery: query returned no results
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:core:db_free_columns: freeing result columns at 0x7fb7cc2f6878
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]: DBG:core:db_free_rows:
freeing 0 rows
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]:
DBG:core:db_free_result: freeing result set at 0x7fb7cc2f4ac8
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]: DBG:tm:io_watch_del:
[UDP_worker] io_watch_del op on index -1 6 (0x5605efdf65a0, 6, -1,
0x10,0x1) fd_no=5 called
Mar 14 20:18:58 localhost /usr/sbin/opensips[2158]: DBG:core:cachedb_store:
from script [memcached] - with grp [lrn]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20200315/6f81c8cd/attachment-0001.html>


More information about the Users mailing list