Book Image

Oracle Database XE 11gR2 Jump Start Guide

By : Asif Momen
Book Image

Oracle Database XE 11gR2 Jump Start Guide

By: Asif Momen

Overview of this book

Oracle Database XE 11gR2 is an excellent beginner-level database and is a great platform to learn database concepts. "Oracle Database XE 11gR2 Jump Start Guide" helps you to install, administer, maintain, tune, back up and upgrade your Oracle Database Express Edition. The book also helps you to build custom database applications using Oracle Application Express.Using this book, you will be able to install Oracle Database XE on Windows/Linux operating system.This book helps you understand different database editions and it guides you through the installation procedure with the aid of screenshots. You will learn to interact with the database objects. You will gain a solid understanding of stored sub-programs which is followed by an introduction to Oracle Application Express (APEX). Solid database performance tuning strategies are also discussed in this book followed by backup and recovery scenarios. All in all, "Oracle Database XE 11gR2 Jump Start Guide" delivers everything that you should know to get started with Oracle Database administration.
Table of Contents (20 chapters)
Oracle Database XE 11gR2 Jump Start Guide
Credits
About the Author
Acknowledgement
About the Reviewers
www.PacktPub.com
Preface

Simulating a database failure (the ARCHIVELOG mode)


Now it's time to start playing with our database. We have recovered our database (NOARCHIVELOG) from a simulated database failure earlier in this chapter. We will repeat a similar approach with our database in the ARCHIVELOG mode.

For this test we will be performing the following steps to simulate a database failure:

  1. 1. Take a full database backup.

  2. 2. Insert a record in the hr_test table:

    SQL>INSERT into hr_test VALUES (6, 'test record', sysdate, 100);
    SQL> COMMIT;
    
  3. 3. Switch the archive logs:

    SQL> ALTER SYSTEM SWITCH LOGFILE;
    
  4. 4. Back up the archive logs:

    RMAN> backup archivelog all;
    
  5. 5. Shut down the database.

  6. 6. Rename the datafiles folder— ORADATA/XE to ORADATA/XE-ARCH-BACKUP.

  7. 7. Create a new empty folder— XE.

  8. 8. Start the database now. (Oracle instance starts up in NOMOUNT mode and fails to mount the database, as Oracle is not able to find controlfile while mounting the database.)