-
Notifications
You must be signed in to change notification settings - Fork 26
SEGV Bug Fix Cand v1.91 #187
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- SEGV's happen during the call to OCISessionEnd()
(based on my usecase)
o WHEN there are three or more threads
o Connected to the same DB user at the same time
o When the last thread makes the call to OCISessionEnd() the SEGV
is created.
- I have discovered 05/05(today) that the SEGV can be iliminated (avoided)
o WHEN the last thread to connect is the first to OCISessionEnd()
o I'm going to write another smaller Perl script to reproduce
the SEV and its avoidance.
- messages have been released to seek a new life by going into the "LIGHT"
Noted that t/15threads.t randomly SEGV's This happens a lot. t/16cached.t .............. Can't call method "prepare" on an undefined value at .../t/cache2.pl line 21. I figure others are seeing these same issues as I am. t/rt74753-utf8-encoded.t .. 1/3 Issuing rollback() due to DESTROY without explicit disconnect() of DBD::Oracle::db handle ORA19C at t/rt74753-utf8-encoded.t line 86. t/rt74753-utf8-encoded.t .. ok t/rt85886.t ............... 1/2 SV = PV(0x5aa9e32f1c60) at 0x5aa9e349c358 REFCNT = 1 FLAGS = (POK,pPOK) PV = 0x5aa9e34b4590 "1"\0 CUR = 1 LEN = 16 t/rt85886.t ............... Dubious, test returned 1 (wstat 256, 0x100) Failed 1/2 subtests Test Summary Report ------------------- t/16cached.t (Wstat: 256 (exited 1) Tests: 1 Failed: 1) Failed test: 1 Non-zero exit status: 1 t/90-segv.t (Wstat: 139 (Signal: SEGV, dumped core) Tests: 37 Failed: 0) Non-zero wait status: 139 Parse errors: No plan found in TAP output t/rt85886.t (Wstat: 256 (exited 1) Tests: 2 Failed: 1) Failed test: 2 Non-zero exit status: 1 Files=44, Tests=1492, 237 wallclock secs ( 0.22 usr 0.19 sys + 3.70 cusr 2.10 csys = 6.21 CPU) Result: FAIL Failed 3/44 test programs. 2/1492 subtests failed. make: *** [Makefile:1114: test_dynamic] Error 1
…mory leak. I've left this better than I found it. But not as clean as I would like. This isn't mine to own or make such decisions. But ... Parhaps it's time to abandon all that old Oracle Support. (Some how I doubt it's been tested in a long time!) Require perl-5.30.3+ & Oracle 17+. Clean up and simplify. Call it 2.0! The existing threads test no longer SEGV's and the test I added also passes. There are a couple of preexisting test fails I'll leave to the maintainers. - God Speed! t/rt85886.t ............... 1/2 SV = PV(0x6479e78dba50) at 0x6479e797ea60 REFCNT = 1 FLAGS = (POK,pPOK) PV = 0x6479e7a88350 "1"\0 CUR = 1 LEN = 16 t/rt85886.t ............... Dubious, test returned 1 (wstat 256, 0x100) Failed 1/2 subtests Test Summary Report ------------------- t/16cached.t (Wstat: 256 (exited 1) Tests: 1 Failed: 1) Failed test: 1 Non-zero exit status: 1 t/rt85886.t (Wstat: 256 (exited 1) Tests: 2 Failed: 1) Failed test: 2 Non-zero exit status: 1 Files=44, Tests=1488, 19 wallclock secs ( 0.25 usr 0.10 sys + 4.15 cusr 1.68 csys = 6.18 CPU) Result: FAIL Failed 2/44 test programs. 2/1488 subtests failed. make: *** [Makefile:1114: test_dynamic] Error 1
dbdcnx.c
Outdated
| // I believe this list, being static, was intented to be shared by all threads! | ||
| // Additional comments in the code suggest this as well. | ||
| // However as it was written every thread was nuking the setup of the last | ||
| // startng with a fresh empty list. Smells like a memoty leak at best |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably s/startng/starting/.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:) I'm the typo king so there is that. I think there are at least two in this text
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixing typos is good. Although ideally they are in their own patch/diff so keep them discrete. Anyway no problems
to make tests consistent in the opertion. Spruced up tests to eliminate noise from the "ok's"
OCISessionEnd_log_stat() OCIServerDetach_log_stat()
a balance between detecton, reporting and making the issue worse.
|
Im going to merge it although it looks like the tests need some tweaking to ensure that tests for threaded perl are only run when perl is compiled for threading. |
I found "a" bug that was the primary reason for the SEGV.
Most of the change was formatting to help with reading. Formatting is kind of all-over the place.
The bug was in dbdcnx.c