文章详情

短信预约-IT技能 免费直播动态提醒

请输入下面的图形验证码

提交验证

短信预约提醒成功

12c Oracle 定期验证备份文件

2024-04-02 19:55

关注

数据库备份大家都知道,正常也会每天都定时备份,但是很少有人去做备份文件的验证。一旦,我们需要使用备份文件,备份文件确实损坏的那就悲催了。定期每个月做一次备份验证是必要的。

RMAN> restore database validate;

Starting restore at 12-JAN-2018 21:49:31
using channel ORA_DISK_1

channel ORA_DISK_1: starting validation of datafile backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/db_fullbk_19_1_965249636.rmn
channel ORA_DISK_1: piece handle=/u01/bak/db_fullbk_19_1_965249636.rmn tag=BACKUP_FULL
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
channel ORA_DISK_1: starting validation of datafile backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/db_fullbk_18_1_965249636.rmn
channel ORA_DISK_1: piece handle=/u01/bak/db_fullbk_18_1_965249636.rmn tag=BACKUP_FULL
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:35
channel ORA_DISK_1: starting validation of datafile backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/db_fullbk_17_1_965249636.rmn
channel ORA_DISK_1: piece handle=/u01/bak/db_fullbk_17_1_965249636.rmn tag=BACKUP_FULL
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:55
Finished restore at 12-JAN-2018 21:51:02

RMAN> 

RMAN> restore archivelog from time 'sysdate-1' validate;

Starting restore at 12-JAN-2018 21:59:39
using channel ORA_DISK_1

channel ORA_DISK_1: starting validation of archived log backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/archive_24_1_965249706.arc
channel ORA_DISK_1: piece handle=/u01/bak/archive_24_1_965249706.arc tag=TAG20180112T205505
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
channel ORA_DISK_1: starting validation of archived log backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/archive_22_1_965249706.arc
channel ORA_DISK_1: piece handle=/u01/bak/archive_22_1_965249706.arc tag=TAG20180112T205505
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:03
channel ORA_DISK_1: starting validation of archived log backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/archive_23_1_965249706.arc
channel ORA_DISK_1: piece handle=/u01/bak/archive_23_1_965249706.arc tag=TAG20180112T205505
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:03
channel ORA_DISK_1: starting validation of archived log backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/archive_21_1_965249706.arc
channel ORA_DISK_1: piece handle=/u01/bak/archive_21_1_965249706.arc tag=TAG20180112T205505
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:03
channel ORA_DISK_1: starting validation of archived log backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/archive_25_1_965249717.arc
channel ORA_DISK_1: piece handle=/u01/bak/archive_25_1_965249717.arc tag=TAG20180112T205505
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
channel ORA_DISK_1: starting validation of archived log backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/archive_35_1_965253442.arc
channel ORA_DISK_1: piece handle=/u01/bak/archive_35_1_965253442.arc tag=TAG20180112T215722
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:00
channel ORA_DISK_1: starting validation of archived log backup set
channel ORA_DISK_1: reading from backup piece /u01/bak/archive_34_1_965253442.arc
channel ORA_DISK_1: piece handle=/u01/bak/archive_34_1_965253442.arc tag=TAG20180112T215722
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:00
Finished restore at 12-JAN-2018 21:59:50

RMAN> restore controlfile validate;

Starting restore at 12-JAN-2018 21:54:47
using channel ORA_DISK_1

channel ORA_DISK_1: starting validation of datafile backup set
channel ORA_DISK_1: reading from backup piece +DATADG/ORCL/AUTOBACKUP/2018_01_12/s_965249725.381.965249727
channel ORA_DISK_1: piece handle=+DATADG/ORCL/AUTOBACKUP/2018_01_12/s_965249725.381.965249727 tag=TAG20180112T205525
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
Finished restore at 12-JAN-2018 21:54:48

RMAN> restore spfile validate;

Starting restore at 12-JAN-2018 21:54:57
using channel ORA_DISK_1

channel ORA_DISK_1: starting validation of datafile backup set
channel ORA_DISK_1: reading from backup piece +DATADG/ORCL/AUTOBACKUP/2018_01_12/s_965249725.381.965249727
channel ORA_DISK_1: piece handle=+DATADG/ORCL/AUTOBACKUP/2018_01_12/s_965249725.381.965249727 tag=TAG20180112T205525
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
Finished restore at 12-JAN-2018 21:54:58

RMAN> 
阅读原文内容投诉

免责声明:

① 本站未注明“稿件来源”的信息均来自网络整理。其文字、图片和音视频稿件的所属权归原作者所有。本站收集整理出于非商业性的教育和科研之目的,并不意味着本站赞同其观点或证实其内容的真实性。仅作为临时的测试数据,供内部测试之用。本站并未授权任何人以任何方式主动获取本站任何信息。

② 本站未注明“稿件来源”的临时测试数据将在测试完成后最终做删除处理。有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341

软考中级精品资料免费领

  • 历年真题答案解析
  • 备考技巧名师总结
  • 高频考点精准押题
  • 2024年上半年信息系统项目管理师第二批次真题及答案解析(完整版)

    难度     813人已做
    查看
  • 【考后总结】2024年5月26日信息系统项目管理师第2批次考情分析

    难度     354人已做
    查看
  • 【考后总结】2024年5月25日信息系统项目管理师第1批次考情分析

    难度     318人已做
    查看
  • 2024年上半年软考高项第一、二批次真题考点汇总(完整版)

    难度     435人已做
    查看
  • 2024年上半年系统架构设计师考试综合知识真题

    难度     224人已做
    查看

相关文章

发现更多好内容

猜你喜欢

AI推送时光机
位置:首页-资讯-数据库
咦!没有更多了?去看看其它编程学习网 内容吧
首页课程
资料下载
问答资讯