[ODBC-286] Very Poor Performance on Remote Connection Created: 2020-06-01 Updated: 2023-04-13 |
|
| Status: | Open |
| Project: | MariaDB Connector/ODBC |
| Component/s: | General |
| Affects Version/s: | N/A |
| Fix Version/s: | 3.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Anil Sharma | Assignee: | Lawrin Novitsky |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Environment: |
windows |
||
| Attachments: |
|
||||||||||||||||||||||||
| Issue Links: |
|
||||||||||||||||||||||||
| Description |
|
Maridb odbc is too slow when you connect a remote server. Same server connected with mysql odbc gives very fast response. Please look into the matter as mariadb user want to use maridb odbc. |
| Comments |
| Comment by Lawrin Novitsky [ 2020-06-01 ] |
|
Thank you for your report. |
| Comment by Anil Sharma [ 2020-06-02 ] |
|
Query return is slower so as connection establishment too. in MySQL odbc it took 3-4 seconds and in MariaDB odbc it took 8 to 10 seconds delay in each task. I am testing from INDIA and my Remote server is in GERMANY. I have MSSQL too in same location and it's working fast on odbc too. |
| Comment by Lawrin Novitsky [ 2020-06-02 ] |
|
I would still ask you to provide ODBC trace. It's hard to imagine that could cause such a performance difference on any query return. Where must be something more than sending query and receiving results, that VIsual Foxpro does. |
| Comment by Lawrin Novitsky [ 2020-06-02 ] |
|
Actually, it's better to provide ODBC trace right from the connections establishing. It's again possible, that Foxpro does something under cover after that. Like reading some metadata or something else. |
| Comment by Anil Sharma [ 2020-06-02 ] |
|
Ok, I will update the ODBC trace. But the same VFP works fine with MySQL ODBC 8.0 |
| Comment by Lawrin Novitsky [ 2020-06-02 ] |
|
I understand that. Something is slower in MariaDB driver. But we don't know what exactly. It can't be everything. And we don't know how exactly VFP uses ODBC without seeing the trace. |
| Comment by Anil Sharma [ 2020-06-03 ] |
|
I have attached odbc log for MariaDB. if you required log for MySQL odbc i can send that too. Regards |
| Comment by Lawrin Novitsky [ 2020-06-03 ] |
|
Thanks for the log. As for mysql log - that may be also useful. It's possible, that depending on info provided by drivers VFP use different approaches for some operations. |
| Comment by Anil Sharma [ 2020-06-03 ] |
|
for MariaDB Connection string is Options=83888160 DRIVER={MariaDB ODBC 3.1 Driver} ;Server=<<SqlServerName>>;Database=<<SqlDataBaseName>>;User=root;Password=<<SqlServerPassword>>;Option=83888160; for MySQL Connection String is options=83904632 DRIVER={MySQL ODBC 8.0 ANSI Driver} ;Server=<<SqlServerName>>;Database=<<SqlDataBaseName>>;User=root;Password=<<SqlServerPassword>>;Option=83904632; Regards |
| Comment by Lawrin Novitsky [ 2020-06-08 ] |
|
Looks like you are using MariadDB server, but I better ask if that is correct assumption? also, what is the version of that server? |
| Comment by Anil Sharma [ 2020-06-09 ] |
|
Correct Mariadb Server. Version 10.3 |
| Comment by Lawrin Novitsky [ 2020-06-09 ] |
|
Would it be also correct to say, that execution of the described by traces takes 3-4s with mysql, and 8-10s with mariadb driver? |
| Comment by Anil Sharma [ 2020-06-10 ] |
|
Yes with MySQL odbc it took 3-4 seconds and with MariaDB Driver, it took 8-10 seconds. here is ping figures. Pinging 79.143.180.23 with 32 bytes of data: Ping statistics for 79.143.180.23: Here is Trace route too Tracing route to controllprocesses.contabo.host [79.143.180.23] 1 1 ms <1 ms <1 ms 192.168.18.1 Trace complete. |
| Comment by Lawrin Novitsky [ 2020-06-15 ] |
|
Could you please try to test the same scenario with turned off compression? You need to deduct 2048 from your OPTIONS value - that bit stands for compression. I wonder if time difference gonna be of the same scale |
| Comment by Anil Sharma [ 2020-06-16 ] |
|
yes, it improved by 20%. now it took 7.40 seconds. which was early approx 9 to 10 seconds. |
| Comment by Lawrin Novitsky [ 2020-06-23 ] |
|
The main theory is that is because of prepared statements in maodbc vs text protocol in myodbc. |
| Comment by Anil Sharma [ 2020-06-24 ] |
|
One more area you need to research when we connect the remote server MariaDB odbc lost the connection within a minute until you have an auto-reconnect option enabled. which is not required in the MySQL odbc case. |
| Comment by Lawrin Novitsky [ 2020-06-24 ] |
|
That is probably they either use either longer wait timeout by default, or set interactive client option by default, that eventually means the same - longer timeout. I am not sure that is a good idea, but we need to add that option. I opened |
| Comment by Lawrin Novitsky [ 2021-05-11 ] |
|
Some of cases described there can affect this issue as well |
| Comment by Lawrin Novitsky [ 2023-04-13 ] |
|
3.2.0 with text protocol support is about to be released. I am tempted to close this ticket, as I suspected binary vs text was slower in this case, but leaving it open to take another look. |