Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: SQL Tuning Regarding System CPU Stats
On May 17, 7:00 pm, Mladen Gogala <mgogala.SPAM_ME...._at_verizon.net>
wrote:
> On Thu, 17 May 2007 08:55:33 -0700, andrew.markiewicz wrote:
> > Hello all.
> > We are in the process of upgrading from 9i to 10g and starting to use
> > system statistics. Since the system statistics are used per database
> > instance and not per user/schema, what approach is recommended for
> > tuning a production system within a development environment?
>
> The best approach is: if it ain't broken, don't fix it. Besides that,
> what does it mean to "tune production system"? I was under the impression
> that applications are what needs tuning, not the system. There is a little
> known book, published by O'Reilly few years ago, named "Optimizing Oracle
> for Performance", written by two guys, Cary Millsap and Jeff Holt. The
> book is as timeless as Mona Lisa, but not as inscrutable. It certainly
> doesn't depend on Oracle version. It deals with performance problems from
> the philosophical point of view and answers the question of life universe
> and everything. There is also a prolific author named Tom Kyte who writes
> various things, Oracle books among other things. I can wholeheartedly
> recommend his collected works, too. Further reading would include Cost-
> Based fundamentals by Jonathan Lewis, RAC Handbook by K. Gopalakrishnan,
> Oracle 10 Wait events by Kirti Deshpande (phenomenal book!!!) and Dan
> Tow's SQL Tuning.
> For further specialized topics, I would recommend numerous available
> articles by Tom Kyte, Jonathan Lewis, Wolfgang Breitling, Tim Gorman,
> The Hotsos gang, Julian Dyke, Howard Rogers, Connor McDonald as well
> as specialized DW books by Ralph Kimball and Gavin Powell.
>
> --http://www.mladen-gogala.com
I frequent Tom Kyte's site and have both his books, studied and restudied Wolfgang Brietling's paper on the 10053 trace such that it is tattered, highlighted and stained with coffee and tears, own and read Jonathon Lewis's "Cost Based Oracle Fundamentals", and peruse OTN, Metalink, groups such as this and other forums. I am familiar with HOW to tune, but was interested in how others approach setting up the environment for tuning with using system statistics.
According to Jonathon's book "Cost Based Oracle Fundamentals", p. 82, "The default value for this parameter (_optimizer_cost_model) is 'choose', and 9i will choose to use CPU costing only if the system statistics exist, but 10g will always choose to use CPU costing and then synthesize some statistics if there aren't any in place....". So db version does matter to how the CBO will generate execution plans. I don't particularly care for the idea of Oracle generating CPU stats that will then be used to generate SQL statements, therefore we must gather system stats. Also, we currently set the optimizer_index_cost_adj and optimizer_index_caching values which will continue to have an influence on the CBO in conjunction with the CPU stats. So the use of those values will need to be reviewed as well.
I suppose I can't speak for others shops, but here we typically have
our best machines for production and the next best for test. There
are system differences between the machines and databases (CPU speed,
allocated memory for SGA, size of buffer cache, speed of the hard
drive the datafiles are on, existence of an OS file or block cache,
etc). I am not a SysAdmin but I think these differences will have an
impact on the system statistics that would be optimal for that
machine.
So I feel there are two (possibly three) options for how we approach
setting up our IS environment for development (which has nothing to do
with tuning individual SQL.)
In summary, my main issue is that I see performance tuning with system stats as being more complicated in a holistic sense than previous releases without system statistics. I haven't had a great deal of opportunity to actually get my hands dirty and test out using the system stats, but as I am upgrading the db and settng up a test environment for the developers, these questions arose and I am wondering how others have approached the issue. If it even is one. Perhpas I am just overthinking it.
Andrew Received on Fri May 18 2007 - 09:36:13 CDT
![]() |
![]() |