QUESTION NO: 390
Which of these are valid Flashback Database recovery point parameters? (Choose all that apply.)
A. SCN
B. Timestamp
C. Named recovery point
D. Transaction ID
E. Session ID
【题目示意】
此题考查有关于Flashback Database recovery point的相关知识。
【解析】
在闪回整个数据库的时候,指定一个过去的时间点,SCN,或者日志序列号。
【实验】
1)启用数据库闪回功能:
SYS@ENMOEDU > startup mount;
ORACLE instance started.
Total System Global Area 422670336 bytes
Fixed Size 1345380 bytes
Variable Size 306186396 bytes
Database Buffers 109051904 bytes
Redo Buffers 6086656 bytes
Database mounted.
SYS@ENMOEDU > alter database flashback on;
SYS@ENMOEDU > select FLASHBACK_ON from v$database;
FLASHBACK_ON
------------------
YES
2)基于时间点的数据库闪回
SYS@ENMOEDU > select count(*) from t1;
COUNT(*)
----------
72152
SYS@ENMOEDU > select to_char(sysdate,'yyyy-mm-dd hh24:mi:ss') tm from dual;
TM
-------------------
2014-02-01 20:19:09
SYS@ENMOEDU > drop table t1;
Table dropped.
SYS@ENMOEDU > shutdown
Database closed.
Database dismounted.
ORACLE instance shut down.
SYS@ENMOEDU > startup mount;
ORACLE instance started.
Total System Global Area 422670336 bytes
Fixed Size 1345380 bytes
Variable Size 306186396 bytes
Database Buffers 109051904 bytes
Redo Buffers 6086656 bytes
Database mounted.
SYS@ENMOEDU > flashback database to timestamp to_timestamp('2014-02-01 20:19:09','yyyy-mm-dd hh24:mi:ss');
Flashback complete.
SYS@ENMOEDU > alter database open read only;
SYS@ENMOEDU > shutdown
SYS@ENMOEDU > startup mount;
SYS@ENMOEDU > alter database open resetlogs;
Database altered.
SYS@ENMOEDU > select count(*) from t1;
COUNT(*)
----------
72152
3)基于SCN的闪回:
SYS@ENMOEDU > select count(*) from t1;
COUNT(*)
----------
72152
SYS@ENMOEDU > select current_scn from v$database;
CURRENT_SCN
-----------
915934
SYS@ENMOEDU > drop table t1;
Table dropped.
SYS@ENMOEDU > shutdown;
Database closed.
Database dismounted.
ORACLE instance shut down.
SYS@ENMOEDU > startup mount;
ORACLE instance started.
Total System Global Area 422670336 bytes
Fixed Size 1345380 bytes
Variable Size 310380700 bytes
Database Buffers 104857600 bytes
Redo Buffers 6086656 bytes
Database mounted.
SYS@ENMOEDU > flashback database to scn 915934;
Flashback complete.
SYS@ENMOEDU > alter database open read only;
SYS@ENMOEDU > shutdown
SYS@ENMOEDU > startup mount;
SYS@ENMOEDU > alter database open resetlogs;
Database altered.
SYS@ENMOEDU > select count(*) from t1;
COUNT(*)
----------
72152
4)基于时点的闪回
SYS@ENMOEDU > select count(*) from t1;
COUNT(*)
----------
72152
SYS@ENMOEDU > create restore point before_changes;
Restore point created.
SYS@ENMOEDU > drop table t1;
Table dropped.
SYS@ENMOEDU > shutdown
Database closed.
Database dismounted.
ORACLE instance shut down.
SYS@ENMOEDU > startup mount
ORACLE instance started.
Total System Global Area 422670336 bytes
Fixed Size 1345380 bytes
Variable Size 310380700 bytes
Database Buffers 104857600 bytes
Redo Buffers 6086656 bytes
Database mounted.
SYS@ENMOEDU > flashback database to restore point before_changes;
Flashback complete.
SYS@ENMOEDU > alter database open read only;
SYS@ENMOEDU > shutdown
SYS@ENMOEDU > startup mount;
SYS@ENMOEDU > alter database open resetlogs;
Database altered.
SYS@ENMOEDU > select count(*) from t1;
COUNT(*)
----------
72152
【小结】
所以闪回过去的时间点可以有SCN,Timestamp,Named recovery point三个参数决定。因此选择ABC
【答案】 ABC
相关参考
file:///D:/oracle/11g手册_01/backup.112/e10642/rcmquick.htm#BABBHDFJ
The end
DB_SUN
2014.2.1
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/29435844/viewspace-1076844/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/29435844/viewspace-1076844/