May 9, 2010
Continuing the true or false blog article series with more questions that seem to have conflicting answers, if the answers to those questions depend on the source of the information found through Internet searches. Today’s quiz is on the topic of Oracle Database’s undo functionality, and in some cases you may need to consult several of the suggested articles in order to correctly answer each of the questions.
When answering the questions, answer True or False, followed by a justification for the answer that you provided. Yes, there are a lot of questions, but part of the entertainment in these types of exercises is reading an article and identifying what is logically right or wrong. Of course, as with the previous quizzes, any answers that attempt to utilize logical fallacies will be scored as incorrect.
- Expert Oracle Database 11g Administration
- Expert Oracle Database Architecture: 9i and 10g Programming Techniques and Solutions
- Documentation Link #1 (11.2.0.x)
- Documentation Link #2 (11.2.0.x)
- Documentation Link #3 (11.2.0.x)
- Documentation Link #4 (10.2.0.x)
1. Rollback segment shrinks cause the next session to use the rollback segment to wait while the rollback segment is reduced in size to its optimal size.
2. An OPTIMAL size for rollback segments should never be set because when the rollback segments are correctly sized, they should never increase in size.
3. The ideal rollback segment size is partially determined by the values of the DB_WRITER_PROCESSES, LOG_BUFFER, AND LOG_CHECKPOINT_INTERVAL initialization parameters, as well as the COMMIT frequency.
4. Large, long running batch jobs should be manually set to use a single, large rollback segment to reduce the risk of ORA-01555 (snapshot too old) errors.
5. Adding a large undo segment when manual undo management is in use will effectively reduce the chances of sessions receiving ORA-01555 (snapshot too old) errors.
6. When automatic undo management is used, ORA-01555 (snapshot too old) errors are triggered by Oracle Database creating many small undo segments in an undo tablespace that is too small.
7. In a database with a single session connected, it is not possible to trigger an ORA-01555 (snapshot too old) error when the session is not modifying the tables that are being queried.
8. When manual undo management is in use, only UPDATE transactions are able to automatically cause an undo segment to grow; SELECT statements do not cause the undo segments to grow, thus increasing the risk of ORA-01555 (snapshot too old) errors when the undo segments are small.
9. When manual undo management is in use, it is a common practice for DBAs to assign a transaction to a specific rollback segment using the SET TRANSACTION command, but this is unnecessary with automatic undo management.
10. The automatically created undo segments in the SYSTEM tablespace will only be used when modifying objects residing in the SYSTEM tablespace.
11. The UNDO_TABLESPACE parameter must be set to an undo tablespace’s name when automatic undo management is used.
12. The V$WAITSTAT view includes a block class that indicates the number of waits on the system undo header blocks.
13. The SESSIONS parameter should be set to a value no larger than the expected maximum number of user sessions since the SESSIONS parameter affects the number of undo segments created when automatic undo management is used.
14. When automatic undo management is used, as the number of sessions connected to the database instance increases, the instance dynamically adds additional (offline) undo segments in response to the sessions merely connecting. The TRANSACTIONS_PER_ROLLBACK_SEGMENT parameter determines the number of additional sessions that must be connected before an additional undo segment is added.
15. SELECT type SQL statements do not generate redo nor undo.
16. In most databases, DML or DDL is performed in only 10% of all transactions in the database.
17. After a session changes data and issues a COMMIT, all sessions with access permissions to view the data are able to immediately see those changes.
18. Read consistency in Oracle means that data included in the query results will always be as of the moment the query was submitted.
19. Undo segments may be used to support flashback type operations.
20. The redo logs contain undo records, which allows Oracle Database to optimize the process of recovering from a shutdown abort, and also means that a future release of Oracle Database will no longer need dedicated undo tablespaces.
Note that a new blog article category has been added to quickly locate the quiz articles. When attempting to answer the true or false questions, think about under what conditions the answer to the question will be true and under what conditions the answer to the question must be false.