ITPub博客

首页 > 数据库 > Oracle > Oracle OCP 1Z0-053 Q513(how to perform tablespace point-in-time recovery)

Oracle OCP 1Z0-053 Q513(how to perform tablespace point-in-time recovery)

原创 Oracle 作者:abstractcyj 时间:2016-03-23 14:34:33 0 删除 编辑
513.What RMAN command is used to execute a tablespace point-in-time recovery?
A. recover
B. duplicate
C. restore
D. copy
E. None of the above
Answer: A

RMAN> recover tablespace users until time "TO_DATE('2016-03-23 14:30:00','yyyy-mm-dd hh24:mi:ss')" auxiliary destination '/home/oracle'; 


Starting recover at 23-MAR-16
using channel ORA_DISK_1
using channel ORA_DISK_2
RMAN-05026: WARNING: presuming following set of tablespaces applies to specified point-in-time


List of tablespaces expected to have UNDO segments
Tablespace SYSTEM
Tablespace UNDOTBS1


Creating automatic instance, with SID='ggiD'


initialization parameters used for automatic instance:
db_name=INST1
db_unique_name=ggiD_tspitr_INST1
compatible=11.2.0.4.0
db_block_size=8192
db_files=200
sga_target=1G
processes=80
db_create_file_dest=/home/oracle
log_archive_dest_1='location=/home/oracle'
#No auxiliary parameter file used




starting up automatic instance INST1


Oracle instance started


Total System Global Area    1068937216 bytes


Fixed Size                     2260088 bytes
Variable Size                281019272 bytes
Database Buffers             780140544 bytes
Redo Buffers                   5517312 bytes
Automatic instance created
Running TRANSPORT_SET_CHECK on recovery set tablespaces
TRANSPORT_SET_CHECK completed successfully


contents of Memory Script:
{
# set requested point in time
set until  time "TO_DATE('2016-03-23 14:30:00','yyyy-mm-dd hh24:mi:ss')";
# restore the controlfile
restore clone controlfile;
# mount the controlfile
sql clone 'alter database mount clone database';
# archive current online log 
sql 'alter system archive log current';
# avoid unnecessary autobackups for structural changes during TSPITR
sql 'begin dbms_backup_restore.AutoBackupFlag(FALSE); end;';
}
executing Memory Script


executing command: SET until clause


Starting restore at 23-MAR-16
allocated channel: ORA_AUX_DISK_1
channel ORA_AUX_DISK_1: SID=80 device type=DISK
allocated channel: ORA_AUX_DISK_2
channel ORA_AUX_DISK_2: SID=10 device type=DISK


channel ORA_AUX_DISK_1: starting datafile backup set restore
channel ORA_AUX_DISK_1: restoring control file
channel ORA_AUX_DISK_1: reading from backup piece /u01/app/oracle/product/11.2.0/dbhome_1/dbs/c-193461069-20160323-00
channel ORA_AUX_DISK_1: piece handle=/u01/app/oracle/product/11.2.0/dbhome_1/dbs/c-193461069-20160323-00 tag=TAG20160323T113313
channel ORA_AUX_DISK_1: restored backup piece 1
channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01
output file name=/home/oracle/INST1/controlfile/o1_mf_ch4gn3tq_.ctl
Finished restore at 23-MAR-16


sql statement: alter database mount clone database


sql statement: alter system archive log current


sql statement: begin dbms_backup_restore.AutoBackupFlag(FALSE); end;

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/8520577/viewspace-2062517/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论
曾从事java方向开发多年。近年已经转入数据库方向。主要擅长SQL优化,Oracle数据库问题诊断,Oracle备份与恢复等。服务于医药物流,医院等行业

注册时间:2010-01-26

  • 博文量
    602
  • 访问量
    1091635