- 论坛徽章:
- 0
|
5可用积分
我用的脚本是:
$RMAN target $TARGET_CONNECT_STR nocatalog msglog $RMAN_LOG_FILE append << EOF
RUN {
ALLOCATE CHANNEL ch00 TYPE 'SBT_TAPE';
#ALLOCATE CHANNEL ch01 TYPE 'SBT_TAPE';
BACKUP
$BACKUP_TYPE
SKIP INACCESSIBLE
TAG hot_db_bk_level0
FILESPERSET 5
# recommended format
FORMAT 'bk_%s_%p_%t'
DATABASE;
sql 'alter system archive log current';
RELEASE CHANNEL ch00;
#RELEASE CHANNEL ch01;
# backup all archive logs
ALLOCATE CHANNEL ch00 TYPE 'SBT_TAPE';
#ALLOCATE CHANNEL ch01 TYPE 'SBT_TAPE';
BACKUP
filesperset 20
FORMAT 'al_%s_%p_%t'
ARCHIVELOG ALL DELETE INPUT;
RELEASE CHANNEL ch00;
#RELEASE CHANNEL ch01;
-----------------------------以下为out文件的信息----------------------------
Starting backup at 13-APR-09
current log archived
channel ch00: starting archive log backupset
channel ch00: specifying archive log(s) in backup set
input archive log thread=1 sequence=40935 recid=1040 stamp=684061058
input archive log thread=1 sequence=40936 recid=1039 stamp=684061057
input archive log thread=1 sequence=40937 recid=1041 stamp=684061063
input archive log thread=1 sequence=40938 recid=1042 stamp=684061075
input archive log thread=1 sequence=40939 recid=1043 stamp=684061198
input archive log thread=1 sequence=40940 recid=1044 stamp=684061233
input archive log thread=1 sequence=40941 recid=1045 stamp=684061246
input archive log thread=1 sequence=40942 recid=1046 stamp=684061268
input archive log thread=1 sequence=40943 recid=1047 stamp=684061300
input archive log thread=1 sequence=40944 recid=1048 stamp=684061316
input archive log thread=1 sequence=40945 recid=1049 stamp=684061534
input archive log thread=1 sequence=40946 recid=1050 stamp=684061605
input archive log thread=1 sequence=40947 recid=1051 stamp=684061647
input archive log thread=1 sequence=40948 recid=1052 stamp=684061706
input archive log thread=1 sequence=40949 recid=1053 stamp=684061766
input archive log thread=1 sequence=40950 recid=1054 stamp=684061881
input archive log thread=1 sequence=40951 recid=1055 stamp=684061927
input archive log thread=1 sequence=40952 recid=1056 stamp=684061947
input archive log thread=1 sequence=40953 recid=1057 stamp=684061964
input archive log thread=1 sequence=40954 recid=1058 stamp=684061993
channel ch00: starting piece 1 at 13-APR-09
released channel: ch00
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03009: failure of backup command on ch00 channel at 04/13/2009 19:11:14
ORA-27206: requested file not found in media management catalog
该脚本备份其他数据库都没问题的。 |
|