Oracle Cold Backup Script

Source: Internet
Author: User

First, the principle

      1. Cold backup

      The process of completing all physical system file copies in a closed state, also known as offline backup

      Suitable for non-archive mode, the database is in a consistent state

    1. Steps

      Start by getting all the physical file locations of the database running in the running library, and then shutting down the database (shutdown) within the plan

      Perform a copy of the physical home to the backup path or backup device

      Start the database immediately after the backup is complete to provide normal service

    2. Summary-Benefits

      The concept is easy to understand in cold standby mode, and the files that will need to be backed up are copied to a secure location

      Simple operation, no need for too much intervention

      Easy to recover to a point in time (just copy the file back)

      Can be combined with the archiving method to restore the database "up-to-date state".

    3. Summary-Disadvantages

      Database must be in a consistent shutdown state when backing up

      can only provide recovery to a point in time

      Backup time is slow, especially the large performance impact of data volume is relatively large

      Cannot implement table-and user-level data recovery
      Second, the case
      In the first place, you should find out the database data files, log files, control files and the location of the temporary files in the relevant view. Note: Do not direct the oradata under the CP on the line, because the production library files are usually distributed in different disks, different places, so in the view to get the real path.
      1. See if the database is CDB
      [Email protected]>select name, decode (CDB, ' YES ', ' multitenant Option enabled ', ' Regular 12c Database: ') "multitenant Option ", Open_mode, con_id from V$database;

NAME multitenant Option Open_mode con_id

Newtest multitenant Option enabled READ WRITE
Yes indicates that the database is CDB, if no means no-cdb (normal database) 0

    1. To view information about instances and databases
      [Email protected]>select instance_name,version,status,archiver,database_status from v$instance;

instance_name VERSION STATUS ARCHIVE database_status

Newtest 12.2.0.1.0 OPEN STARTED ACTIVE
[Email protected]>select dbid,name,log_mode from V$database;

  DBID NAME      LOG_MODE

1779551310 newtest ARCHIVELOG

Oracle Cold Backup Script

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.