联系:手机/微信(+86 17813235971) QQ(107644445)
作者:惜分飞©版权所有[未经本人同意,不得以任何形式转载,否则有进一步追究法律责任的权利.]
SQL执行报ORA-03113错误
SQL> SELECT * FROM USER.TABLE_NAME t WHERE t.YEAR = '2019' AND t.UPPCODE = '51010000' AND t.MONTH = '01'; 2 3 4 5 SELECT * * ERROR at line 1: ORA-03113: end-of-file on communication channel Process ID: 68389 Session ID: 2419 Serial number: 34370
数据库版本等信息
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options ORACLE_HOME = /oracle/product/db12cr1 System name: Linux Node name: Tkfcsdb Release: 2.6.32-431.el6.x86_64 Version: #1 SMP Sun Nov 10 22:19:54 EST 2013 Machine: x86_64
alert日志报错
Thu Sep 27 17:41:15 2018 Exception [type: SIGSEGV, Address not mapped to object] [ADDR:0x4] [PC:0xCDFB0C6, qcdlgcd()+70] [flags: 0x0, count: 1] Errors in file /oracle/diag/rdbms/tst12uf/tst12uf/trace/tst12uf_ora_234433.trc (incident=126129) (PDBNAME=PTST12UF): ORA-07445:exception encountered:core dump[qcdlgcd()+70][SIGSEGV][ADDR:0x4][PC:0xCDFB0C6][Address not mapped to object][] Incident details in: /oracle/diag/rdbms/tst12uf/tst12uf/incident/incdir_126129/tst12uf_ora_234433_i126129.trc Use ADRCI or Support Workbench to package the incident.
trace文件
----- Beginning of Customized Incident Dump(s) ----- Dumping swap information Memory (Avail / Total) = 948.73M / 63736.63M Swap (Avail / Total) = 30025.52M / 32255.99M Exception [type: SIGSEGV, Address not mapped to object] [ADDR:0x4] [PC:0xCDFB0C6, qcdlgcd()+70] [flags: 0x0, count: 1] Registers: %rax: 0x0000000000000000 %rbx: 0x000000020c3da3f0 %rcx: 0x00007fc492268a40 %rdx: 0x00007fc49239eab0 %rdi: 0x000000022cd5da20 %rsi: 0x00007fc492f2bc80 %rsp: 0x00007fffbd9c9430 %rbp: 0x00007fffbd9c94a0 %r8: 0x00000002372efcb8 %r9: 0x000000022cd5da20 %r10: 0x00007fc49239eab0 %r11: 0x00007fc492268a40 %r12: 0x000000022cd5da20 %r13: 0x00007fc492f2bc80 %r14: 0x00007fc49239eab0 %r15: 0x00007fc492268a40 %rip: 0x000000000cdfb0c6 %efl: 0x0000000000010206 qcdlgcd()+53 (0xcdfb0b5) mov %rdi,%r12 qcdlgcd()+56 (0xcdfb0b8) mov 0x10(%rax),%rbx qcdlgcd()+60 (0xcdfb0bc) jz 0xcdfb29e qcdlgcd()+66 (0xcdfb0c2) mov 0x60(%r15),%rax > qcdlgcd()+70 (0xcdfb0c6) movzwl 0x4(%rax),%r8d qcdlgcd()+75 (0xcdfb0cb) cmp $30,%r8d qcdlgcd()+79 (0xcdfb0cf) jnle 0xcdfb277 qcdlgcd()+85 (0xcdfb0d5) pxor %xmm0,%xmm0 qcdlgcd()+89 (0xcdfb0d9) movaps %xmm0,-0x40(%rbp) *** 2018-09-27 17:41:15.110 dbkedDefDump(): Starting a non-incident diagnostic dump (flags=0x3, level=3, mask=0x0) [TOC00004] ----- Current SQL Statement for this session (sql_id=52chysuyh36t4) ----- SELECT /* DS_SVC */ /*+ dynamic_sampling(0) no_sql_tune no_monitoring optimizer_features_enable(default) no_parallel result_cache(snapshot=3600) */ SUM(C1) FROM (SELECT /*+ qb_name("innerQuery") NO_INDEX_FFS( "T") */ 1 AS C1 FROM "USER"."TABLE_NAME" "T" WHERE ("T"."MONTH"='01') AND ("T"."UPPCODE"='51010000') AND ("T"."YEAR"='2019')) innerQuery [TOC00004-END] [TOC00005] ----- Call Stack Trace ----- calling call entry argument values in hex location type point (? means dubious value) -------------------- -------- -------------------- ---------------------------- skdstdst()+45 call kgdsdst() 7FC492BAB678 000000003 7FC492B8D0B0 ? 7FC492B8D1C8 ? 7FC492BAAEA8 ? 000000083 ? ksedst()+119 call skdstdst() 7FC492BAB678 000000001 000000001 7FC492B8D1C8 ? 7FC492BAAEA8 ? 000000083 ? dbkedDefDump()+1119 call ksedst() 000000001 000000001 ? 000000001 ? 7FC492B8D1C8 ? 7FC492BAAEA8 ? 000000083 ? ksedmp()+261 call dbkedDefDump() 000000003 000000003 000000001 ? 7FC492B8D1C8 ? 7FC492BAAEA8 ? 000000083 ? ssexhd()+2650 call ksedmp() 00000044F 000000003 ? 000000001 ? 000000003 7FC492BAAEA8 ? 000000083 ? sslsshandler()+456 call ssexhd() 202F206C69617641 3D20296C61746F54 4D33372E38343920 3633373336202F20 6177530A4D33362E 000000083 ? __sighandler() call sslsshandler() 000002000 000000000 000000000 3633373336202F20 ? 6177530A4D33362E ? 000000083 ? qcdlgcd()+70 signal __sighandler() 22CD5DA20 7FC492F2BC80 7FC49239EAB0 7FC492268A40 ? 2372EFCB8 ? 22CD5DA20 ? kkdlgcd()+118 call qcdlgcd() 22CD5DA20 ? 7FC492F2BC80 ? 7FC49239EAB0 ? 7FC492268A40 ? 2372EFCB8 ? 22CD5DA20 ? kkmfbtic()+17 call kkdlgcd() 7FC49239EAB0 ? 7FC492268A40 ? 7FC49239EAB0 ? 7FC492268A40 ? 2372EFCB8 ? 22CD5DA20 ? qcsgcic()+163 call kkmfbtic() 7FC49239EAB0 ? 7FC492268A40 ? 7FC49239EAB0 ? 7FC492268A40 ? 2372EFCB8 ? 22CD5DA20 ? kkmgkc()+147 call qcsgcic() 22CD5DA20 ? 7FC492F2BC80 ? 7FC49239EAB0 ? 7FC492268A40 ? 000000007 22CD5DA20 ? kokscit()+65 call kkmgkc() 22CD5DA20 ? 7FC492F2BC80 ? 7FC49239EAB0 ? 7FC492268A40 ? 000000007 ? 22CD5DA20 ? qkebCreateColById() call kokscit() 22CD5DA20 ? 7FC492F2BC80 ? +298 7FC49239EAB0 ? 7FC492268A40 ? 000000007 ? 22CD5DA20 ? qksvcGetGuardCol()+ call qkebCreateColById() 000000002 7FC4923A4078 161 7FC49239EAB0 ? 000000007 ? 7FC492268A40 ? 22CD5DA20 ? qksvcProcessVCColum call qksvcGetGuardCol() 7FC49239D9D8 ? 7FC4923A4078 ? ns()+1625 7FC49239EAB0 ? 000000007 ? 7FC492268A40 ? 22CD5DA20 ? qkacol()+405 call qksvcProcessVCColum 000000000 ? 000000000 ? ns() 7FC49239EAB0 ? 000000007 ? 7FC492268A40 ? 22CD5DA20 ? qkadrv()+933 call qkacol() 7FC49239EAB0 ? 000000000 ? 7FC49239EAB0 ? 000000007 ? 7FC492268A40 ? 22CD5DA20 ? opitca()+2417 call qkadrv() 7FC4923A4078 ? 000000001 ? 7FC49239EAB0 ? 000000007 ? 7FC492268A40 ? 22CD5DA20 ? kksFullTypeCheck()+ call opitca() 7FC4922F4BD0 22CD5DC40 79 7FFFBD9CF3B0 000000007 ? 7FC492268A40 ? 22CD5DA20 ? rpiswu2()+2235 call kksFullTypeCheck() 7FFFBD9CDF08 ? 22CD5DC40 ? 7FFFBD9CF3B0 ? 000000007 ? 7FC492268A40 ? 22CD5DA20 ? kksLoadChild()+7590 call rpiswu2() 7FFFBD9CDF08 ? 22CD5DC40 ? 7FFFBD9CF3B0 ? 000000008 ? 7FC492F5D260 ? 22CD5DA20 ? kxsGetRuntimeLock() call kksLoadChild() 7FFFBD9CDF08 ? 22CD5DC40 ? +2155 000000000 000000008 ? 7FC492F5D260 ? 22CD5DA20 ? kksfbc()+14306 call kxsGetRuntimeLock() 7FC492F2BC80 7FC4922F4BD0 7FFFBD9CF330 22D1E7C28 ? 7FC492F5D260 ? 22D1E7C28 kkspsc0()+3146 call kksfbc() 7FC4922F4BD0 7FC4922F4BD0 ? 7FFFBD9CF330 ? 22D1E7C28 ? 7FC492F5D260 ? 22D1E7C28 ? kksParseCursor()+11 call kkspsc0() 7FC4928321A0 7FC49235D198 8 00000015F 000000003 000000006 000000020 opiosq0()+2210 call kksParseCursor() 7FFFBD9D0178 ? 7FC49235D198 ? 00000015F ? 000000003 ? 000000006 ? 000000020 ? opiall0()+4530 call opiosq0() 000000003 7FC49235D198 ? 7FC492F5D260 ? 000000020 000000000 000000020 ? opikpr()+567 call opiall0() 000000003 ? 000000022 7FFFBD9D0A50 000000000 000000000 ? 000000020 ? opiodr()+1165 call opikpr() 000000065 ? 000000022 ? 7FFFBD9D22F0 000000000 ? 000000000 ? 000000020 ? rpidrus()+206 call opiodr() 000000065 00000001F 7FFFBD9D22F0 ? 000000000 ? 000000000 ? 100000001 skgmstack()+144 call rpidrus() 7FFFBD9D1B70 00000001F ? 7FC492F2BE78 000000000 ? 000000000 ? 100000001 ? rpiswu2()+723 call skgmstack() 7FFFBD9D1B48 ? 7FC492F2B7A0 ? 00000F618 ? 00CBFE570 ? 7FFFBD9D1B70 ? 100000001 ? kprball()+1163 call rpiswu2() 7FFFBD9D1B48 ? 7FC492F2B7A0 ? 00000F618 ? 000000002 ? 7FC492F5D260 ? 100000001 ? qksdsExeStmt()+2411 call kprball() 7FFFBD9D22F0 004000180 00000F618 ? 000000002 ? 7FC492F5D260 ? 100000001 ? qksdsExecute()+959 call qksdsExeStmt() 7FFFBD9D2B98 7FC49235D150 000000001 000000008 7FFFBD9D28C8 100000001 ? kkoatVerifyEst()+30 call qksdsExecute() 7FFFBD9D2B98 7FC49235D150 ? 85 000000001 ? 000000008 ? 7FFFBD9D28C8 ? 100000001 ? kkeAdjSingTabCard() call kkoatVerifyEst() 300000001 7FC4923E9DA8 +714 1EE909D75846 7FC49235D108 000000000 100000001 ? kkecdn()+3803 call kkeAdjSingTabCard() 7FC4923E9DA8 7FC4923EA328 7FFFBD9D2E30 ? 7FC49235D108 ? 000000000 ? 100000001 ? kkotap()+13019 call kkecdn() 7FC4923ECF08 000000003 ? 7FFFBD9D2E30 ? 7FC4923EA328 ? 000000000 ? 100000001 ? kkoiqb()+8331 call kkotap() 7FC492F5D260 ? 000000000 ? 000000011 000000000 000000000 100000001 ? kkooqb()+532 call kkoiqb() 000000000 ? 000000000 000000000 000000000 ? 000000000 ? 100000001 ? kkoqbc()+2385 call kkooqb() 7FC4927F8BC0 ? 000000006 000000000 ? 000000000 ? 000000000 ? 100000001 ? apakkoqb()+182 call kkoqbc() 7FC4927F8BC0 ? 7FC4927F8BC0 ? 000000001 000000000 ? 000000000 ? 100000001 ? apaqbdDescendents() call apakkoqb() 000000000 ? 7FC4927F8BC0 ? +488 21EE306B8 ? 000000000 ? 000000000 ? 100000001 ? apadrv()+5383 call apaqbdDescendents() 7FFFBD9DC2B0 ? 7FC4927F8BC0 ? 21EE306B8 ? 000000000 ? 000000000 ? 100000001 ? opitca()+2106 call apadrv() 21EE306B8 ? 7FC4927F8BC0 ? 21EE306B8 ? 000000000 ? 000000000 ? 100000001 ? kksLoadChild()+7318 call opitca() 7FC492845648 21EE306B8 7FFFBD9DE6F0 000000000 ? 000000000 ? 100000001 ? kxsGetRuntimeLock() call kksLoadChild() 7FC492845648 ? 21EE306B8 ? +2155 000000000 000000000 ? 000000000 ? 100000001 ? kksfbc()+14306 call kxsGetRuntimeLock() 7FC492F2BC80 7FC492845648 7FFFBD9DE670 232AE3E98 ? 000000000 ? 232AE3E98 kkspsc0()+3146 call kksfbc() 7FC492845648 7FC492845648 ? 7FFFBD9DE670 ? 232AE3E98 ? 000000000 ? 232AE3E98 ? kksParseCursor()+11 call kkspsc0() 7FC492832108 7FFFBD9E0A28 8 000000081 000000003 000000006 0000000A4 opiosq0()+2210 call kksParseCursor() 7FFFBD9DF4B8 ? 7FFFBD9E0A28 ? 000000081 ? 000000003 ? 000000006 ? 0000000A4 ? kpoal8()+1223 call opiosq0() 000000003 7FFFBD9E0A28 ? 7FC492F5D260 ? 0000000A4 000000000 0000000A4 ? opiodr()+1165 call kpoal8() 00000005E 00000001F 7FFFBD9E3278 0000000A4 ? 000000000 ? 0000000A4 ? ttcpip()+2699 call opiodr() 00000005E 00000001F 7FFFBD9E3278 ? 0000000A4 ? 000000000 ? 100000000 opitsk()+1734 call ttcpip() 7FC492F41070 ? 00000005E ? 7FFFBD9E3278 000000000 ? 7FFFBD9E2CD8 7FFFBD9E3484 opiino()+945 call opitsk() 000000400 000000000 7FFFBD9E3278 ? 000000000 ? 7FFFBD9E2CD8 ? 7FFFBD9E3484 ? opiodr()+1165 call opiino() 00000003C 000000004 7FFFBD9E4918 000000000 ? 7FFFBD9E2CD8 ? 7FFFBD9E3484 ? opidrv()+587 call opiodr() 00000003C 000000004 7FFFBD9E4918 ? 000000000 ? 7FFFBD9E2CD8 ? 000000000 sou2o()+145 call opidrv() 00000003C 000000004 7FFFBD9E4918 000000000 ? 7FFFBD9E2CD8 ? 000000000 ? opimai_real()+154 call sou2o() 7FFFBD9E48F0 00000003C 000000004 7FFFBD9E4918 7FFFBD9E2CD8 ? 000000000 ? ssthrdmain()+412 call opimai_real() 000000000 7FFFBD9E4C00 000000004 ? 7FFFBD9E4918 ? 7FFFBD9E2CD8 ? 000000000 ? main()+236 call ssthrdmain() 000000000 000000002 7FFFBD9E4C00 000000001 000000000 000000000 ? __libc_start_main() call main() 7FFFBD9E559F 7FFFBD9E55AD +253 7FFFBD9E4C00 ? 000000001 ? 000000000 ? 000000000 ? _start()+41 call __libc_start_main() 000BBD640 000000002 7FFFBD9E4E48 000000000 ? 000000000 ? 000000000 ? [TOC00005-END] [TOC00006] --------------------- Binary Stack Dump ---------------------
解决方法
这里比较明显,我们可以发现这个sql执行报错,其实本质是由于递归执行动态采样报错而引起异常的.通过设置_fix_control来规避这个问题
SQL> alter session set "_fix_control"='14191778:0'; Session altered. SQL> SELECT * FROM USER.TABLE_NAME t WHERE t.YEAR = '2019' AND t.UPPCODE = '51010000' AND t.MONTH = '01'; 2 3 4 5 ID EMPCODE COMCODE YEAR QUARTER ---------- -------------------- -------------------- ---------- ---------- PUSHRATIO D A CREATECODE UPDATECODE CREATEDATE ---------- - - -------------------- -------------------- ------------------- UPDATEDATE UPPCODE CLAIM MONTH ------------------- -------------------- -------------------- ---------- 77813 5101000166 51010702 2019 1 50 0 0 1777 2018-07-18 17:44:19 51010000 50 01 77909 8000545245 51010702 2019 1 0 0 0 1777 1777 2018-07-18 17:35:12 2018-07-18 17:41:20 51010000 100 01 ID EMPCODE COMCODE YEAR QUARTER ---------- -------------------- -------------------- ---------- ---------- PUSHRATIO D A CREATECODE UPDATECODE CREATEDATE ---------- - - -------------------- -------------------- ------------------- UPDATEDATE UPPCODE CLAIM MONTH ------------------- -------------------- -------------------- ---------- 77912 5101000047 51010702 2019 1 0 0 0 1777 1777 2018-07-18 17:41:03 2018-07-18 17:44:28 51010000 100 01 SQL> SQL>