650) this.width=650;" src="/upload/getfiles/default/2022/11/8/20221108073646015.jpg" title="备份策略.png" />周日:做0级的增量备份(是增量备份的基础备份),脚本如下:
#!/bin/bash
#Author:wangergui Date:2017-02-13 Email:291131893@qq.com
#Function Sunday Increment level 0 backup script
Current_day=$(date +%Y-%m-%d)
[[ ${USER} == "oracle" ]] || exit 2
[[ -d /u01/app/oracle/myrman ]] || mkdir -p /u01/app/oracle/myrman
rman target / <<EOF
run {
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO ‘%F‘;
allocate channel c1 type disk;
allocate channel c2 type disk;
allocate channel c3 type disk;
allocate channel c4 type disk;
backup incremental level 0 database format ‘/u01/app/oracle/myrman/%d_%T_%s.bak‘ plus archivelog delete all input;
delete noprompt obsolete;
release channel c1;
release channel c2;
release channel c3;
release channel c4;
}
EOF
本文出自 “linux相关技术” 博客,请务必保留此出处http://wangergui.blog.51cto.com/8504247/1897308
原文:http://wangergui.blog.51cto.com/8504247/1897308
【说明】:本文章由站长整理发布,文章内容不代表本站观点,如文中有侵权行为,请与本站客服联系(QQ:254677821)!