Top 28 Database Backup Recovery Interview Questions You Must Prepare 24.Jun.2024

Q1. Why We Should Need To Open Database Using Resetlogs After Finishing Incomplete Recovery?

When we are performing incomplete recovery it me we bring database to past time or rewind period of time using change based, cancel based or time based recovery. These all recovery make database in prior state of database. The forward sequence number already available after performing recovery, due to mismatching of this sequence numbers and prior state of database, it needs to open database with new sequence number of Redo log and archive logs.

Q2. I Am Working As Oracle Dba In 24/7 Running Large Production Database. Size Of Database Is Around 800 Gb. We Take Hot Backup Every Day Night. But One Day At Around 4:00 Pm, By Mistake One Table Is Drop

If your database is running on Oracle 10g/11g/12c version then there is new feature available called Recycle bin. You can recover dropped table from user_recyclebin or dba_recyclebin.

Q3. Have You Faced Any Recovery Scenario? Explain How You Resolved It?

2 months back, a potential table was dropped by an application developer on our large 24/7 running production database. Immediately he informed us. We have standby database for our production database. We checked that archives didn’t apply to standby database up to dropped timing. We stopped archive applying on standby immediately and open database read only. Took export of dropped table and imported in production database. After finishing appropriate checking of table, again we started archive applying in standby database for refreshing.

Q4. What Are The Steps Involved In Instance Recovery?

  • Rolling forward to recover data that has not been recorded in data files yet has been recorded in the on-line redo log, including the contents of rollback segments.
  • Rolling back tractions that have been explicitly rolled back or have not been committed as indicated by the rollback segments regenerated in step a.
  • Releasing any resources (locks) held by tractions in process at the time of the failure.
  • Resolving any pending distributed tractions undergoing a two-phase commit at the time of the instance failure.

Q5. Archive Logs Are Being Generated Around 20gb In My Production Large Database. But One Day Almost Double Archives Were Generated. What Is The Reason Behind This? How Can I Check It?

There are lots of reason behind increasing size of archives like If more database changes were performed using batch jobs or any special task like merging 2 database or data etc. You can investigate exact root cause using enabling Log Minor utility.

Q6. Does Incremental Checkpoint Recorded In Alert.log? How To Disable It?

We can enable disable recording incremental checkpoint in alert.log .We can enable/disable recording using parameter log_checkpoints_to_alert=true/false.

Q7. What Are The Different Modes Of Mounting A Database With The Parallel Server?

Exclusive Mode If the first instance that mounts a database does so in exclusive mode, only that Instance can mount the database.

Parallel Mode if the first instance that mounts a database is started in parallel mode, other instances that are started in parallel mode can also mount the database.

Q8. What Is Partial Backup?

A Partial Backup is any operating system backup short of a full backup, taken while the database is open or shut down.

Q9. What Is Restricted Mode Of Instance Startup?

An instance can be started in (or later altered to be in) restricted mode so that when the database is open connections are limited only to those whose user accounts have been granted the RESTRICTED SESSION system privilege.

Q10. In Continuation Above Scenario, Why I Should Need To Perform Recovery In Uat And Test Database Server? Can I Restore Backup In Production Database Server Too?

Yes. You can. It is not recommended because your production database is large database and running 24/7 environment. Restoration and recovery will take downtime. It is better to perform restoration and recovery process on UAT or Test database.

Q11. Which Command I Should Need To Execute To Back Up Database Which Is Running On Noarchivelog Mode?

Shutdown immediate. Because without shutdown, we can't perform online backup of database, which running on NOARCHIVELOG mode. We should need to take cold backup of database. After clean shutdown database copy of all datafiles, control files, redo log files, password file, and parameter files.

Q12. What Is On-line Redo Log?

The On-line Redo Log is a set of two or more on-line redo files that record all committed changes made to the database. Whenever a traction is committed, the corresponding redo entries temporarily stores in redo log buffers of the SGA are written to an on-line redo log file by the background process LGWR. The on-line redo log files are used in cyclical fashion.

Q13. What Is Log Switch?

The point at which ORACLE ends writing to one online redo log file and begins writing to another is called a log switch.

Q14. Can Full Backup Be Performed When The Database Is Open?


Q15. In Continuation Of Above Scenario, Recycle Bin Doesn't Enable In My Database Then How To Recover My Table? How To Disable It?

Then you should need to restore backup on your UAT or test database server and enable time based recovery for applying all archives before drop command execution. For an instance, apply archives up to 3:55 PM here.

Q16. What Is Incremental Checkpoint?

In incremental checkpoint process, CKPT process records lowest Low RBA to the control file to keep advancing the Buffer checkpoint Queue (BCQ) to make easy and fastest Active Checkpoint Queue (ACQ).

Q17. What Is Archived Redo Log?

Archived Redo Log consists of Redo Log files that have achieved before being reused.

Q18. What Is Full Backup?

A full backup is an operating system backup of all data files, on-line redo log files and control file that constitute ORACLE database and the parameter.

Q19. What Are The Advantages Of Operating A Database In Archivelog Mode Over Operating It In No Archivelog Mode?

Complete database recovery from disk failure is possible only in ARCHIVELOG mode.

Online database backup is possible only in ARCHIVELOG mode.

Q20. What Are The Steps Involved In Database Shutdown?

Close the Database; Dismount the Database and Shutdown the Instance.

Q21. One Of My Control File Corrupted And I Am Unable To Start Database. Could You Tell Me How To Perform Recovery?

If one of your control file is missing or corrupted then we have 2 options to recover it. Check alert.log for exact name and location of corrupted control file. Delete it manually and copy from available rest of control file and rename it and start database. Another option is delete corrupted control file and remove name from parameter file/ spfile. After removing said control file from spfile, start your database.

Q22. What Is Mirrored On-line Redo Log?

A mirrored on-line redo log consists of copies of on-line redo log files physically located on separate disks; changes made to one member of the group are made to all members.

Q23. Why Export/data Pump Backup Called As Logical Backup?

Export and datapump dump file doesn't backup or contain any physical structure of database like datafile, control file, redo log file, parameter file, password file. Instead of physical structure, export dump contains logical structure of database like definition of tablespaces, segments, schemas, data of segments etc. Due to these reasons export and datapump dump is called as logical backup.

Q24. What Are The Steps Involved In Database Startup?

Start an instance, Mount the Database and Open the Database.

Q25. How Can I Know My Require Table Is Available In Export Dump File?

Create index file of export dump file using import with index file command. A text file will be generating with all table and index object name with number of rows. You can confirm your require table object from this text file. If you are using datapump then there is parameter called "sqlfile" in impdp.

Q26. What Is The Complete Recovery?

During this recovery we are applying all database changes using archives log and make it to up to date. Complete recovery can be done full database level or datafile level or tablespace level. Main concept is to apply all data changes using archive logs and bring database up to recent time.

Q27. What Is The Meaning Of Lgwr Sync And Lgwr Async In Log Archive Destination Parameter Of Standby Configuration?

When use LGWR with SYNC, it me once network I/O initiated, LGWR has to wait for completion of network I/O before write processing. LGWR with ASYNC me LGWR doesn’t wait to finish network I/O and continuing write processing.

Q28. How Do You Recover From The Loss Of Data File If Database Is Running In Archive Log Mode?

We can perform this recovery in 2 ways. One is open database mode and another is database mount mode. After taking offline lost datafile, we can bring database open and after that restore lost datafile from last backup. After restoration of datafile we can perform datafile level recovery for applying archive logs and make it online. In database mount mode, we can restore datafile from backup and perform datafile recovery using "Recover datafile" command.