Обсуждение: stable driver for multithreaded environment (IIS 5.X)

Поиск
Список
Период
Сортировка

stable driver for multithreaded environment (IIS 5.X)

От
"Markus Donath"
Дата:
hello,

i've been making load-tests with Microsoft IIS 5.0 on Windows 2000,
accessing postgresql via the Microsoft "OLEDB over ODBC" Driver using
Postgres ODBC 7.03.0200.
MDAC Version is 2.7 SP1 refresh.
This version seems to have stability problems in a multithreading
environment, same problems occur using version 7.03.0100:

1. the first bytes of column-data are corrupted under heavy load on the
webserver machine
2. after some minutes of testing, the webserver starts blocking threads
because of unhandled MDAC errors.
Here is a stack-dump of one of the blocked threads:

Warning: This thread is blocked by a Message Box
Message Box Text: Runtime Error!

Program: C:\WINNT\system32\dllhost.exe

R6025

- pure virtual function call



Thread Type: MDAC Error being handled.  Possible ASP page
Executing Page: R:\INETPUB\XXXX\SHOP\FOLDER.ASP

 # ChildEBP RetAddr
00 0202d99c 77e234d6 USER32!NtUserWaitMessage+0xb
01 0202d9d0 77e33f21 USER32!DialogBox2+0x216
02 0202d9f4 77e23fdd USER32!InternalDialogBox+0xd1
03 0202dcac 77e24379 USER32!SoftModalMessageBox+0x752
04 0202ddf4 77e23871 USER32!MessageBoxWorker+0x247
05 0202de4c 77e24104 USER32!MessageBoxExW+0x77
06 0202de7c 77e232a2 USER32!MessageBoxExA+0xa0
07 0202de9c 7800bec3 USER32!MessageBoxA+0x49
08 0202debc 78007e22 MSVCRT!__crtMessageBoxA+0x81
09 0202e09c 78007f87 MSVCRT!_NMSG_WRITE+0x11f
0a 0202e0a4 7800bc7a MSVCRT!_amsg_exit+0x25
0b 0202e0ac 1f33f360 MSVCRT!_purecall+0x7
0c 0202e0b4 1f334aaf msadce!CSingleResult::~CSingleResult+0x27
0d 0202e0bc 1f35244b msadce!CSingleResult::`scalar deleting destructor'+0x8
0e 0202e0e8 1f352518 msadce!CMultipleResults::mrInitFetch+0xb1
0f 0202e11c 1f43fa41 msadce!CMultipleResults::GetResult+0xbd
10 0202e15c 1f43f72c msado15!CConnection::Execute+0x13f
11 0202e318 1f43f5e6 msado15!_ExecuteAsync+0x16e
12 0202e328 1f43f4f9 msado15!ExecuteAsync+0x1f
13 0202e3f0 1f43ef4d msado15!CQuery::Execute+0x9fe
14 0202e498 1f43a33c msado15!CCommand::_Execute+0x147
15 0202e4d8 1f438174 msado15!CXLockContext::~CXLockContext+0x14
16 0202e638 1f4448f7 msado15!CRecordset::Open+0x571
17 0202e69c 779ffe61 msado15!CRecordset::put_CursorLocation+0x93
18 0a96c800 00650073 OLEAUT32!APP_DATA::FreeCachedMem+0x85
WARNING: Frame IP not in any known module. Following frames may be wrong.
19 000008ec 00000000 0x650073


As with all multithreading issues, the server runs fine when not under
stress.

Is there a stable version of this driver available (maybe an older version)
?
Can anybody recommend a commercial driver version ?

thank you,
Markus.




Re: stable driver for multithreaded environment (IIS 5.X)

От
Дата:
While I am not an ODBC developer, my first inclanation would be to examine
your code for areas where you may be using the same connection resources
across multiple threads.


> hello,
>
> i've been making load-tests with Microsoft IIS 5.0 on Windows 2000,
> accessing postgresql via the Microsoft "OLEDB over ODBC" Driver using
> Postgres ODBC 7.03.0200.
> MDAC Version is 2.7 SP1 refresh.
> This version seems to have stability problems in a multithreading
> environment, same problems occur using version 7.03.0100:
>
> 1. the first bytes of column-data are corrupted under heavy load on the
> webserver machine
> 2. after some minutes of testing, the webserver starts blocking threads
> because of unhandled MDAC errors.
> Here is a stack-dump of one of the blocked threads:
>
> Warning: This thread is blocked by a Message Box
> Message Box Text: Runtime Error!
>
> Program: C:\WINNT\system32\dllhost.exe
>
> R6025
>
> - pure virtual function call
>
>
>
> Thread Type: MDAC Error being handled.  Possible ASP page
> Executing Page: R:\INETPUB\XXXX\SHOP\FOLDER.ASP
>
>  # ChildEBP RetAddr
> 00 0202d99c 77e234d6 USER32!NtUserWaitMessage+0xb
> 01 0202d9d0 77e33f21 USER32!DialogBox2+0x216
> 02 0202d9f4 77e23fdd USER32!InternalDialogBox+0xd1
> 03 0202dcac 77e24379 USER32!SoftModalMessageBox+0x752
> 04 0202ddf4 77e23871 USER32!MessageBoxWorker+0x247
> 05 0202de4c 77e24104 USER32!MessageBoxExW+0x77
> 06 0202de7c 77e232a2 USER32!MessageBoxExA+0xa0
> 07 0202de9c 7800bec3 USER32!MessageBoxA+0x49
> 08 0202debc 78007e22 MSVCRT!__crtMessageBoxA+0x81
> 09 0202e09c 78007f87 MSVCRT!_NMSG_WRITE+0x11f
> 0a 0202e0a4 7800bc7a MSVCRT!_amsg_exit+0x25
> 0b 0202e0ac 1f33f360 MSVCRT!_purecall+0x7
> 0c 0202e0b4 1f334aaf msadce!CSingleResult::~CSingleResult+0x27
> 0d 0202e0bc 1f35244b msadce!CSingleResult::`scalar deleting
> destructor'+0x8 0e 0202e0e8 1f352518
> msadce!CMultipleResults::mrInitFetch+0xb1
> 0f 0202e11c 1f43fa41 msadce!CMultipleResults::GetResult+0xbd
> 10 0202e15c 1f43f72c msado15!CConnection::Execute+0x13f
> 11 0202e318 1f43f5e6 msado15!_ExecuteAsync+0x16e
> 12 0202e328 1f43f4f9 msado15!ExecuteAsync+0x1f
> 13 0202e3f0 1f43ef4d msado15!CQuery::Execute+0x9fe
> 14 0202e498 1f43a33c msado15!CCommand::_Execute+0x147
> 15 0202e4d8 1f438174 msado15!CXLockContext::~CXLockContext+0x14
> 16 0202e638 1f4448f7 msado15!CRecordset::Open+0x571
> 17 0202e69c 779ffe61 msado15!CRecordset::put_CursorLocation+0x93
> 18 0a96c800 00650073 OLEAUT32!APP_DATA::FreeCachedMem+0x85
> WARNING: Frame IP not in any known module. Following frames may be
> wrong. 19 000008ec 00000000 0x650073
>
>
> As with all multithreading issues, the server runs fine when not under
> stress.
>
> Is there a stable version of this driver available (maybe an older
> version) ?
> Can anybody recommend a commercial driver version ?
>
> thank you,
> Markus.
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend




Re: stable driver for multithreaded environment (IIS 5.X)

От
"Markus Donath"
Дата:
Hello,

thank you for your reply.
The application ran fine with ORACLE, accessed over OLEDB.
I do not share connections over multiple threads. The Application uses the
Windows ODBC connection pooling. For that, connections are always closed
immediately after a statement was done, so that these connections are always
available for connection pooling when they are not in use. Connection
pooling is the standard way when using IIS with ADO for data access, and it
works fine e.g. for ORACLE and MS SQL Server. One connection is always used
by just one thread (i think it would not work in any other way ?!)

Did anyone here use OLEDB over ODBC in a similar environment ?
Which driver was used in that case ?

thank you,
Markus.






<markw@mohawksoft.com> schrieb im Newsbeitrag
news:39049.24.60.194.163.1069423072.squirrel@mail.mohawksoft.com...
> While I am not an ODBC developer, my first inclanation would be to examine
> your code for areas where you may be using the same connection resources
> across multiple threads.
>
>
> > hello,
> >
> > i've been making load-tests with Microsoft IIS 5.0 on Windows 2000,
> > accessing postgresql via the Microsoft "OLEDB over ODBC" Driver using
> > Postgres ODBC 7.03.0200.
> > MDAC Version is 2.7 SP1 refresh.
> > This version seems to have stability problems in a multithreading
> > environment, same problems occur using version 7.03.0100:
> >
> > 1. the first bytes of column-data are corrupted under heavy load on the
> > webserver machine
> > 2. after some minutes of testing, the webserver starts blocking threads
> > because of unhandled MDAC errors.
> > Here is a stack-dump of one of the blocked threads:
> >
> > Warning: This thread is blocked by a Message Box
> > Message Box Text: Runtime Error!
> >
> > Program: C:\WINNT\system32\dllhost.exe
> >
> > R6025
> >
> > - pure virtual function call
> >
> >
> >
> > Thread Type: MDAC Error being handled.  Possible ASP page
> > Executing Page: R:\INETPUB\XXXX\SHOP\FOLDER.ASP
> >
> >  # ChildEBP RetAddr
> > 00 0202d99c 77e234d6 USER32!NtUserWaitMessage+0xb
> > 01 0202d9d0 77e33f21 USER32!DialogBox2+0x216
> > 02 0202d9f4 77e23fdd USER32!InternalDialogBox+0xd1
> > 03 0202dcac 77e24379 USER32!SoftModalMessageBox+0x752
> > 04 0202ddf4 77e23871 USER32!MessageBoxWorker+0x247
> > 05 0202de4c 77e24104 USER32!MessageBoxExW+0x77
> > 06 0202de7c 77e232a2 USER32!MessageBoxExA+0xa0
> > 07 0202de9c 7800bec3 USER32!MessageBoxA+0x49
> > 08 0202debc 78007e22 MSVCRT!__crtMessageBoxA+0x81
> > 09 0202e09c 78007f87 MSVCRT!_NMSG_WRITE+0x11f
> > 0a 0202e0a4 7800bc7a MSVCRT!_amsg_exit+0x25
> > 0b 0202e0ac 1f33f360 MSVCRT!_purecall+0x7
> > 0c 0202e0b4 1f334aaf msadce!CSingleResult::~CSingleResult+0x27
> > 0d 0202e0bc 1f35244b msadce!CSingleResult::`scalar deleting
> > destructor'+0x8 0e 0202e0e8 1f352518
> > msadce!CMultipleResults::mrInitFetch+0xb1
> > 0f 0202e11c 1f43fa41 msadce!CMultipleResults::GetResult+0xbd
> > 10 0202e15c 1f43f72c msado15!CConnection::Execute+0x13f
> > 11 0202e318 1f43f5e6 msado15!_ExecuteAsync+0x16e
> > 12 0202e328 1f43f4f9 msado15!ExecuteAsync+0x1f
> > 13 0202e3f0 1f43ef4d msado15!CQuery::Execute+0x9fe
> > 14 0202e498 1f43a33c msado15!CCommand::_Execute+0x147
> > 15 0202e4d8 1f438174 msado15!CXLockContext::~CXLockContext+0x14
> > 16 0202e638 1f4448f7 msado15!CRecordset::Open+0x571
> > 17 0202e69c 779ffe61 msado15!CRecordset::put_CursorLocation+0x93
> > 18 0a96c800 00650073 OLEAUT32!APP_DATA::FreeCachedMem+0x85
> > WARNING: Frame IP not in any known module. Following frames may be
> > wrong. 19 000008ec 00000000 0x650073
> >
> >
> > As with all multithreading issues, the server runs fine when not under
> > stress.
> >
> > Is there a stable version of this driver available (maybe an older
> > version) ?
> > Can anybody recommend a commercial driver version ?
> >
> > thank you,
> > Markus.
> >
> >
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 8: explain analyze is your friend
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 9: the planner will ignore your desire to choose an index scan if your
>       joining column's datatypes do not match
>



Re: stable driver for multithreaded environment (IIS 5.X)

От
"Markus Donath"
Дата:
As no developer has answered yet, could anyone related to odbc driver
development answer the following questions:

1. Is there any development going on for the Windows version of the ODBC
driver ?
2. Are there known problems in a multithreaded environment (Webserver on
Windows 2000) and are they adressed ?
3. Is there a stable (maybe older, maybe commercial) version available for
multithreaded environments ?
4. Is anyone interessted in bug reports or am i completely wasting my time
when posting to this newsgroup ?

this would be very important for me.
PLEASE if anyone is working on the driver CONTACT ME.

thank you,
Markus.





"Markus Donath" <md-postgres-donath@netapps.de> schrieb im Newsbeitrag
news:bpl77u$1mii$1@news.hub.org...
> Hello,
>
> thank you for your reply.
> The application ran fine with ORACLE, accessed over OLEDB.
> I do not share connections over multiple threads. The Application uses the
> Windows ODBC connection pooling. For that, connections are always closed
> immediately after a statement was done, so that these connections are
always
> available for connection pooling when they are not in use. Connection
> pooling is the standard way when using IIS with ADO for data access, and
it
> works fine e.g. for ORACLE and MS SQL Server. One connection is always
used
> by just one thread (i think it would not work in any other way ?!)
>
> Did anyone here use OLEDB over ODBC in a similar environment ?
> Which driver was used in that case ?
>
> thank you,
> Markus.
>
>
>
>
>
>
> <markw@mohawksoft.com> schrieb im Newsbeitrag
> news:39049.24.60.194.163.1069423072.squirrel@mail.mohawksoft.com...
> > While I am not an ODBC developer, my first inclanation would be to
examine
> > your code for areas where you may be using the same connection resources
> > across multiple threads.
> >
> >
> > > hello,
> > >
> > > i've been making load-tests with Microsoft IIS 5.0 on Windows 2000,
> > > accessing postgresql via the Microsoft "OLEDB over ODBC" Driver using
> > > Postgres ODBC 7.03.0200.
> > > MDAC Version is 2.7 SP1 refresh.
> > > This version seems to have stability problems in a multithreading
> > > environment, same problems occur using version 7.03.0100:
> > >
> > > 1. the first bytes of column-data are corrupted under heavy load on
the
> > > webserver machine
> > > 2. after some minutes of testing, the webserver starts blocking
threads
> > > because of unhandled MDAC errors.
> > > Here is a stack-dump of one of the blocked threads:
> > >
> > > Warning: This thread is blocked by a Message Box
> > > Message Box Text: Runtime Error!
> > >
> > > Program: C:\WINNT\system32\dllhost.exe
> > >
> > > R6025
> > >
> > > - pure virtual function call
> > >
> > >
> > >
> > > Thread Type: MDAC Error being handled.  Possible ASP page
> > > Executing Page: R:\INETPUB\XXXX\SHOP\FOLDER.ASP
> > >
> > >  # ChildEBP RetAddr
> > > 00 0202d99c 77e234d6 USER32!NtUserWaitMessage+0xb
> > > 01 0202d9d0 77e33f21 USER32!DialogBox2+0x216
> > > 02 0202d9f4 77e23fdd USER32!InternalDialogBox+0xd1
> > > 03 0202dcac 77e24379 USER32!SoftModalMessageBox+0x752
> > > 04 0202ddf4 77e23871 USER32!MessageBoxWorker+0x247
> > > 05 0202de4c 77e24104 USER32!MessageBoxExW+0x77
> > > 06 0202de7c 77e232a2 USER32!MessageBoxExA+0xa0
> > > 07 0202de9c 7800bec3 USER32!MessageBoxA+0x49
> > > 08 0202debc 78007e22 MSVCRT!__crtMessageBoxA+0x81
> > > 09 0202e09c 78007f87 MSVCRT!_NMSG_WRITE+0x11f
> > > 0a 0202e0a4 7800bc7a MSVCRT!_amsg_exit+0x25
> > > 0b 0202e0ac 1f33f360 MSVCRT!_purecall+0x7
> > > 0c 0202e0b4 1f334aaf msadce!CSingleResult::~CSingleResult+0x27
> > > 0d 0202e0bc 1f35244b msadce!CSingleResult::`scalar deleting
> > > destructor'+0x8 0e 0202e0e8 1f352518
> > > msadce!CMultipleResults::mrInitFetch+0xb1
> > > 0f 0202e11c 1f43fa41 msadce!CMultipleResults::GetResult+0xbd
> > > 10 0202e15c 1f43f72c msado15!CConnection::Execute+0x13f
> > > 11 0202e318 1f43f5e6 msado15!_ExecuteAsync+0x16e
> > > 12 0202e328 1f43f4f9 msado15!ExecuteAsync+0x1f
> > > 13 0202e3f0 1f43ef4d msado15!CQuery::Execute+0x9fe
> > > 14 0202e498 1f43a33c msado15!CCommand::_Execute+0x147
> > > 15 0202e4d8 1f438174 msado15!CXLockContext::~CXLockContext+0x14
> > > 16 0202e638 1f4448f7 msado15!CRecordset::Open+0x571
> > > 17 0202e69c 779ffe61 msado15!CRecordset::put_CursorLocation+0x93
> > > 18 0a96c800 00650073 OLEAUT32!APP_DATA::FreeCachedMem+0x85
> > > WARNING: Frame IP not in any known module. Following frames may be
> > > wrong. 19 000008ec 00000000 0x650073
> > >
> > >
> > > As with all multithreading issues, the server runs fine when not under
> > > stress.
> > >
> > > Is there a stable version of this driver available (maybe an older
> > > version) ?
> > > Can anybody recommend a commercial driver version ?
> > >
> > > thank you,
> > > Markus.
> > >
> > >
> > >
> > >
> > > ---------------------------(end of
broadcast)---------------------------
> > > TIP 8: explain analyze is your friend
> >
> >
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 9: the planner will ignore your desire to choose an index scan if
your
> >       joining column's datatypes do not match
> >
>
>



Re: stable driver for multithreaded environment (IIS 5.X)

От
"Hiroshi Inoue"
Дата:
> -----Original Message-----
> From: Markus Donath
>
> As no developer has answered yet, could anyone related to odbc driver
> development answer the following questions:
>
> 1. Is there any development going on for the Windows version
> of the ODBC
> driver ?
> 2. Are there known problems in a multithreaded environment
> (Webserver on
> Windows 2000) and are they adressed ?

Could you try the dll at http://www.geocities.jp/inocchichichi/ ?
It would fix a multithread related bug though I'm not sure if it would
solve your problem.

regards,
Hiroshi Inoue

> 3. Is there a stable (maybe older, maybe commercial) version
> available for
> multithreaded environments ?
> 4. Is anyone interessted in bug reports or am i completely
> wasting my time
> when posting to this newsgroup ?
>
> this would be very important for me.
> PLEASE if anyone is working on the driver CONTACT ME.


Re: stable driver for multithreaded environment (IIS 5.X)

От
"Markus Donath"
Дата:
Hello,

thank you for the new version (07.03.0205).
i've tested the version for a few days now with the following results:

1. The "corrupted data under stress" problem (up to 07.03.0204) is fixed
2. Threads are no longer blocked by the "pure virtual function call" error
message box

But the 07.03.0205-Version introduces new bugs:

1. When using updateable recordsets in a database call (no matter if allowed
in the dsn-settings or not), the odbc-driver becomes unusable after a few
statements, and
error-statements ("unknown error") are returned by the database driver.
2. We use components to cache some data. When i call these components in the
following manner:
comp1.init(connectionstring)
comp2.init(connectionstring)
the second call fails with the new driver. When i vary the connection-string
a bit for the second
call (e.g. by adding something like ";foo=222") , everything works fine.
This lets me think that there might be a problem with connection pooling.
Even when connection pooling and updateable cursors are disabled (by
DSN-Settings), these errors occur.

Note: these components do not share any database related resources.
For every call made in the entire application a seperate connection is
opened, a call is beeing made and the connection is closed as soon as
possible (this is how to make connection pooling work with windows).

All in all, this Version is even less stable then 07.03.0204 although some
problems were fixed.


@Hiroshi Inoue:    Are you interested in the odbc-driver-logs ?


bye,
Markus.


""Hiroshi Inoue"" <inoue@tpf.co.jp> schrieb im Newsbeitrag
news:000001c3be62$5ea57500$3d283ddb@PbgX...
> > -----Original Message-----
> > From: Markus Donath
> >
> > As no developer has answered yet, could anyone related to odbc driver
> > development answer the following questions:
> >
> > 1. Is there any development going on for the Windows version
> > of the ODBC
> > driver ?
> > 2. Are there known problems in a multithreaded environment
> > (Webserver on
> > Windows 2000) and are they adressed ?
>
> Could you try the dll at http://www.geocities.jp/inocchichichi/ ?
> It would fix a multithread related bug though I'm not sure if it would
> solve your problem.
>
> regards,
> Hiroshi Inoue
>
> > 3. Is there a stable (maybe older, maybe commercial) version
> > available for
> > multithreaded environments ?
> > 4. Is anyone interessted in bug reports or am i completely
> > wasting my time
> > when posting to this newsgroup ?
> >
> > this would be very important for me.
> > PLEASE if anyone is working on the driver CONTACT ME.
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 7: don't forget to increase your free space map settings
>



Re: stable driver for multithreaded environment (IIS 5.X)

От
Hiroshi Inoue
Дата:
Markus Donath wrote:
>
> Hello,
>
> thank you for the new version (07.03.0205).
> i've tested the version for a few days now with the following results:
>
> 1. The "corrupted data under stress" problem (up to 07.03.0204) is fixed
> 2. Threads are no longer blocked by the "pure virtual function call" error
> message box
>
> But the 07.03.0205-Version introduces new bugs:
>
> 1. When using updateable recordsets in a database call (no matter if allowed
> in the dsn-settings or not), the odbc-driver becomes unusable after a few
> statements, and
> error-statements ("unknown error") are returned by the database driver.
> 2. We use components to cache some data. When i call these components in the
> following manner:
> comp1.init(connectionstring)
> comp2.init(connectionstring)
> the second call fails with the new driver. When i vary the connection-string
> a bit for the second
> call (e.g. by adding something like ";foo=222") , everything works fine.
> This lets me think that there might be a problem with connection pooling.
> Even when connection pooling and updateable cursors are disabled (by
> DSN-Settings), these errors occur.
>
> Note: these components do not share any database related resources.
> For every call made in the entire application a seperate connection is
> opened, a call is beeing made and the connection is closed as soon as
> possible (this is how to make connection pooling work with windows).
>
> All in all, this Version is even less stable then 07.03.0204 although some
> problems were fixed.
>
> @Hiroshi Inoue:    Are you interested in the odbc-driver-logs ?

Yes. Please send me the logs.

regards,
Hiroshi Inoue

Bug correction

От
"George A.J"
Дата:

hi all,

i am using postgresql 7.3.2 with ODBC 7.3.1

i have fixed a bug in the ODBC driver. ie the bug when numeric input 0.009 is given it reached database as .9 . how can i add this fix to the source. the bug is still in the latest ODBC.

pls inform about how can i send this fix..

regards

jinujose 


Do you Yahoo!?
New Yahoo! Photos - easier uploading and sharing

Re: Bug correction

От
"Hiroshi Inoue"
Дата:
Please post your patch(diff -c style) to pgsql-odbc ML.

regards,,
Hiroshi Inoue

> ""George A.J"" <jinujosein@yahoo.com> wrote in message
news:20031216024053.4324.qmail@web14906.mail.yahoo.com...
> hi all,
> i am using postgresql 7.3.2 with ODBC 7.3.1
> i have fixed a bug in the ODBC driver. ie the bug when numeric input 0.009
is given it reached database as .9 .
> how can i add this fix to the source. the bug is still in the latest ODBC.
> pls inform about how can i send this fix..