Oracle Backup knowledge: Daily backups, full backups, and seven-day backups

Source: Internet
Author: User
Tags backup

1. Keep for seven days

This is the only way to keep backups for seven days

Rman> Connect target/

Connected to target Database:dbsid (dbid=3100778490)

Rman> Configure retention Policy to recovery windows of 7 days;

2. Backup Scripts

vi/root/rmanbak.sh

#! /bin/bash

Su-oracle <<!

Rman Target/<<eof

Backup as Compressed Backupset database

Include current controlfile format '/orabak/db_%d_%t_%s '

Plus archivelog format '/orabak/arch_%d_%t_%s ';

#delete obsolete; (Use this script to prompt for Yes or no to cause automatic deletion to fail)

Delete NoPrompt obsolete;

# (No prompt to enter Yes or no)

Exit

Eof

3.2 o'clock in the morning daily backup

Crontab Set Value to

2 * * */root/rmanbak.sh

This column more highlights: http://www.bianceng.cnhttp://www.bianceng.cn/database/Oracle/

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.