OCP Oracle Database 11g:New Features for Administrators Exam Guide Exam 1Z0-050 ®... OCP Oracle Database 11g:New Features for Administrators Exam Guide Exam 1Z0-050 Sam Alapati New Yor
Trang 2OCP Oracle Database 11g:
New Features for
Administrators
Exam Guide (Exam 1Z0-050)
®
Trang 3This page intentionally left blank
Trang 4OCP Oracle Database 11g:
New Features for
Administrators
Exam Guide (Exam 1Z0-050)
Sam Alapati
New York Chicago San Francisco Lisbon London Madrid
This publication and CD-ROM may be used in assisting students to prepare for the
OCP Oracle Database 11g: New Features for Administrators exam Neither Oracle
Corporation nor The McGraw-Hill Companies warrant that use of this publication
and CD-ROM will ensure passing the relevant exam.
®
Trang 5Copyright © 2008 by The McGraw-Hill Companies, Inc All rights reserved Manufactured in the United States of America Except as permitted under the United States Copyright Act of 1976, no part of this publication may be reproduced or distributed in any form or
by any means, or stored in a database or retrieval system, without the prior written permission of the publisher
0-07-164372-9
The material in this eBook also appears in the print version of this title: 0-07-149682-3.
All trademarks are trademarks of their respective owners Rather than put a trademark symbol after every occurrence of a trademarked name, we use names in an editorial fashion only, and to the benefit of the trademark owner, with no intention of infringement of the trademark Where such designations appear in this book, they have been printed with initial caps
McGraw-Hill eBooks are available at special quantity discounts to use as premiums and sales promotions, or for use in corporate training programs For more information, please contact George Hoare, Special Sales, at george_hoare@mcgraw-hill.com or (212) 904-4069
TERMS OF USE
This is a copyrighted work and The McGraw-Hill Companies, Inc (“McGraw-Hill”) and its licensors reserve all rights in and to the work Use of this work is subject to these terms Except as permitted under the Copyright Act of 1976 and the right to store and retrieve one copy of the work, you may not decompile, disassemble, reverse engineer, reproduce, modify, create derivative works based upon, transmit, distribute, disseminate, sell, publish or sublicense the work or any part of it without McGraw-Hill’s prior consent You may use the work for your own noncommercial and personal use; any other use of the work is strictly prohibited Your right to use the work may be terminated if you fail to comply with these terms
THE WORK IS PROVIDED “AS IS.” McGRAW-HILL AND ITS LICENSORS MAKE NO GUARANTEES OR WARRANTIES AS
TO THE ACCURACY, ADEQUACY OR COMPLETENESS OF OR RESULTS TO BE OBTAINED FROM USING THE WORK, INCLUDING ANY INFORMATION THAT CAN BE ACCESSED THROUGH THE WORK VIA HYPERLINK OR OTHERWISE, AND EXPRESSLY DISCLAIM ANY WARRANTY, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE McGraw-Hill and its licensors do not warrant or guarantee that the functions contained in the work will meet your requirements or that its operation will be uninterrupted or error free Neither McGraw-Hill nor its licensors shall be liable to you or anyone else for any inaccuracy, error or omission, regardless
of cause, in the work or for any damages resulting therefrom McGraw-Hill has no responsibility for the content of any information accessed through the work Under no circumstances shall McGraw-Hill and/or its licensors be liable for any indirect, incidental, spe- cial, punitive, consequential or similar damages that result from the use of or inability to use the work, even if any of them has been advised of the possibility of such damages This limitation of liability shall apply to any claim or cause whatsoever whether such claim
or cause arises in contract, tort or otherwise
DOI: 10.1036/0071496823
Trang 6We hope you enjoy this McGraw-Hill eBook! If you’d like more information about this book, its author, or related books and websites,
please click here.
Professional
Want to learn more?
Trang 7To the twins, Nina and Nicholas.
Trang 8ABOUT THE AUTHOR
Sam Alapati (Irvine, TX) is an experienced Oracle DBA who holds the Oracle OCP
DBA (11g) certification and the Hewlett-Packard UNIX System Administrator
certification He currently manages Oracle databases at the Boy Scouts of America’s national office in Irving, Texas Previously, Sam worked for AMR Holdings (Sabre) and the Blanch Company in Dallas Sam was a Senior Principal Consultant for Oracle Corporation in New York, working with NBC and Lehman Brothers In addition to being a professional Oracle database administrator, Sam has also taught Oracle DBA classes for many students and college-level courses at Kansas State University, University of Texas at Austin, and Rutgers University
About the Technical Editor
April Wells (Austin, TX) is an experienced Oracle DBA who holds multiple OCP
DBA certifications She currently manages Oracle databases and Oracle data warehouses at NetSpend Corporation in Austin, Texas Previously, April worked for Oracle Corporation in Austin as on-site support at Dell; at Corporate Systems
in Amarillo, Texas; and at US Steel in Pennsylvania and Minnesota
Trang 9CONTENTS AT A GLANCE
1 Installing, Upgrading, and Change Management 1
2 Diagnosing and Resolving Problems 77
3 Intelligent Infrastructure and Database Security 147
4 Automatic SQL Tuning and SQL Plan Management 213
5 Automatic Storage Management and Partitioning Enhancements 263
6 Performance Enhancements 321
7 RMAN and Flashback Enhancements 383
8 Oracle SecureFiles and Miscellaneous New Features 449
About the CD-ROM 491
Glossary 493
Index 507
Trang 10CONTENTS
Acknowledgments xv
Introduction xvi
1 Installing, Upgrading, and Change Management 1
Installing Oracle Database 11g 3
Changes in the Optimal Flexible Architecture 3
Automatic Diagnostic Repository 5
Changes in the Installation Options 6
New Database Components 7
Role and Privilege Changes 7
An Oracle Database 11g Installation 8
New Features in Database Creation 10
Summary of New Initialization Parameters 10
DBCA Enhancements 12
Using the DBCA to Create a Database 13
Upgrading to Oracle Database 11g 19
Moving Data as Part of the Upgrade 19
New Privileges for Storage Management 20
Upgrading to Oracle Database 11g 20
Exercise 1-1 Scripts to Run for Upgrading a Database 31
Real Application Testing 32
Database Replay 33
Exercise 1-2 Procedure for Capturing and Replaying a Database Workload 47
The SQL Performance Analyzer 51
Exercise 1-3 Testing SQL Performance Following a Database Upgrade 61
✓ Two-Minute Drill 63
Q&A Self Test 68
Lab Question 71
Self Test Answers 72
Lab Answer 75
2 Diagnosing and Resolving Problems 77
Automatic Diagnostic Repository 80
The Structure of the ADR 81
ADRCI 83
For more information about this title, click here
Trang 11Incidents and Problems 88
Incident Packaging Service 90
Exercise 2-1 Creating an Incident Package with ADRCI 95
Support Workbench 96
Viewing Critical Error Alerts 96
Examining Problem Details 98
Collecting Additional Diagnostic Data 98
Creating a Service Request 99
Packaging and Uploading Diagnostic Data 100
Tracking the Service Request 102
Implementing Repairs 103
Closing Incidents 103
Generating a User-Created Problem 103
Viewing the Alert Log 104
Health Monitor 105
Running a Health Check 106
Exercise 2-2 Running a Health Check with Input Parameters 107
Viewing the Health Monitor Reports 110
SQL Repair Advisor 110
Using the Support Workbench 111
Using the DBMS_SQLDIAG Package 111
Exercise 2-3 Exporting a SQL Patch to Another Database 114
Data Recovery Advisor 115
Failures 117
Repair Options 118
Using RMAN to Manage the Data Recovery Advisor 119
Proactive Checks 126
Managing the DRA with Database Control 130
New Parameter to Detect Database Corruption 131
✓ Two-Minute Drill 135
Q&A Self Test 138
Lab Question 142
Self Test Answers 143
Lab Answer 146
Contents ix
Trang 12x OCP Oracle Database 11g: New Features for Administrators Exam Guide
3 Intelligent Infrastructure and Database Security 147
Enhancements in AWR Baselines 148
Managing Baseline Templates 149
Renaming a Baseline 152
Setting AWR Baseline Metric Thresholds 152
Moving Window AWR Baselines 155
Managing the New Baseline Features 156
Controlling Automated Maintenance Tasks 158
Predefined Maintenance Windows 159
Managing the Automatic Maintenance Tasks 159
Implementing Automatic Maintenance Tasks 163
Configuring Resource Allocation for Automatic Tasks 163
I/O Calibration 164
Exercise 3-1 Calibrating I/O Resources 164
Database Resource Manager New Features 167
Per Session I/O Limits 168
Pre-Created Mixed Workload Resource Plan 172
Using New Oracle Scheduler Features 173
Lightweight Jobs 173
Exercise 3-2 Creating an Array of Regular Scheduler Jobs 177
Remote External Jobs 178
Scheduler Support for Data Guard 184
Security Enhancements 185
Secure Password Support 186
Configuring Fine-Grained Access to Network Services 190
Encrypting Tablespaces 194
Creating the Oracle Wallet 195
Creating an Encrypted Tablespace 196
Restrictions on Tablespace Encryption 198
✓ Two-Minute Drill 201
Q&A Self Test 204
Lab Question 207
Self Test Answers 208
Lab Answer 211
4 Automatic SQL Tuning and SQL Plan Management 213
Automatic SQL Tuning Advisor 214
SQL Profiles 216
Trang 13Limitations 217
The Automatic SQL Tuning Process 217
Exercise 4-1 Using Enterprise Manager to Access the SQL Tuning Advisor 222
Interpreting Automatic SQL Tuning Reports 223
Data Dictionary Views 224
SQL Plan Management 225
SQL Plan Baselines 226
Capturing SQL Plan Baselines 227
Fixed SQL Plan Baselines 235
SQL Plan Baseline Attributes 235
Managing SQL Plan Baselines 237
The SQL Management Base 238
Managing SPM with the Enterprise Manager 240
SQL Access Advisor Enhancements 240
New Procedures 240
Partitioning Recommendations 242
Publish Points 243
Running a SQL Access Advisor Job Using PL/SQL 243
Using Enterprise Manager 249
Using the Cursor Cache to Get SQL Access Advisor Recommendations 251
✓ Two-Minute Drill 254
Q&A Self Test 257
Lab Question 259
Self Test Answers 260
Lab Answer 262
5 Automatic Storage Management and Partitioning Enhancements 263
Automatic Storage Management New Features 264
ASM Architecture 264
ASM Fast Mirror Resync 265
ASM Preferred Mirror Read 269
ASM Scalability and Performance Enhancements 272
New SYSASM Privilege 274
ASM Compatibility 275
Changing ASM Disk Group Attributes 279
New Manageability Options for Commands 280
Contents xi
Trang 14xii OCP Oracle Database 11g: New Features for Administrators Exam Guide
Exercise 5-1 Using the md_backup and md_restore
Commands 288
Partitioning Enhancements 289
Interval Partitioning 290
System Partitioning 295
Virtual Column-Based Partitioning 298
Reference Partitioning 301
Composite Partitioning Enhancements 307
✓ Two-Minute Drill 312
Q&A Self Test 315
Lab Question 316
Self Test Answers 317
Lab Answer 318
6 Performance Enhancements 321
ADDM Enhancements 322
ADDM for Real Application Clusters 322
New DBMS_ADDM Package 324
Automatic Memory Management 328
SGA, PGA, and the MEMORY_TARGET Parameter 329
Exercise 6-1 Using Automatic Memory Management 331
Monitoring Automatic Memory Management 332
DBCA and Automatic Memory Management 333
Enhancements in Optimizer Statistics Collection 334
Statistics Preferences 334
Partitioned Tables and Incremental Statistics 337
New Sampling Technique 338
Deferred Statistics Publishing 338
Extended Statistics 341
Result Cache 347
Result Cache Memory Pool 347
Managing the Result Cache 348
Caching SQL Results with a Result_Cache Hint 348
Using the DBMS_RESULT_CACHE Package 350
Using Dynamic Performance Views 353
The SQL Query Result Cache 354
The PL/SQL Function Result Cache 357
The Client Query Result cache 359
Adaptive Cursor Sharing 362
Trang 15How Adaptive Cursor Sharing Works 364
Monitoring Adaptive Cursor Sharing 365
✓ Two-Minute Drill 369
Q&A Self Test 373
Lab Question 376
Self Test Answers 377
Lab Answer 380
7 RMAN and Flashback Enhancements 383
RMAN Enhancements 384
Active (Network-Based) Database Duplication 384
Parallel Backup and Restore of Large Files 392
Archival (Long-Term) Backups 394
Fast Incremental Backups 398
Improved Block Media Recovery Performance 398
New Persistent Configuration Parameters 401
Backup Failover to Non-Flash Recovery Areas 404
Recovery Catalog Management 405
Merging Recovery Catalogs 405
Virtual Private Catalogs 408
New Flashback-Related Features 413
Flashback Data Archive 413
Flashback Transaction Backout 427
Exercise 7-1 Using the TRANSACTION_BACKOUT Procedure 430
✓ Two-Minute Drill 433
Q&A Self Test 438
Lab Question 442
Self Test Answers 443
Lab Answer 447
8 Oracle SecureFiles and Miscellaneous New Features 449
Oracle SecureFiles 450
Enabling SecureFiles 451
Capabilities of SecureFiles 452
Storage Options for SecureFiles 453
Creating SecureFiles 454
Managing and Monitoring SecureFiles 456
Migrating to SecureFiles 457
Contents xiii