- •About the Authors
- •Contents at a Glance
- •Contents
- •Table of Exercises
- •Introduction
- •Assessment Test
- •Answers to Assessment Test
- •What Is ASM?
- •Working with the ASM Instance
- •Overview of ASM Data Dictionary Views
- •Using ASM Storage
- •Using RMAN with ASM
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Understanding the Oracle Database as It Relates to Backup and Recovery
- •Performing Oracle Offline Backups
- •Performing Oracle Online Backups
- •Backing Up the Control File
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Performing Incomplete Recoveries
- •Performing Other Types of Recoveries
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Why Use RMAN?
- •Exploring the RMAN Architecture
- •Connecting to RMAN
- •Configuring RMAN for Use
- •Backing Up Your Database with RMAN
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Introducing the Recovery Catalog
- •Creating the Recovery Catalog User and Schema Objects
- •Using a Recovery Catalog
- •Maintaining the Recovery Catalog
- •Using the RMAN Virtual Private Catalog
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •RMAN Database-Recovery Basics
- •Using Image Copies to Recover Your Database
- •Other Basic Recovery Topics
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Switching Between RMAN Incarnations
- •Overview of RMAN Database Duplication
- •Performing an RMAN Tablespace Point-in-Time Recovery
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Overview of Flashback Technology
- •Using Automatic Undo Management
- •Using Flashback Technologies
- •Using Additional Flashback Operations
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Diagnosing the Database
- •Managing Database Performance
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Managing Memory
- •Managing Space
- •Managing Resources
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Automating Tasks with the Scheduler
- •Exploring the Scheduler Architecture
- •Exploring Common Administration Tools
- •Using Scheduler Jobs
- •Using Scheduler Programs
- •Using Schedules
- •Creating Lightweight Jobs
- •Using Job Chains
- •Using Scheduler Windows
- •Creating and Using Job Classes
- •Using Advanced Scheduler Concepts to Prioritize Jobs
- •Using Scheduler Views
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •An Overview of Globalization Support
- •Using NLS Parameters
- •Using Datetime Datatypes
- •Using Linguistic Sorts and Searches
- •Summary
- •Exam Essentials
- •Review Questions
- •Answers to Review Questions
- •Lab 1.1: Creating an ASM Instance
- •Lab 1.2: Creating ASM Disk Groups
- •Lab 1.3: Using ASM Disk Groups from a Database
- •Lab 2.2: Putting the Database in ARCHIVELOG Mode
- •Lab 2.3: Executing a Manual Online (Hot) Backup
- •Lab 3.1: Executing a Time-Based Point-in-Time Recovery
- •Lab 3.2: Recovering from Control-File Loss with a Backup Control File
- •Lab 3.3: Recovering from Loss of the Current Online Redo Log
- •Lab 4.1: Creating an RMAN Offline Backup
- •Lab 4.2: Creating an RMAN Incremental Backup
- •Lab 4.3: Creating an Image-Copy Backup
- •Lab 5.1: Implementing RVPC
- •Lab 6.1: Restoring a Datafile Online
- •Lab 6.2: Performing a Change-Based Recovery with RMAN
- •Lab 6.3: Restoring a Control File from an Autobackup
- •Lab 7.1: Monitoring RMAN Backups
- •Lab 7.2: One of My Backups Is Missing!
- •Lab 8.1: Duplicating a Database Using Active Database Duplication
- •Lab 8.2: Duplicating a Database Using Backup-Based Duplication to a Different Point in Time
- •Lab 9.1: Using the Recycle Bin
- •Lab 9.3: Using Flashback Data Archive
- •Lab 10.1: Using Support Workbench to Report a Problem to Oracle Support
- •Lab 11.1: Exporting a Transportable Tablespace
- •Lab 11.2: Testing Resumable Space Allocation
- •Lab 11.3: Manually Configuring the SGA
- •Lab 12.1: Creating a Local External Job
- •Lab 12.2: Creating a Job Window
- •Lab 13.1: Using the Locale Builder to Create a New Linguistic Sort
- •Lab 13.2: Setting NLS Parameters
- •Lab 13.3: Performing Linguistic Sorts
- •What You’ll Find on the CD
- •System Requirements
- •Using the CD
- •Troubleshooting
- •Glossary
- •Index
Answers to Assessment Test |
xlv |
Answers to Assessment Test
1.F, G. ASM supports datafiles, log files, control files, archive logs, RMAN backup sets, spfiles, and other Oracle database file types, but not password files or init.ora files. For more information, see Chapter 1, “Using Oracle ASM.”
2.C. The V$ASM_OPERATION view will indicate if the drop disk operation is still in progress. If no rows are returned by the view, then the drop disk operation is complete. If the drop disk operation is complete you cannot run the undrop disks command. For more information, see Chapter 1, “Using Oracle ASM.”
3.C. The disk group will be automatically rebalanced during a drop (or add) disk operation. Once the rebalancing is complete then the disk is dropped. For more information, see Chapter 1, “Using Oracle ASM.”
4.E. DG_DROP_TIME is not a valid configuration attribute for a disk group. For more information, see Chapter 1, “Using Oracle ASM.”
5.C. The ARCH process starts up when the database is in ARCHIVELOG mode. It is responsible for moving the online redo logs to the various archived redo log destination directories. For more information, see Chapter 2, “Performing Oracle User-Managed Backups.”
6.E. Since the database is in NOARCHIVELOG mode, the entire plan will not work since you can not perform hot backups in NOARCHIVELOG mode. If the database was in ARCHIVELOG mode, then you would choose option B. For more information, see Chapter 2, “Performing Oracle User-Managed Backups.”
7.D. When a tablespace is in hot backup mode, the related datafile headers are not updated. The headers will be updated after the tablespaces are taken out of hot backup mode. For more information, see Chapter 2, “Performing Oracle User-Managed Backups.”
8.E. When you issue the alter database backup controlfile to ‘directory/filename’, Oracle will write the backup control file to the directory and filename that you choose. For more information, see Chapter 2, “Performing Oracle User-Managed Backups.”
9.C. Use the alter database clear logfile command to clear the log file and free up the database. If the log file has not been archived, you may have to use the alter database clear unarchived logfile command instead. For more information, please see Chapter 3, “Performing Oracle User-Managed Database Recoveries.”
10.B. You will have to startup mount the database and then restore the database datafiles that were lost (you could, of course, restore the files first). You then need to recover the datafiles with the recover datafile command. Once the datafiles are recovered, you can then open the database. You may wonder why online recovery is not possible in this case. Datafile 1 is always the SYSTEM tablespace. The database cannot be opened if the SYSTEM tablespace is not available. Also the use of the recover database command is not the best choice in this case. Oracle always wants you to answer the question that is the best choice. In this case, datafile recovery is the better choice. For more information, please see Chapter 3, “Performing Oracle User-Managed Database Recoveries.”
xlvi Answers to Assessment Test
11.C. The alter database open resetlogs command is used to open an Oracle database after an incomplete recovery. For more information, please see Chapter 3, “Performing Oracle User-Managed Database Recoveries.”
12.E. The database is not recoverable. You would need all the archived redo logs generated during the backup on Tuesday, at least, to restore the database after that backup. The online redo logs are very unlikely to have all the redo that would be required. For more information, please see Chapter 3, “Performing Oracle User-Managed Database Recoveries.”
13.C, D. RMAN will not back up online redo logs or database parameter files. RMAN will back up database server parameter files (spfiles) however. For more information, see Chapter 4, “Configuring and Backing Up Using RMAN.”
14.B. RMAN backup set pieces within the same backup set can contain data from a given datafile. For more information see Chapter 4, “Configuring and Backing Up Using RMAN.”
15.C. Use the alter database enable block change tracking using file command, followed by the path and filename in single quotes, to create the block change tracking file. For more information, see Chapter 4, “Configuring and Backing Up Using RMAN.”
16.C. You would use the backup as compressed backupset database plus archivelog all command to back up your database. Of course, the command is so long-winded that the war would be over by the time you finished typing it all in. For more information, see Chapter 4, “Configuring and Backing Up Using RMAN.”
17.B, C, D. The RMAN recovery catalog provides a centralized location for all RMANrelated metadata. Thus it makes centralized reporting much easier. Additionally, you can store scripts in the recovery catalog for use across all databases that use RMAN. For more information, see Chapter 5, “Using the RMAN Recovery Catalog.”
18.B. The RMAN virtual private catalog provides the ability to allow users granular access to RMAN recovery catalog records based on database name. Thus, specific users can see only records they are allowed to see. For more information, see Chapter 5, “Using the RMAN Recovery Catalog.”
19.A. You can back up any database without connecting to the recovery catalog, including the recovery catalog database. In fact, you can back up the recovery catalog database while connected to the recovery catalog. For more information, see Chapter 5, “Using the RMAN Recovery Catalog.”
20.E. The register database command is used to indicate that the target database should be registered in the recovery catalog. For more information, see Chapter 5, “Using the RMAN Recovery Catalog.”
21.C. You would first need to start the database with the startup nomount command from the RMAN prompt. Then you restore the spfile using the restore spfile from autobackup command. For more information, see Chapter 6, “Recovering Databases with RMAN.”
Answers to Assessment Test |
xlvii |
22.C. You would first need to restore the database to the correct point in time with the restore database command. You would include the until time parameter to indicate what point in time you want to restore to. You then recover the database with the recover database command, which will apply the appropriate incremental backups and archived redo logs. Again, you use the until time command to indicate the time to recover to. Finally, you would open the database with the alter database open resetlogs command. For more information, see Chapter 6, “Recovering Databases with RMAN.”
23.A. The until change option of the restore command provides the ability to restore the database to a specific SCN. For more information, see Chapter 6, “Recovering Databases with RMAN.”
24.B, C, D, E. The recover command will recover the needed incremental backup and archived redo logs from backup sets for recovery purposes. The recover command will then apply the incremental backups and archived redo logs as needed to recover the database. For more information, see Chapter 6, “Recovering Databases with RMAN.”
25.B. An obsolete backup set is one that has exceeded the retention criteria. As a result, it is subject to automatic removal in the flash recovery area. For more information, see Chapter 7, “Reporting, Monitoring, and Tuning with RMAN.”
26.C. An expired backup is one that is missing one or more physical backup set pieces. The list expired backup command lists these types of backups. For more information, see Chapter 7, “Reporting, Monitoring, and Tuning with RMAN.”
27.C. The catalog command is used to catalog backup set pieces or image copies in both the control file and the recovery catalog so RMAN can use those backup set pieces or image copies. For more information, see Chapter 7, “Reporting, Monitoring, and Tuning with RMAN.”
28.D. There is no report user command. For more information, see Chapter 7, “Reporting, Monitoring, and Tuning with RMAN.”
29.A, D. Active database duplication takes place using network connections between the target database and the auxiliary database instance. Backup-based duplication requires that the RMAN backup set pieces be available on the server where the duplicate database will be created. For more information, see Chapter 8, “Performing Oracle Advanced Recovery.”
30.A, B. The SYSTEM and UNDO tablespaces will always be restored during a tablespace point-in- time recovery operation. For more information, see Chapter 8, “Performing Oracle Advanced Recovery.”
31.A, B. Database duplication (either backup-based or active) requires that you create the parameter files for the auxiliary database instance and have the auxiliary database instance started in NOMOUNT mode. For more information, see Chapter 8, “Performing Oracle Advanced Recovery.”
32.A. You use the recover tablespace command to perform a tablespace point-in-time recovery. For more information, see Chapter 8, “Performing Oracle Advanced Recovery.”
xlviii Answers to Assessment Test
33.E. Only the Flashback Table option recovers a table to a previous point in time. The other options allow viewing of past states of the data (B, C, D) or restoration from the Recycle Bin (A), but they do not recover a table to a previous point in time. For more information, see Chapter 9, “Understanding Flashback Technology.”
34.D. A Flashback Drop option would allow you to restore the table from the Recycle Bin. Although A, B, and C may all be valid recovery options, they are much less desirable than Flashback Drop. E is an invalid option altogether. For more information, see Chapter 9, “Understanding Flashback Technology.”
35.A, C, D. Shared server requests and remote DESCRIBE and COMMIT operations are not captured in a workload. For more information, see Chapter 10, “Diagnosing the Database and Managing Performance.”
36.B, C. Option A is incorrect because a gap in archive logs does not automatically end the recovery. RMAN will search forward for uncorrupted newer blocks; if RMAN finds one, it will continue with the restore and recovery operation. RMAN will check the flashback logs for uncorrupted copies of the block before it checks the backups. Option D is incorrect because the database must be in ARCHIVELOG mode. For more information, see Chapter 10, “Diagnosing the Database and Managing Performance.”
37.E. A good starting point is to use approximately 20 percent of the available memory for the PGA and approximately 80 percent for the SGA. For more information, see Chapter 11, “Managing Database Resources.”
38.B. Since you’re running short on time, extend the time-out for the session that’s in jeopardy and fix the space problem. Don’t put the transaction at risk while you try to find free space and run the commands, and don’t kill the transaction—unless you know that the space condition and extended suspend has caused other issues. For more information, see Chapter 11, “Managing Database Resources.”
39.E. A schedule is enabled by default. The others are disabled by default. For more information, see Chapter 12, “Using the Scheduler to Automate Tasks.”
40.C. Since we’ve established that the RAC is not performance constrained, option A is not valid—if the resource group were not able to obtain adequate CPU, this might be a valid answer. Option B is not correct because service affinity guarantees that if one instance in the service is available, the Scheduler will attempt to use it to run the job. If there is no service or instance affinity, the Scheduler will attempt to balance the load across surviving nodes. For more information, see Chapter 12, “Using the Scheduler to Automate Tasks.”
41.F. The NLS_LANGUAGE parameter specifies the default sorting sequence for character data. For more information, see Chapter 13, “Implementing Globalization Support.”
42.A, B, C. The NLS_TERRITORY parameter specifies conventions for local currency symbol, ISO currency symbol, dual currency symbol, credit/debit symbols, ISO week flag, and the list separator. Option D is incorrect because the default first day of the week is specified; the first day of the month is the 1st, not a specific day of the week. For more information, see Chapter 13, “Implementing Globalization Support.”
Chapter
1
Using Oracle ASM
Oracle Database 11g: Administration II exam objectives covered in this chapter:
ÛÛDatabase Architecture and ASM
NN Describe Automatic Storage Management (ASM)
NNSet up initialization parameter files for ASM and database instances
NN Start up and shut down ASM instances
NN Administer ASM diskgroups