Advertisement

08.15.2007 at 07:27AM PDT, ID: 22764214
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

6.9

Oracle 10g versus 9i major I/O problem

Asked by tfex in Oracle 10.x, Oracle 9.x

Tags: , ,

We have a query that is run once a year to move all accounting data to the next fiscal year:

INSERT INTO COST_CD_ACCT
( COST_CD_ACCT.nr_id,
  COST_CD_ACCT.suffix_nr_id,
  COST_CD_ACCT.gl_cost_cd,
  COST_CD_ACCT.gl_acct_nr_id,
  COST_CD_ACCT.cc_acct_yr_tm,
  COST_CD_ACCT.cc_acct_mo_tm,
  COST_CD_ACCT.cc_acct_last_act_usr_id,
  COST_CD_ACCT.cc_acct_last_act_dt,
  COST_CD_ACCT.cc_acct_stat_cd,
  COST_CD_ACCT.acct_am )
SELECT
  COST_CD_ACCT.nr_id,
  COST_CD_ACCT.suffix_nr_id,
  COST_CD_ACCT.gl_cost_cd,
  COST_CD_ACCT.gl_acct_nr_id,
  :Incc_acct_yr_tm_0,
  0,
  'BATCH',
  SYSDATE,
  'A',
  NVL( SUM( COST_CD_ACCT.acct_am ), 0 )
  FROM
  COST_CD_ACCT
WHERE
  ( COST_CD_ACCT.cc_acct_mo_tm IN( 1,
  2,
  3,
  4,
  5,
  6,
  7,
  8,
  9 ) AND
  COST_CD_ACCT.cc_acct_yr_tm = :Incc_acct_yr_tm_1 ) OR ( COST_CD_ACCT.cc_acct_mo_tm IN( 0,
  10,
  11,
  12 ) AND
  COST_CD_ACCT.cc_acct_yr_tm = :Incc_acct_yr_tm_2 )
GROUP BY
  COST_CD_ACCT.nr_id,
  COST_CD_ACCT.suffix_nr_id,
  COST_CD_ACCT.gl_cost_cd,
  COST_CD_ACCT.gl_acct_nr_id

Binding <:Incc_acct_yr_tm_0> with <2007>
Binding <:Incc_acct_yr_tm_1> with <2007>
Binding <:Incc_acct_yr_tm_2> with <2006>

The query result is 13,748,977 rows inserted.

Here is the table:

desc COST_CD_ACCT
 Name                                      Null?    Type
 ----------------------------------------- -------- ----------------------------
 NR_ID                                     NOT NULL VARCHAR2(14)
 SUFFIX_NR_ID                              NOT NULL VARCHAR2(1)
 GL_COST_CD                                NOT NULL VARCHAR2(12)
 GL_ACCT_NR_ID                             NOT NULL VARCHAR2(7)
 CC_ACCT_YR_TM                             NOT NULL NUMBER(4)
 CC_ACCT_MO_TM                             NOT NULL NUMBER(2)
 CC_ACCT_LAST_ACT_USR_ID                            VARCHAR2(8)
 CC_ACCT_LAST_ACT_DT                                DATE
 CC_ACCT_STAT_CD                                    VARCHAR2(1)
 ACCT_AM                                            NUMBER(14,2)

Under orcale 9i this query runs in 27:27.

Under oracle 10g this query runs in 11:37:37 -- over 11 hours longer!!

The machine is an hp9000 runing 11.11.  It has four 875 mhz processors and 16 GB  ram.  The Oracle database files are on a SAN.  There were no hardware changes.  The only change was to upgrade to 10g.  There appears to be no memory or cpu contention.  The SAN reports very high I/O as would be expected.

During the run of this query we turn off all triggers on the table and drop all but the primary key indexes.  We also turn off archving because we do a backup before and after the query so archiving is unnecessary.

I think the problem lies in the amount of I/O that Oracle 10g overhead requires versus 9i.  Using GlancePlus we see the following I/O for the processes that seem to be involved:

Under 9i:
oracleret, user process, 6.56 GB I/O
ora_dbw0_ret, oracle process, 8.66 GB I/O
ora_lgwr_ret, oracle process, 7.16 GB I/O

Under 10g
oracleret, user process, 154 GB I/O, 11,518,878 phisical reads, 52,231 phisical writes
ora_dbw0_ret, oracle process, 158 GB I/O, 2,159,586 phisical reads, 14,001,896 phisical writes
ora_lgwr_ret, oracle process, 41.8 GB I/O, 60,531 phisical reads, 372,950 phisical writes

Here is the init.ora file:

O7_DICTIONARY_ACCESSIBILITY=FALSE
audit_sys_operations=TRUE
audit_trail=TRUE
background_dump_dest=/usr01/dba/admin/ret/bdump
compatible=10.2.0
control_files=/usr10/ORACLE/ret/retcntrl1.ctl, /usr10/ORACLE/ret/retcntrl2.ctl, /usr10/ORACLE/ret/retcntrl3.ctl
core_dump_dest=/usr01/dba/admin/ret/cdump
db_block_size=8192
db_cache_size=400M  #872415232
db_file_multiblock_read_count=32
db_files=250
db_name=ret
db_writer_processes=1
disk_asynch_io=FALSE
dml_locks=500
fast_start_mttr_target=300
global_names=TRUE
job_queue_processes=2
log_archive_dest='/usr08/ORACLE/ret/arch'
log_archive_format=ret_%s%t%r.arc
log_buffer=245760
max_dump_file_size=10240
nls_date_format=MMDDYYYY
open_cursors=400
os_roles=FALSE
processes=450
remote_login_passwordfile=EXCLUSIVE
resource_limit=TRUE
sga_max_size=4000000000
sga_target=2000000000
shared_pool_size=268435456
sort_area_retained_size=65536
sort_area_size=1024000
sql92_security=TRUE
timed_statistics=TRUE
undo_management=AUTO
undo_retention=900
user_dump_dest=/usr01/dba/admin/ret/udump
utl_file_dir=*
java_pool_size=67108864
streams_pool_size=50331648
large_pool_size=8388608
pga_aggregate_target=25165824
session_max_open_files=20

I am not the DBA but am the programmer in charge of making the application work.  The DBAs so far have not been able to help and Oracle support has provided no insight.  The DBAs have not been able to get Enterprise Manager configured because they forgot some password ...

Is there an automatic oralce feature that is causing this overhead?  Is there something we can tune, change or turn off?Start Free Trial
[+][-]08.16.2007 at 12:41AM PDT, ID: 19706099

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08.23.2007 at 09:38PM PDT, ID: 19759786

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10.31.2007 at 06:48AM PDT, ID: 20185422

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10.31.2007 at 12:42PM PDT, ID: 20188491

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Oracle 10.x, Oracle 9.x
Tags: oracle, 10g, 9i
Sign Up Now!
Solution Provided By: prast1007
Participating Experts: 2
Solution Grade: B
 
 
[+][-]11.01.2007 at 04:26AM PDT, ID: 20191914

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628