Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1062220
  • 博文数量: 239
  • 博客积分: 10
  • 博客等级: 民兵
  • 技术积分: 3618
  • 用 户 组: 普通用户
  • 注册时间: 2012-11-12 13:17
文章分类

全部博文(239)

文章存档

2021年(1)

2016年(1)

2015年(30)

2014年(91)

2013年(116)

分类: LINUX

2013-09-11 12:35:24

os版本:RHEL6.1
oracle版本:11.2.0.3.0
单机环境

利用rman测试时候:
由于在系统层面执行了删除操作,命令如下:
#cd /oradata/backup
#rm -rf bak_0aojh5d8_1_1
#rm -rf bak_0bojh5ft_1_1



RMAN> list backup;


List of Backup Sets
===================


BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
6       Full    979.57M    DISK        00:01:23     10-SEP-13      
        BP Key: 6   Status: AVAILABLE  Compressed: NO  Tag: TAG20130910T183832
        Piece Name: /oradata/backup/bak_0aojh5d8_1_1
  List of Datafiles in backup set 6
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  1       Full 1133254    10-SEP-13 /opt/oracle/oradata/portaldb/system01.dbf
  2       Full 1133254    10-SEP-13 /opt/oracle/oradata/portaldb/sysaux01.dbf
  3       Full 1133254    10-SEP-13 /opt/oracle/oradata/portaldb/undotbs01.dbf
  4       Full 1133254    10-SEP-13 /opt/oracle/oradata/portaldb/users01.dbf
  5       Full 1133254    10-SEP-13 /oradata/portaldb_ICMLFQ32_01.dbf
  6       Full 1133254    10-SEP-13 /oradata/portaldb_ICMLNF32_01.dbf
  7       Full 1133254    10-SEP-13 /oradata/portaldb_ICMSFQ04_01.dbf
  8       Full 1133254    10-SEP-13 /oradata/portaldb_ICMVFQ04_01.dbf
  9       Full 1133254    10-SEP-13 /oradata/portaldb_ICMLSNDX_01.dbf

BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
7       Full    9.36M      DISK        00:00:01     10-SEP-13      
        BP Key: 7   Status: AVAILABLE  Compressed: NO  Tag: TAG20130910T183832
        Piece Name: /oradata/backup/bak_0bojh5ft_1_1
  SPFILE Included: Modification time: 10-SEP-13
  SPFILE db_unique_name: PORTALDB
  Control File Included: Ckp SCN: 1133289      Ckp time: 10-SEP-13

RMAN> crosscheck backup;

using channel ORA_DISK_1
crosschecked backup piece: found to be 'EXPIRED'
backup piece handle=/oradata/backup/bak_0aojh5d8_1_1 RECID=6 STAMP=825791912
crosschecked backup piece: found to be 'EXPIRED'
backup piece handle=/oradata/backup/bak_0bojh5ft_1_1 RECID=7 STAMP=825791998
Crosschecked 2 objects


RMAN> delete expired backup;

using channel ORA_DISK_1

List of Backup Pieces
BP Key  BS Key  Pc# Cp# Status      Device Type Piece Name
------- ------- --- --- ----------- ----------- ----------
6       6       1   1   EXPIRED     DISK        /oradata/backup/bak_0aojh5d8_1_1
7       7       1   1   EXPIRED     DISK        /oradata/backup/bak_0bojh5ft_1_1

Do you really want to delete the above objects (enter YES or NO)? y
deleted backup piece
backup piece handle=/oradata/backup/bak_0aojh5d8_1_1 RECID=6 STAMP=825791912
deleted backup piece
backup piece handle=/oradata/backup/bak_0bojh5ft_1_1 RECID=7 STAMP=825791998
Deleted 2 EXPIRED objects


RMAN> list backup;

specification does not match any backup in the repository


利用crosscheck命令检测备份或归档物理文件的状态,如果物理文件存在,并且控制文件中有匹配记录,则标记该对象为available,如果不存在,则标记为expired(无效)
阅读(9076) | 评论(0) | 转发(0) |
1

上一篇:利用rman备份oracle控制文件

下一篇:linux ntp

给主人留下些什么吧!~~