Tuning and health
Are developers getting worse as databases mature, or are they just not able to grow their skills at the same rate the requirements are exploding? Either way, Oracle is doing a lot to help DBAs discover and deal with resource-hogging code.
For starters, Database 11g adds self-learning capabilities to Oracle's automatic SQL tuning. Now the engine detects high-load SQL statements and saves them for tuning during a maintenance window. It can apply some automatic fixes or suggest structural changes, such as indexes. If you're leery of letting the engine do too much tuning, you can let it simply capture your queries and suggest fixes. Then, if the engine turns out to be right most of the time, you can start trusting it more. One problem is that Oracle can't take your entire workload into account, so it may suggest changes that would damage your normal flow for a query that gets run only every so often.
There's more than one way to quantify a runaway workload, and Oracle has risen to the occasion here as well. When workloads go awry, it's typically in one of the three main areas of server performance: CPU, memory, or disk I/O. Usually resource governors quantify a runaway workload by measuring CPU or memory, but Oracle Database 11g has also instituted per-session I/O limits.
These I/O limits allow you to specify a maximum value (either in I/O requests or in megabytes) of work that connections are allowed to perform on the server. I/O limits are a very important addition (especially in the case of large warehouses) because these systems can become disk-bound very easily, and CPU or memory resource capping doesn't adequately address disk contention.
I/O caps can also help DBAs put the kibosh on long-running queries. Because there's no way to natively define a policy that checks whether a query has used 20 per cent of the CPU for 20 minutes, for example, DBAs will often write their own checks, and then have the code do something based off of the results. Being able to cap total I/O consumption means no longer having to manage these checks by hand.
And as usual, you can move these long-running queries to a lower-priority resource group as they become a problem. It's like being put in the penalty box at a hockey game. If you're going to write SQL that drags the system down, then you'll be given fewer resources so that you can't affect others. And of course, as a result, your query will take a lot longer.
Result Cache
Result Cache is a feature that can make or break you, depending on who's holding the wheel. Result Cache allows you to effectively pin a query result into a special buffer in memory, therefore bypassing the disk lookup for subsequent calls to the same query. You can cache entire queries, subqueries, or even PL/SQL functions. Of course, the query call has to be the same as the cached version -- and therein lies the rub. Quite often, queries differ only in the parameters being passed (the case with most OLTP queries), so you'll have a lot of individual queries being cached, but very little reuse.
To that end, Oracle gives you three different levels in which you can specify your result cache: the database level, the session level, and the query level. There's a lot of power in those options, for both good and evil, so I would suggest sticking with the query or session level unless you've thoroughly tested it at the database level and you know exactly what to expect. At the database level, all query results will be cached, including those that don't need it. And by default, the result cache is assigned a fairly small portion of the buffer, so you're not likely to see tremendous results unless you expand the allocation.
Oracle has implemented Result Cache pretty well, and it does exactly what it's told. In my initial tests, I had no problems seeing results. I tested against just a couple queries to get the feel for it, and I did see vast improvements in my query times. After I bumped up the number of queries and parameterized them, however, I didn't see nearly the same changes as I did the first time. That's not unexpected at all and in no way outlines any kind of shortcoming with the feature. I'm merely pointing out that you need to plan carefully and test thoroughly before you implement it in production.
It should also go without saying that this feature is aimed at improving performance on disk-bound systems and isn't going to do any good on memory-bound systems. If you're already experiencing memory pressure, carving out a buffer in an already constrained system is only going to make things worse. I'd also like to point out that in general, this isn't going to help a great deal with your OLTP workloads. And if you use it on your decision support workloads, be mindful of the query results you're caching. It's easy to forget that even 64-bit systems have memory limits, and that caching a 200-million-row result might not be the best use of your memory resources.
I like Result Cache for what I call nuisance queries, which are lookups you do to satisfy joins or to pull results that rely on table scans -- things of that nature. But Result Cache is a good feature that will let you do pretty much whatever you want to do.
- +
Ticked Off at Tick the Box Mentality 04/02/2008 13:01:15
Does your executive search firm know the difference between an MIS manager and a CIO, and if it does, can it explain that difference to its corporate clients?Does your executive search firm know its MIS managers from its elbow? Does it even know the difference between an MIS manager and a CIO, and if it does, can it explain that difference to its corporate clients? - +
Strategies for Dealing With IT Complexity 24/12/2007 10:30:47
Every innovation, every business process improvement, comes with an IT complexity tax that must be paid by CIOs in time, money and sweat. Here are strategies to mitigate the increasing complexity of IT as it enables new business.Every innovation, every business process improvement, comes with an IT complexity tax that must be paid by CIOs in time, money and sweat. Here are strategies to mitigate the increasing complexity of IT as it enables new business.
Read up on the latest ideas and technologies from companies that sell hardware, software and services. CRM your salespeople will love
Data grids and service-oriented architecture
Taking On Demand CRM Integration to the Next Level
Mimosa™ NearPoint™ for Microsoft® Exchange Server: Email Archiving 101
Gaining Competitive Advantage Through Enterprise Planning
Business Intelligence and Enterprise Performance Management: Trends for Emerging Businesses
Agile in the Enterprise
How to Beef Up Your Sales Pipeline
Zones provide focussed content from Computerworld and leading technology partners.Discover how SOA can create smarter outcomes for your business.
Attend and learn:
- How SOA is helping leading companies to become more agile
- Where you should be applying SOA processes in your company
- The top SOA implementation mistakes to avoid
Click here for more information.
- +
Computerworld Live Podcast #97: The Future of Enterprise Networking 25/07/2008 09:45:36
This week CW Live chats with Mark Thompson, global sales and marketing manager for HP ProCurve, on the future of the enterprise networking. Mark discusses the trends we can expect to see in the near future and how the right infrastructure can ensure your enterprise network is secure. - +
Computerworld Live Podcast #96: Security at the Edge 11/06/2008 09:22:22
CW Live speaks with Amol Mitra, HP ProCurve Director of Marketing for Asia Pacific and Japan. Today's topic: how enterprises are starting to shift away from simply controlling security via server logins, firewalls and moving to more adaptive security frameworks. - +
Data Management Edition #10: Multi-Petascale Systems 02/05/2008 09:12:33
This week we look at sustainability and the development of multicore technologies to build multi-petascale systems. - +
IT Security Edition #11: How to poison the Storm botnet 01/05/2008 08:51:55
This week CW Live presents a case study on how to poison the notorious Storm botnet . Plus we take a look at Cisco's plans for Ironport. - +
IT Security Edition #10: Cyber-battles fought and won 24/04/2008 11:09:47
Vendors bow to end user pressure to improve product security, and we take a look at the latest concepts shaping the cyber-battlefield of the future.
Vignette Announces 2008 Excellence Awards 2008-11-21 10:50:00+11
PGP and Ponemon Institute Unveil Inaugural Australian Data Breach Study 2008 2008-11-20 17:34:00+11
Symantec Cloud Services Transform Data Centre Operations Through Proactive Management 2008-11-20 12:06:00+11
Verizon Business Offers Tips to Building a Successful Unified Communications and Collaboration Plan 2008-11-20 12:04:00+11
AARNet Brings 4K Digital Cinema to Australia: First 4K HD Video Signal delivered into Australia by AARNet 2008-11-20 12:02:00+11
Best Practice in Building an Integrated Information Management Strategy
Discover the business value that creating an integrated information platform can bring. Learn how to provide consistent, accurate information to all stakeholders within your business network. Integrate vital data from disparate sources and deliver a trusted information foundation. Read on to uncover the stepping-stones to your new information management strategy.









