Oracle12c多租戶資料庫備份與恢復 - 備份CDB和下面的所有PDBs

tolywang發表於2014-03-07

Oracle 12.1.0 ,  多租戶資料庫

[oracle@nkgttv2024rhl tmp]$  sqlplus   /  as sysdba
SQL> show  con_name

CON_NAME
------------------------------
CDB$ROOT
SQL>     
SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO
         3 PLUGDB                         READ WRITE NO
         4 CONT01_PLUG01                  MOUNTED
         5 MYPDB1                         READ WRITE NO
SQL>
SQL> exit


----  備份CDB和下面的所有PDBs (整個資料庫)

syntax :    backup database 


範例:
$RMAN target  / 
RMAN> 
run {
     allocate channel c1 type disk ;
     allocate channel c2 type disk ;
     allocate channel c3 type disk ;
      crosscheck archivelog all ;
      backup as compressed backupset database plus archivelog format '/data01/tmp/fullbak/db_full_%U_%p_%T_%s.bak';
      backup current controlfile format '/data01/tmp/fullbak/contorlfile_%T_%U_%s.ctlbak';
     release channel c1;
     release channel c2;
     release channel c3;
  }

 

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/35489/viewspace-1103089/,如需轉載,請註明出處,否則將追究法律責任。

相關文章