unixODBC 2.2.14 on CentOS 6.4 Final x86_64

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

unixODBC 2.2.14 on CentOS 6.4 Final x86_64

Nunzio Luigi Puleio
Hello everyone,

I have a webserver with PHP 5.3.3 where it's installed FreeTDS 0.91-2.el6, unixODBC.x86_64 2.2.14-12.el6_3 and at the other side there's a SQL Server 2008. 
This webserver is 

Linux WEBSERVER 2.6.32-358.11.1.el6.x86_64 #1 SMP Wed Jun 12 03:34:52 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
CentOS release 6.4 (Final)

I settled freetds.conf as:

# TDS protocol version
tds version = 8.0

host = X.X.X.X
port = 1433
tds version = 8.0

and odbc.ini as:

Driver  = FreeTDS
Server  = X.X.X.X
Port = 1433
Database = mydb
TDS_Version = 8.0
and in odbcinst.ini as:

Description     = ODBC for SQL Server
Driver          = /usr/lib64/libtdsodbc.so.0
Setup           = /usr/lib64/libtdsS.so.0
UsageCount      = 1
FileUsage       = 1
and in PHP I communicate with db through unixODBC using odbc_connect, odbc_query, odbc_fetch_object/odbc_fetch_array but to get a response of a simple SELECT that would return me just 10 rows from PHP takes like almost 3 seconds 
doing these steps: odbc_connect - odbc_exec of grant user if admin or not - odbc_fetch_object of data - odbc_close - odbc_free_result

Is there a way to trace log clearly to see where it slows during those operations between webpage command call and its return data and to see if there are bottlenecks? 
Maybe to see if it solves issue shall I have to rebuild and reinstall PHP 5.3.3 with parameter --with-odbc=unixODBC or shall I have to rebuild unixODBC with some sort of parameters to increase performance?
Also because on another webserver with same platform and configuration is more performant...

Thanks in advance 

unixODBC-support mailing list
[hidden email]