Hi Frank,
There were no changes in the db_unixodbc driver in OpenSIPS for some
time. Maybe something changed in the unixodbc driver for MS SQL.
Based on the this log:
core:db_table_version: invalid type (1) or nul (0)
I see that that the "table_version" from the version table is returned
as BIGINT, while OpenSIPS expects INT. Of course, this is something we
can quickly adjust.
In regards to the 'avp_db_query', could you post the level 3 logs
corresponding to the query ? Maybe it will give us a clue.
Regards,
Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
https://www.opensips-solutions.com
OpenSIPS Summit 2019
https://www.opensips.org/events/Summit-2019Amsterdam/
On 05/25/2019 07:33 AM, Frank Lee wrote:
Hello,
Was there some major change between version 1.11 and 2.4.5 on
supporting of the ODBC connection of Microsoft SQL Server? It seems I
had 1.11 running fine on SQL server (or at least partial table on sql
server such as location table). But now I use 2.4.5 it seems all the
module that uses odbc connector instead of the mysql connector it will
have the error below
core:db_table_version: invalid type (1) or nul (0)
Thus, I changed all the module to use mysql connector (except the
AVPOPS Module because I have custom query in the script which need to
query the Microsoft sql server) which made Opensips start out fine.
But as soon as it uses the avp_db_query in the script it seems it
would not work. Alhtough I don’t see any error in the syslog file
(although I had log_level set to 3, do I need to set it higher?)
Anyway, it just seems all the query/support to Microsoft SQL server
doesn’t run right in 2.4.5 vs 1.11.
Is there some dependency that I am suppose to install which is different?
I had my 1.11 run on Debian 7. Now we are moving to Azure cloud, I
had run Ubuntu 18.04 since Debian 7 is not support on Azure.
I had install odbc version 2.3.4 and also tdsodbc 1.00
Are these not to correct version to interface between 2.4.5 and
Microsoft sql server (I tried both version msssql 2008 and 2016).
Anyway, any pointer or help will be greatly appreciated!
Thank you!
*From:* Frank Lee [mailto:fr...@wtild.com]
*Sent:* Friday, May 24, 2019 10:58 AM
*To:* 'users@lists.opensips.org' <users@lists.opensips.org>
*Subject:* Opensip 2.4.5 Subscriber module on ODBC (MSSQL 2016 )
Hello,
This is the first time I use this mail message, so let me know if this
is not the correct way of posting question.
Anyway, I am running Opensips 2.4.5 and when I use MYSQL database on
all module, opensips runs fine. But as soon as I switch over the
database source to use ODBC driver (which is linked to Microsoft SQL
server 2016), I get this error. What is It mean?
May 24 17:36:48 osipibDprimary /usr/local/sbin/opensips[13534]:
ERROR:core:db_table_version: invalid type (1) or nul (0) version
columns for subscriber
May 24 17:36:48 osipibDprimary /usr/local/sbin/opensips[13534]:
ERROR:core:db_check_table_version: querying version for table subscriber
May 24 17:36:48 osipibDprimary /usr/local/sbin/opensips[13534]:
ERROR:uri:mod_init: Invalid table version.
I first created the MySQL table usinmg the command:
opensipsdbctl create
And then I transfer the tables to MSSQL using the:
Microsoft SQL Server Migration Assistant 8.1 for MySQL
All the table named corrected and all the index was created too.
Thank you very much!
Frank
_______________________________________________
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
_______________________________________________
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users