Skip to Main Content

Breadcrumb

Question and Answer

Connor McDonald

Thanks for the question, Div.

Asked: September 20, 2016 - 6:06 pm UTC

Last updated: September 20, 2016 - 8:23 pm UTC

Version: 11.2.0.4

Viewed 1000+ times

You Asked

Hi Tom,
I have been reading your questions/answers thread and like it. Want to ask you one simple question.

Database Time= CPU Time +Non-Idle Wait;

I see in my database, CPU Time is more all the time and Non-Idle Wait is less.
say for example, for one Query
DB Time=4.5min
CPU Time=4.26 min(98%)
Non-Idle Time=4.280Seconds(1.62%)--The wait is User I/O (direct path read)
IO Requests=1,366

my question, Is this good or bad? or depends.

My thinking is if most of the time is spend on CPU then it's doing something good. and there should be less time waiting for any Non-Idle wait. in my case it's User I/O so lesser is the User I/O more it is good. correct?

Thanks in advance

and Chris said...

The good thing about having most of your time on CPU is you can scale your system by adding more of it.

But that doesn't necessarily mean your system is "well tuned". You might have processes eating CPU on useless work. For example:

select 1 from dual;

and

select sqrt(power(1, 2)) from dual;

return the same answer. But the second does a lot of unnecessary work!

So it's better for most of the database time to be CPU time. But it doesn't mean you have an optimal application!

Rating

  (2 ratings)

Is this answer out of date? If it is, please let us know via a Comment

Comments

Excellent

Div, September 20, 2016 - 11:34 pm UTC

Hi Thanks for getting back to me in a quick time.
I agree with you.your last time says "But it doesn't mean you have an optimal application!" Yes Agree !
how one can make application optimal? I mean it involves lot of things, firstly Developer, then comes the infrastructure that includes everything Network,Storage,Database Server etc. Tuning can be never ending process, when to stop? or say we got optimal application.

thanks

DB Time

A reader, September 21, 2016 - 7:54 am UTC

IF you mess with the developers, every thing else can not help you.

Akram Khan