Databases Reference
In-Depth Information
Oracle flashback drop (uses the recycle bin) : This relies on the concept of a recycle bin and
lets you restore a dropped table. When you accidentally drop a table with the drop table
statement, information about the purged table is saved in the recycle bin (which is actually
a data dictionary table) under a system-assigned name. Actually, the table's contents
remain intact and in place, but the data dictionary marks the table as having been dropped.
You can then “undrop” the table at a later time by using the flashback table … to before
drop statement, which recovers the dropped object from the recycle bin. The flashback
table feature relies entirely on the recycle bin concept.
The flashback data archive capability lets you use the previously described flashback features to access data from a
period of time that's as old as you want. By using a flashback data archive, you overcome the limitation of a short undo
retention time in the undo tablespace.
Oracle's flashback database feature serves as an alternative to traditional database point-in-time recovery. You use
this feature to undo changes made by logical data corruption or by user errors. The essential point to understand here
is that the opposite of flashback is to recover . In normal database recovery, you update the backups by applying logs
forward. In flashback, you rewind the database by applying flashback logs backward. Thus, in most cases, a flashback
database operation will take much less time than it takes to restore and recover during the traditional alternative,
which is a database point-in-time recovery. The flashback database feature takes the database back in time, essentially
rewinding it to a past point in time by undoing all changes made to the database since that time. Unlike traditional
point-in-time recovery, you don't have to perform a media recovery by restoring backups. You simply use the flashback
logs (stored in the fast recovery area) to access older versions of the changed data blocks. In addition, the database
makes use of the archived redo logs as well.
the flashback database feature is useless in dealing with cases of lost data files or damaged media. you can
use this feature to undo the changes made to an oracle database's data files only by reverting the contents of the data
files to a previous point in time.
Note
When you enable flashback logging so that you can use the flashback database feature, you may not always be
able to return to a specific point in time, if the flashback logs for that period aren't available. Oracle's guaranteed
restore points feature lets you specify a system change number (SCN) to which you can always restore the database.
That is, the database will ensure that the flashback logs from the specific SCN on are saved, no matter what. Thus,
guaranteed restore points, which are an adjunct to the flashback database feature, let you ensure that you'll at least be
able to recover until the specified SCN, even if you aren't necessarily able to recover up to the current SCN.
Backup Types
When we talk about a database backup, your first thought might be that it is simply a copy of all the database
physical files. However, an Oracle database offers several types of backups. We summarize the main types in the
following sections.
Physical and Logical Backups
When you make a copy of a database file using an operating system utility, such as cp , you are making an actual
physical copy of the database file. You can use this file to restore the database contents if you happen to lose the disk
containing that file. Physical backups are simply physical copies of the files used by the database, such as data files,
redo logs, and control files. However, making exact physical copies of the database file isn't the only way to copy the
contents of an Oracle database. You can also make a logical backup by using Oracle's Data Pump Export tool, wherein
you copy the definitions and contents of all of the database's logical components, such as tables and so on. You can
 
 
Search WWH ::




Custom Search