[ODBC-349] speed issues and IIS crashing Created: 2022-01-19  Updated: 2022-01-21

Status: Open
Project: MariaDB Connector/ODBC
Component/s: General
Affects Version/s: 3.1.15
Fix Version/s: None

Type: Bug Priority: Major
Reporter: Nathaniel Courtens Assignee: Lawrin Novitsky
Resolution: Unresolved Votes: 0
Labels: Compatibility, crash, performance
Environment:

Windows 10 Pro with MariaDB 10.6, Apache 2.4 (Apache is mostly used as proxy), IIS 10, PHP 8.1, Code on IIS is ASP Classic (VBS). Hosted by VritualBox, dedicate 6 Cores and 5029 MB of memory.


Attachments: PNG File DJm574ItegPhH6a2.png     PNG File FfNs3d1BAmOuAvi7.png     PNG File H30sqx9ot2g60InP.png    

 Description   

I have been struggling finding the right ODBC driver after this server meltdown. I ended up upgraded from MariaDB 10.1 to MariaDB 10.6.

Before the upgrade IIS was fast and reliable. I used to connect ASP to MariaDB 10.1 in two ways: MySQL ODBC 5.1 Driver, and MariaDB ODBC 3.0 Driver. Connection string was:

{{"PROVIDER=MSDASQL;DRIVER=

{MySQL ODBC 5.1 Driver}

;port=3306;SERVER=localhost;UID=;PWD=;database=_;Option=3"}}

{{"PROVIDER=MSDASQL;DRIVER=

{MariaDB ODBC 3.0 Driver}

;port=3306;SERVER=localhost;UID=;PWD=;database=_;"}}


Now on MariaDB 10.6 I have tried myodbc8w.dll MySQL ODBC 8.00.27.00 Unicode Driver which is fast but it crashes IIS after 1 or 2 days (not just the Application Pool but IIS!)

I also tried maodbc.dll MariaDB ODBC 3.1.15 but it is slow (it takes 4x longer) and it crashes the IIS Application Pool every 2 to 3 hours in.

Link to my related post

I am getting errors such as:
MariaDB EventID 100: Aborted connection _ to db: '' user: '' host: 'localhost' (Got an error reading communication packets)



 Comments   
Comment by Lawrin Novitsky [ 2022-01-20 ]

Thank you for the report.
Is this error is what causes Application Pool to crash, or is it something that you get along the crashes?

We need something, that could help us to find what causes the crashes.

The first step naturally is to get ODBC trace. In past it was a problem - IIS did not let the driver manager write to it. Not sure if that is changed, but worth of trying.

2nd option is if you could provide us with (minimal) standalone script/DB infrastructure, so we could repeat your problem locally.

If that is not possible, then the next option is create special driver version, that would somehow provide us with some debug information. If ODBC trace(from step1) is impossible to get, than that means, that we can't write (the debug info) to the file, thus we will need to figure out what to do.

Comment by Nathaniel Courtens [ 2022-01-20 ]

Hello David, and hello Lawrin,

Lawrin, David from Microsoft Support has been helping me with this issue: TrackingID#2201060060003079

I attached my last email I sent to him to bring you up to speed.

I have been collecting debug diagnostic dumps and uploading them ([1]link to upload location) for him to analyze. This is his contact:

David Dietz
Senior Support Escalation Engineer
Developer Web Apps  
Office: +1 (980) 776-7170
Working hours: Monday - Thursday 10am-9pm Eastern

David, Lawrin from mariadb.org is asking in her email below "Is this error what causes Application Pool to crash, or is it something that you get along the crashes?" I am not sure how to answer that.

The only thing I know is that IIS stops responding to requests, and that my logs look like this when IIS stops responding:

I forgot to mention that I temporarily set IIS to recycle every 25 minutes, in the hopes that IIS stays up longer:

Please find in bold my response between Lawrin's lines below.
Thank you,
Nathaniel Courtens
805 640-8883

-------- Forwarded Message --------

Subject: [JIRA] (ODBC-349) speed issues and IIS crashing
Date: Thu, 20 Jan 2022 11:16:00 +0000 (UTC)
From: Lawrin Novitsky (Jira) [2]<jira@mariadb.org>
To: [3]courtens@poweryourpoint.com

[ [4]https://jira.mariadb.org/browse/ODBC-349?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=211487#comment-211487 ]
Lawrin Novitsky commented on ODBC-349:
--------------------------------------

Thank you for the report.
Is this error is what causes Application Pool to crash, or is it something that you get along the crashes?

We need something, that could help us to find what causes the crashes.

The first step naturally is to get ODBC trace. In past it was a problem - IIS did not let the driver manager write to it. Not sure if that is changed, but worth of trying.
N:   I suppose I could activate ODBC tracing. Should I start collecting these when IIS is not responding, or all the time? It could quickly produce a crazy amount of very sensitive data.

Also, would I need to be using defined System DSN for the tracing tool to work?

2nd option is if you could provide us with (minimal) standalone script/DB infrastructure, so we could repeat your problem locally.N:  This is a bit more complicated.
If that is not possible, then the next option is create special driver version, that would somehow provide us with some debug information. If ODBC trace(from step1) is impossible to get, than that means, that we can't write (the debug info) to the file, thus we will need to figure out what to do.

speed issues and IIS crashing
-----------------------------

Key: ODBC-349
URL: [5]https://jira.mariadb.org/browse/ODBC-349
Project: MariaDB Connector/ODBC
Issue Type: Bug
Components: General
Affects Versions: 3.1.15
Environment: Windows 10 Pro with MariaDB 10.6, Apache 2.4 (Apache is mostly used as proxy), IIS 10, PHP 8.1, Code on IIS is ASP Classic (VBS). Hosted by VritualBox, dedicate 6 Cores and 5029 MB of memory. Reporter: Nathaniel Courtens
Assignee: Lawrin Novitsky
Priority: Major
Labels: Compatibility, crash, performance

I have been struggling finding the right ODBC driver after this server meltdown. I ended up upgraded from MariaDB 10.1 to MariaDB 10.6. Before the upgrade IIS was fast and reliable. I used to connect ASP to MariaDB 10.1 in two ways: MySQL ODBC 5.1 Driver, and MariaDB ODBC 3.0 Driver. Connection string was:
{{"PROVIDER=MSDASQL;DRIVER=

{MySQL ODBC 5.1 Driver}

;port=3306;SERVER=localhost;UID=;PWD=;database=_;Option=3"}}
{{"PROVIDER=MSDASQL;DRIVER=

{MariaDB ODBC 3.0 Driver}

;port=3306;SERVER=localhost;UID=;PWD=;database=_;"}}

Now on MariaDB 10.6 I have tried myodbc8w.dll MySQL ODBC 8.00.27.00 Unicode Driver which is fast but it crashes IIS after 1 or 2 days (not just the Application Pool but IIS!) I also tried maodbc.dll MariaDB ODBC 3.1.15 but it is slow (it takes 4x longer) and it crashes the IIS Application Pool every 2 to 3 hours in.
Link to my [related post|[6]http://mariadb.com/kb/en/asp-c0000005-errors-with-mariadb-connectorodbc-3115-64bit/]
I am getting errors such as:
MariaDB EventID 100: Aborted connection _ to db: '' user: '' host: 'localhost' (Got an error reading communication packets)


This message was sent by Atlassian Jira
(v8.13.13#813013)

----------------------------------------------------------------------------------------
[1] https://support.microsoft.com
[2] jira@mariadb.org
[3] courtens@poweryourpoint.com
[4] https://jira.mariadb.org/browse/ODBC-349?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=211487#comment-211487
[5] https://jira.mariadb.org/browse/ODBC-349
[6] http://mariadb.com/kb/en/asp-c0000005-errors-with-mariadb-connectorodbc-3115-64bit/

Comment by Lawrin Novitsky [ 2022-01-20 ]

Yes, it will be crazy amount of data, if it works. It logs all ODBC calls, that come go thru the Driver Manager, and can't be DSN specific to my knowledge. When IIS is not responding - that is too late for tracing activation.
If it works - and I am not sure that it will, I will need only part of it - where the error occurs, and maybe some preceding sequence of ODBC calls leading to the error. It will be fine, if you you remove sensitive data from there.

Comment by Nathaniel Courtens [ 2022-01-21 ]

Somehow I can't get tracing to work. No log file is created. Also, if turned ON it produces wrong connections, accessing the wrong database and with that producing ASP errors. I will upload these dumps.

Comment by Lawrin Novitsky [ 2022-01-21 ]

That's what I expected. IIS used to prevent asp scripts from any kind of writing to the disk. That's probably still a thing.
But just in case - we need the tracing on the server, where IIS and asp scripts run.

Comment by Nathaniel Courtens [ 2022-01-21 ]

I used regedit and changed HKEY_LOCAL_MACHINE\Software\ODBC\ODBC.ini\ODBC Trace flag to 1. I am now getting tracing in C:\SQL.LOG but it brings IIS down with Script timed out. (IIS Connection time-out is set to 120 sec. ASP script time-out is at 1:30.)

I collected  close to 0.5GB in less then 1 minute. I have 40GB of free space on C. It would fill it up in 80 minutes. Screenshot of activity when stopping tracing:

Is there another way to connect to the DB with ASP Classic? Apache and PHP just works – but these ODBC driver are just crashing.

On 1/21/2022 12:46 AM, Lawrin Novitsky (Jira) wrote:

[ [1]https://jira.mariadb.org/browse/ODBC-349?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=211633#comment-211633 ]

Lawrin Novitsky commented on ODBC-349:
--------------------------------------

That's what I expected. IIS used to prevent asp scripts from any kind of writing to the disk. That's probably still a thing.
But just in case - we need the tracing on the server, where IIS and asp scripts run.

speed issues and IIS crashing
-----------------------------

Key: ODBC-349
URL: [2]https://jira.mariadb.org/browse/ODBC-349
Project: MariaDB Connector/ODBC
Issue Type: Bug
Components: General
Affects Versions: 3.1.15
Environment: Windows 10 Pro with MariaDB 10.6, Apache 2.4 (Apache is mostly used as proxy), IIS 10, PHP 8.1, Code on IIS is ASP Classic (VBS). Hosted by VritualBox, dedicate 6 Cores and 5029 MB of memory.
Reporter: Nathaniel Courtens
Assignee: Lawrin Novitsky
Priority: Major
Labels: Compatibility, crash, performance
Attachments: DJm574ItegPhH6a2.png, H30sqx9ot2g60InP.png

I have been struggling finding the right ODBC driver after this server meltdown. I ended up upgraded from MariaDB 10.1 to MariaDB 10.6.
Before the upgrade IIS was fast and reliable. I used to connect ASP to MariaDB 10.1 in two ways: MySQL ODBC 5.1 Driver, and MariaDB ODBC 3.0 Driver. Connection string was:
{{"PROVIDER=MSDASQL;DRIVER=

{MySQL ODBC 5.1 Driver}

;port=3306;SERVER=localhost;UID=;PWD=;database=_;Option=3"}}
{{"PROVIDER=MSDASQL;DRIVER=

{MariaDB ODBC 3.0 Driver}

;port=3306;SERVER=localhost;UID=;PWD=;database=_;"}}

Now on MariaDB 10.6 I have tried myodbc8w.dll MySQL ODBC 8.00.27.00 Unicode Driver which is fast but it crashes IIS after 1 or 2 days (not just the Application Pool but IIS!)
I also tried maodbc.dll MariaDB ODBC 3.1.15 but it is slow (it takes 4x longer) and it crashes the IIS Application Pool every 2 to 3 hours in.
Link to my [related post|[3]http://mariadb.com/kb/en/asp-c0000005-errors-with-mariadb-connectorodbc-3115-64bit/]
I am getting errors such as:
MariaDB EventID 100: Aborted connection _ to db: '' user: '' host: 'localhost' (Got an error reading communication packets)


This message was sent by Atlassian Jira
(v8.13.13#813013)
----------------------------------------------------------------------------------------
[1] https://jira.mariadb.org/browse/ODBC-349?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=211633#comment-211633
[2] https://jira.mariadb.org/browse/ODBC-349
[3] http://mariadb.com/kb/en/asp-c0000005-errors-with-mariadb-connectorodbc-3115-64bit/

Generated at Thu Feb 08 03:28:03 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.