####################################################################full database
vi /backup/ebsbackup_db_level0.sh
backup_path="/backup"
#backup
mkdir -p $backup_path
chown -R oracle:oinstall $backup_path
su - oracle -c 'rman target / nocatalog msglog=/backup/rman_L0.`date +%Y%m%d%H%M%S`.log' <<EOF
run
{
#CONFIGURE DEVICE TYPE DISK PARALLELISM 16 BACKUP TYPE TO COMPRESSED BACKUPSET;
backup as compressed backupset incremental level 0 format '$backup_path/BZPROD_DATA_level0_%Y%M%D$(date +%H%M%S)_%U' database;
#sql "alter system archive log current";
#sql "alter system archive log current";
#sql "alter system archive log current";
backup as compressed backupset archivelog all format '$backup_path/BZPROD_ARCH_%Y%M%D$(date +%H%M%S)_%U';
backup current controlfile format '$backup_path/BZPROD_CONTROLFILE_level0_%Y%M%D$(date +%H%M%S)_%U';
}
EOF
####################################################################archivelog
vi /backup/ebsbackup_db_arch.sh
backup_path="/backup"
#backup
mkdir -p $backup_path
chown -R oracle:oinstall $backup_path
su - oracle -c 'rman target / nocatalog msglog=/backup/rman_arch.`date +%Y%m%d%H%M%S`.log' <<EOF
run
{
#CONFIGURE DEVICE TYPE DISK PARALLELISM 16 BACKUP TYPE TO COMPRESSED BACKUPSET;
#sql "alter system archive log current";
#sql "alter system archive log current";
#sql "alter system archive log current";
backup as compressed backupset archivelog all format '$backup_path/BZPROD_ARCH_%Y%M%D$(date +%H%M%S)_%U';
backup current controlfile format '$backup_path/BZPROD_CONTROLFILE_arch_%Y%M%D$(date +%H%M%S)_%U';
}
EOF
####################################################################
chmod +x /backup/ebsbackup_db_level0.sh /backup/ebsbackup_db_arch.sh
nohup sh /backup/ebsbackup_db_level0.sh &
nohup sh /backup/ebsbackup_db_arch.sh &
oracle rman backup scripts
未经允许不得转载:徐万新之路 » oracle rman backup scripts
相关推荐
- ORACLE 临时表空间使用率过高的原因及解决方案(转)
- cursors.sql
- ORA-20005: Object Statistics Are Locked (stattype = ALL) ORA-06512: At "APPS.FND_STATS"
- How To Download And Install The Latest OPatch(6880880) Version (Doc ID 274526.1)
- Oracle 11g备份与恢复
- Oracle Database物理坏块与逻辑坏块
- KFS Oracle RAC 数据解析同步配置方法
- coe_locks.sql - Session and Serial# for Locked Rows (9.2-11.2.0.4) (Doc ID 156965.1)
最新评论
这个牛
放下欲望,男人从来不醉,充分且必要
勇气、责任、自信、创新,为天下先!
软件即数据,软件即服务,软件即管理,软件就是对人类各种社会活动的仿真和记录。软件很重要,但软件不可能凌驾于业务之上,尤其不可能高人一等。