大数据并行sqlload加载,丢数据和入库有积压
系统环境:AIX6.1 64G内存,16核数据库环境:ORACLE11g
用sqlload入库,入库流量在40-50MBps/s,现存在丢数据和入库有积压。
入库日志有时会报
SQL*Loader-951: Error calling once/load initialization
ORA-02477: can not perform parallel direct load on object 4396828
数据库已经设置为NOARCHIVELOG模式,force_logging关闭,parallel_max_servers=640。SGA=36G,PGA=12G
sqlload不经过SGA,SGA设置是否偏大?
有那些参数可以优化的? Hdr: 10018143 11.2.0.1 RDBMS 11.2.0.1 SQL*LOADER PRODID-5 PORTID-226 ORA-2477 8769441
Abstract: DIRECT MODE LOAD FALSELY FAILS WITH ORA-2477
*** 08/11/10 12:10 pm *** (CHG: Test Case Status-> NULL -> Z)
*** VPOMPEE 08/11/10 12:10 pm ***
BUG TYPE CHOSEN
===============
Code
SubComponent: SQL*Loader
========================
DETAILED PROBLEM DESCRIPTION
============================
Direct mode load falsely fails with ORA-2477
SQL*Loader-951: Error calling once/load initialization
ORA-2477: can not perform parallel direct load on object 73550
ORACLE11g
11g到底什么版本?
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 sqlldr和最新的awr SQL*Loader-951: Error calling once/load initialization
ORA-02477: can not perform parallel direct load on object 4413857
oerr ora 2477
02477, 00000, "can not perform parallel direct load on object %s"
// *Cause: A parallel direct load is not possible because an index is
// is being created on the table.
// *Action: Retry load after index creation is complete.
从awr中可以看到 有索引维护
Elapsed Time (s) Executions Elapsed Time per Exec (s) %Total %CPU %IO SQL Id SQL Module SQL Text
16,527.57 2 8,263.78 31.04 51.46 27.52 4yvwyb5z5t8v9 SQL*Plus BEGIN SP_ORA_INDEX_REBUILD_ALL...
4,247.36 10 424.74 7.98 50.33 26.50 2p7c1wy5dwfbm SQL*Plus BEGIN SP_ORA_INDEX_REBUILD_ALL
请检查 在sqlload加载数据的时候 是否有索引维护的任务 在执行呢? 每个小时有定时任务执行索引重建。
控制文件中设置direct=true skip_index_maintenance=true parallel=true,导入的时候应该已经忽略索引了的。 是否与parallel_max_servers这个参数设置过大有关系,parallel_max_servers=640,只有几个并发查询的用户
select count(*) from dba_hist_parameter b where b.parameter_name='parallel_max_servers'
207 select * from v$pq_slave; 看有多少条记录 SQL> select * from v$pq_slave;
SLAVE_NAME STATUS SESSIONS IDLE_TIME_CUR BUSY_TIME_CUR CPU_SECS_CUR MSGS_SENT_CUR MSGS_RCVD_CUR IDLE_TIME_TOTAL BUSY_TIME_TOTAL CPU_SECS_TOTAL MSGS_SENT_TOTAL MSGS_RCVD_TOTAL
---------- ------ ---------- ------------- ------------- ------------ ------------- ------------- --------------- --------------- -------------- --------------- ---------------
skip_index_maintenance=true,只是忽略 sqlloader的 index维护, 每小时的索引维护 仍是运行的,建议 在导入的时间段暂停定时索引维护 观察下效果。 已经暂停。现入库数据库索引都是UNUSABLE.
266 P_20140220_78 UNUSABLE
265 P_20140220_77 UNUSABLE
264 P_20140220_76 UNUSABLE
261 P_20140220_73 UNUSABLE
262 P_20140220_74 UNUSABLE
59 P_20140220_15 UNUSABLE
这应该不是报错的原因
页:
[1]