Oracle Backup and Recovery - August 28, 2008 at 17:10 pm by Amit
Satpute
What is configure command and recovery catalog?
A recovery catalog is a schema stored in a database. It tracks backups and
stores scripts for use in RMAN backup and recovery situations.
Configure command used in RMAN,is used to configure the parameters for the RMAN
database.
It is used while making backups and recoveries.
What are different types of backup? (Hot, Cold, logical, Physical) Explain in
detail.
Cold Backup
In this type of backup, after the database is shut down, DBA exits the
SVRMGR utility and copies the log files, data files and control files onto a
backup media.Once the backup has been completed the DBA can restart the
database.
Physical Backup
The operating system saves the database files onto tape or some other media.
This is useful to restire the system to an earlier point whenever needed.
Logical Backup
In logical backup technique, the IMPORT/EXPORT utilities are used to
create the backup of the database. A logical backup backs-up the contents of
the database. A logical backup can be used to restore the database to the last
backup. However, unlike physical back, it should not be used to create an OS
back up copy because restoring using this approach would make it possible to
correct the damaged datafiles. Therefoe in these situations physical backups
should be preferred.
Hot backup
A few systems that need to support continuous operation, it is
difficult to bring down the database without interrupting the service provided
to the users. In such cases, hot backup approach should be used.
There are two modes in which the hot backup works:
ARCHIEVELOG mode
NOARCHIVELOG mode
The database operations are suspended until archiving has been completed if the
on-line redo log files are filled before they can be archived.
It is important that the directory containing the archived log files doesnt
become full because if it does the ARCH thread wouldnt be able to archive the
redo log files. The DBA has to continuously monitor the used-space percentage
in the archive directory.
The database can be placed into ARCHIVELOG mode at the creation time or after
the database has been created.
However, the database is shutdown before connecting as the user INTERNAL.
It was originally created in NOARCHIVELOG mode, this technique can be used to
place the database in ARCHIVELOG mode.
Whats the Concept of Flashback Query in Oracle (10g in particular) and how is
it beneficial?
Due to human errors, valuable data gets deleted or misentered. Oracle Flashback
Technology provides a set of new features to view and undo the data back and
forth.
The benefits of flashback quering are:
- The capability of querying the historical data,
- perform change analysis, and
- perform self-service repair to recover from logical corruptions while the
database is online.
What is mean live lock and deadlock? How to prevent it?
A deadlock can occur when two or more processes that strive to acquire resources
are not able to acquire them due to some of the following reasons:
-
Two processes may be interdependent upon each other,
-
If there are more than 2 processes, then if a graph is plotted, then there
could be a cycle,
-
A server maintains a graph. The processes acquiring the resources would
intimate the server about their requirement. If the server detects an occurance
of a deadlock, the user process is be terminated.
In a livelock, a request for an exclusive lock is denied repeatedly due to a
series of overlapping shared locks that keep interfering.
An SQL Server detects this situation after four denials and then refuses further
shared locks.
When a write transaction is forced to wait indefinitely due to read transactions
that monopolize a table or a page then a live lock occurs.
What is Partial Backup?
A partial backup is similar to a full database backup, but a it does not contain
all the filegroups.
It contains all the data in the primary filegroup, every read/write filegroup,
and any optionally-specified read-only files.
What is Mirrored on-line Redo Log?
Due to Mirrored online redo logs and disk array mirroring, the occurrence of
redo log corruptions has dropped to practically zero. 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.
|