91超碰碰碰碰久久久久久综合_超碰av人澡人澡人澡人澡人掠_国产黄大片在线观看画质优化_txt小说免费全本

溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

【備份恢復】物理熱備及恢復

發布時間:2020-08-17 13:00:48 來源:ITPUB博客 閱讀:188 作者:不一樣的天空w 欄目:關系型數據庫

物理熱備:即數據庫處于開啟時備份,但前提必須要開啟歸檔,因為只有開歸檔,數據庫恢復時才能應用日志將數據庫恢復到最新;物理熱備可以備份單個數據文件、表空間及整個數據庫;物理熱備,分普通表空間(非關鍵數據文件)備份恢復和系統表空間(關鍵數據文件)備份恢復。

系統表空間:指的是systemsysauxundo表空間;

 

一:普通表空間的熱備及模擬故障恢復(方法一之關庫恢復shutdown

1.  (前提)物理熱備必須開啟歸檔,查看:

SYS@ORA11GR2>archive log list;

Database log mode              Archive Mode

Automatic archival             Enabled

Archive destination            USE_DB_RECOVERY_FILE_DEST

Oldest online log sequence     13

Next log sequence to archive   15

Current log sequence           15

SYS@ORA11GR2>

——確認快速恢復區已設置好:

SYS@ORA11GR2>show parameter recover

 

NAME                                 TYPE        VALUE

------------------------------------ ----------- ------------------------------

db_recovery_file_dest                string      /u01/app/FRA/

db_recovery_file_dest_size           big integer   3G

db_unrecoverable_scn_tracking        boolean     TRUE

recovery_parallelism                 integer     0

SYS@ORA11GR2>

 

2.  查看備份文件絕對路徑(重要)

SYS@ORA11GR2>select name from v$controlfile;

NAME

--------------------------------------------------------------------------------

/u01/app/oracle/oradata/ORA11GR2/control01.ctl

/u01/app/oracle/oradata/ORA11GR2/control02.ctl

/u01/app/FRA/control03.ctl

 

SYS@ORA11GR2>select name from v$datafile;

NAME

--------------------------------------------------------------------------------

/u01/app/oracle/oradata/ORA11GR2/system01.dbf

/u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

/u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

/u01/app/oracle/oradata/ORA11GR2/users01.dbf

/u01/app/oracle/oradata/ORA11GR2/example01.dbf

/u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

/u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

7 rows selected.

 

SYS@ORA11GR2>select member from v$logfile;

 

MEMBER

----------------------------------------------------------------------------
/u01/app/oracle/oradata/ORA11GR2/redo03.log

/u01/app/oracle/oradata/ORA11GR2/redo02.log

/u01/app/oracle/oradata/ORA11GR2/redo01.log

/u01/app/oracle/oradata/ORA11GR2/redo01_a.log

/u01/app/oracle/oradata/ORA11GR2/redo02_a.log

/u01/app/oracle/oradata/ORA11GR2/redo03_a.log

/u01/app/FRA/redo01_b.log

/u01/app/FRA/redo02_b.log

/u01/app/FRA/redo03_b.log

 

9 rows selected.

 

3.  模擬備份表空間TS_ORA11GR2

——先查看數據庫的表空間及對應文件

SYS@ORA11GR2>select tablespace_name,file_name from dba_data_files;

 

TABLESPACE FILE_NAME

---------- ------------------------------------------------------------

USERS       /u01/app/oracle/oradata/ORA11GR2/users01.dbf

UNDOTBS1    /u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

SYSAUX      /u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

SYSTEM      /u01/app/oracle/oradata/ORA11GR2/system01.dbf

EXAMPLE     /u01/app/oracle/oradata/ORA11GR2/example01.dbf

TS_ORA11GR2 /u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

UNDOTBS2    /u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

 

——開始表空間TS_ORA11GR2備份沒有關庫,即熱備

SYS@ORA11GR2>alter tablespace TS_ORA11GR2 begin backup;

 

Tablespace altered.

 

4.  回到操作系統層copy 表空間TS_ORA11GR2

[oracle@wang ORA11GR2]$ pwd

/u01/app/oracle/oradata/ORA11GR2

[oracle@wang ORA11GR2]$

[oracle@wang ORA11GR2]$ cp ts_ora11gr2_01.dbf  /home/oracle

[oracle@wang ORA11GR2]$

[oracle@wang ~]$ ls

ts_ora11gr2_01.dbf

[oracle@wang ~]$

 

5.  結束表空間TS_ORA11GR2備份

SYS@ORA11GR2>alter tablespace TS_ORA11GR2 end backup;

 

Tablespace altered.

 

驗證是否處于備份:

SYS@ORA11GR2>select * from v$backup;

 

     FILE# STATUS                CHANGE# TIME

---------- ------------------ ---------- ---------

         1 NOT ACTIVE                  0

         2 NOT ACTIVE                  0

         3 NOT ACTIVE                  0

         4 NOT ACTIVE                  0

         5 NOT ACTIVE                  0

         6 NOT ACTIVE            1543727 27-SEP-16

         7 NOT ACTIVE                  0

(說明備份已完成,結束)

7 rows selected.

 

SYS@ORA11GR2>select FILE_ID,TABLESPACE_NAME,FILE_NAME from dba_data_files order by 1;

 

   FILE_ID TABLESPACE FILE_NAME

---------- ---------- -------------------------------------------------------

         1 SYSTEM     /u01/app/oracle/oradata/ORA11GR2/system01.dbf

         2 SYSAUX     /u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

         3 UNDOTBS1   /u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

         4 USERS      /u01/app/oracle/oradata/ORA11GR2/users01.dbf

         5 EXAMPLE    /u01/app/oracle/oradata/ORA11GR2/example01.dbf

         6 TS_ORA11GR2 /u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

         7 UNDOTBS2   /u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

 

6.  操作刪除TS_ORA11GR2表空間下的數據文件:

[oracle@wang ORA11GR2]$ rm ts_ora11gr2_01.dbf

[oracle@wang ORA11GR2]$ pwd

/u01/app/oracle/oradata/ORA11GR2

7.  一致性關閉數據庫:

SYS@ORA11GR2>shutdow immediate;

Database closed.

Database dismounted.

ORACLE instance shut down.

SYS@ORA11GR2>

 

8.開啟數據庫(顯示找不到ts_ora11gr2_01.dbf

SYS@ORA11GR2>startup

ORACLE instance started.

 

Total System Global Area  730714112 bytes

Fixed Size                  2256832 bytes

Variable Size             457179200 bytes

Database Buffers          268435456 bytes

Redo Buffers                2842624 bytes

Database mounted.

ORA-01157: cannot identify/lock data file 6 - see DBWR trace file

ORA-01110: data file 6: '/u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf'

 

9.進行恢復操作:

——將備份的ts_ora11gr2_01.dbf文件cp/u01/app/oracle/oradata/ORA11GR2/下:

[oracle@wang ~]$ pwd

/home/oracle

[oracle@wang ~]$

[oracle@wang ~]$ ls

ts_ora11gr2_01.dbf

[oracle@wang ~]$

[oracle@wang ~]$ cp ts_ora11gr2_01.dbf  /u01/app/oracle/oradata/ORA11GR2/

[oracle@wang ~]$

[oracle@wang ORA11GR2]$ ls ts_ora11gr2_01.dbf

ts_ora11gr2_01.dbf

 

——恢復表空間:
SYS@ORA11GR2>  select status from v$instance;

STATUS
------------
MOUNTED

SYS@ORA11GR2>recover tablespace TS_ORA11GR2

Media recovery complete.

recover的動作,就是應用日志實現實例恢復到最近時間點)

——將數據庫啟動OPEN狀態:

SYS@ORA11GR2>alter database open;

 

Database altered.

 

完成!!!!!!!!!!!!

同類操作后臺日志記錄內容如下:

 【備份恢復】物理熱備及恢復alert.txt

 

二:普通表空間的熱備及模擬故障恢復(方法二之在線恢復offline-recover-online

1.查看熱備是否處于歸檔模式:

SYS@ORA11GR2>archive log list;

Database log mode              Archive Mode

Automatic archival             Enabled

Archive destination            USE_DB_RECOVERY_FILE_DEST

Oldest online log sequence     22

Next log sequence to archive   24

Current log sequence           24

SYS@ORA11GR2>

 

2.查看備份文件的絕對路徑:

SYS@ORA11GR2>select member from v$logfile;

MEMBER

-----------------------------------------------------------------

/u01/app/oracle/oradata/ORA11GR2/redo03.log

/u01/app/oracle/oradata/ORA11GR2/redo02.log

/u01/app/oracle/oradata/ORA11GR2/redo01.log

/u01/app/oracle/oradata/ORA11GR2/redo01_a.log

/u01/app/oracle/oradata/ORA11GR2/redo02_a.log

/u01/app/oracle/oradata/ORA11GR2/redo03_a.log

 

6 rows selected.

 

SYS@ORA11GR2>select name from v$controlfile;

NAME

-----------------------------------------------------------------

/u01/app/oracle/oradata/ORA11GR2/control01.ctl

/u01/app/oracle/oradata/ORA11GR2/control02.ctl

 

SYS@ORA11GR2>select tablespace_name,file_name from dba_data_files;

 

TABLESPACE_NAME FILE_NAME

-------------------------------------------------------

USERS           /u01/app/oracle/oradata/ORA11GR2/users01.dbf

UNDOTBS1        /u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

SYSAUX          /u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

SYSTEM          /u01/app/oracle/oradata/ORA11GR2/system01.dbf

EXAMPLE         /u01/app/oracle/oradata/ORA11GR2/example01.dbf

TS_ORA11GR2    /u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

UNDOTBS2        /u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

SYS@ORA11GR2>select file_id, tablespace_name,file_name from dba_data_files order by 1;

 

   FILE_ID TABLESPACE_NAME FILE_NAME

---------- ---------------

         1SYSTEM       /u01/app/oracle/oradata/ORA11GR2/system01.dbf

         2SYSAUX       /u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

         3UNDOTBS1    /u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

         4USERS        /u01/app/oracle/oradata/ORA11GR2/users01.dbf

         5EXAMPLE     /u01/app/oracle/oradata/ORA11GR2/example01.dbf

 6TS_ORA11GR2  /u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

         7UNDOTBS2  u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

 

SYS@ORA11GR2

 

3.備份數據文件users01.dbf

——使數據庫處于熱備狀態:(沒有關庫)

SYS@ORA11GR2>alter tablespace users begin backup;

 

Tablespace altered.

SYS@ORA11GR2>

 

——回到操作系統層copy對應文件到備份目錄下:

[oracle@wang ORA11GR2]$ ls users01.dbf

users01.dbf

[oracle@wang ORA11GR2]$

[oracle@wang ORA11GR2]$ cp users01.dbf /home/oracle/

[oracle@wang ORA11GR2]$

[oracle@wang ~]$ ls

users01.dbf

[oracle@wang ~]$ pwd

/home/oracle

[oracle@wang ~]$

 

查看備份狀態:

SYS@ORA11GR2>select * from v$backup;

 

     FILE# STATUS                CHANGE# TIME

---------- ------------------ ---------- -------------------

         1 NOT ACTIVE            1548675 2016-09-27 16:53:00

         2 NOT ACTIVE                  0

         3 NOT ACTIVE                  0

         4 ACTIVE                1585418 2016-09-27 21:57:23

         5 NOT ACTIVE                  0

         6 NOT ACTIVE            1543727 2016-09-27 16:11:12

         7 NOT ACTIVE                  0

(表明備份的動作還沒有結束)

7 rows selected.

 

SYS@ORA11GR2>select file_id,tablespace_name,file_name from dba_data_files order by 1;

 

   FILE_ID TABLESPACE_NAME FILE_NAME

---------- ---------------

         1SYSTEM       /u01/app/oracle/oradata/ORA11GR2/system01.dbf

         2SYSAUX       /u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

         3UNDOTBS1    /u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

         4USERS          /u01/app/oracle/oradata/ORA11GR2/users01.dbf

         5EXAMPLE     /u01/app/oracle/oradata/ORA11GR2/example01.dbf

         6TS_ORA11GR2 /01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

         7UNDOTBS2 /u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

 

結束備份:

SYS@ORA11GR2>alter tablespace users end backup;

 

Tablespace altered.

 

查看備份狀態:

SYS@ORA11GR2>select * from v$backup;

 

     FILE# STATUS                CHANGE# TIME

---------- ------------------ ---------- -------------------

         1 NOT ACTIVE            1548675 2016-09-27 16:53:00

         2 NOT ACTIVE                  0

         3 NOT ACTIVE                  0

         4 NOT ACTIVE            1585418 2016-09-27 21:57:23

         5 NOT ACTIVE                  0

         6 NOT ACTIVE            1543727 2016-09-27 16:11:12

         7 NOT ACTIVE                  0

 

7 rows selected.

 

4.操作刪除原目錄下的user01.dbf文件:

[oracle@wang ORA11GR2]$ pwd

/u01/app/oracle/oradata/ORA11GR2

[oracle@wang ORA11GR2]$ rm users01.dbf

[oracle@wang ORA11GR2]$

[oracle@wang ORA11GR2]$ ls user01.dbf

ls: user01.dbf: No such file or directory

[oracle@wang ORA11GR2]$

 

5.恢復數據文件:

——將數據文件offline

SYS@ORA11GR2>alter databasedatafile '/u01/app/oracle/oradata/ORA11GR2/users01.dbf' offline;

 

Database altered.

 

——將備份目錄下的備份文件copy回原目錄:

[oracle@wang ~]$ pwd

/home/oracle

[oracle@wang ~]$ cp users01.dbf /u01/app/oracle/oradata/ORA11GR2/

[oracle@wang ORA11GR2]$ pwd

/u01/app/oracle/oradata/ORA11GR2

[oracle@wang ORA11GR2]$

[oracle@wang ORA11GR2]$ ls users01.dbf

users01.dbf

[oracle@wang ORA11GR2]$

 

——使用recover命令進行介質恢復

SYS@ORA11GR2>recover datafile4;

Media recovery complete.

SYS@ORA11GR2>

 

——將表空間修改為online狀態(或者可以將數據文件置于online狀態)

SYS@ORA11GR2>alter tablespace users online;

Tablespace altered.

 

恢復成功!!!!!!!!!

 【備份恢復】物理熱備及恢復alert.txt

 

三:系統表空間的熱備及模擬故障恢復

恢復數據庫只能選擇關閉恢復,因為系統表空間只能online

1.(前提)物理熱備必須開啟歸檔,查看:

SYS@ORA11GR2>archive log list;

Database log mode              Archive Mode

Automatic archival             Enabled

Archive destination            USE_DB_RECOVERY_FILE_DEST

Oldest online log sequence     13

Next log sequence to archive   15

Current log sequence           15

SYS@ORA11GR2>

 

2.查看備份文件絕對路徑(重要)

SYS@ORA11GR2>select name from v$controlfile;

NAME

--------------------------------------------------------------------------------

/u01/app/oracle/oradata/ORA11GR2/control01.ctl

/u01/app/oracle/oradata/ORA11GR2/control02.ctl

/u01/app/FRA/control03.ctl

 

SYS@ORA11GR2>select name from v$datafile;

NAME

--------------------------------------------------------------------------------

/u01/app/oracle/oradata/ORA11GR2/system01.dbf

/u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

/u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

/u01/app/oracle/oradata/ORA11GR2/users01.dbf

/u01/app/oracle/oradata/ORA11GR2/example01.dbf

/u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

/u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

 

SYS@ORA11GR2>select member from v$logfile;

MEMBER

--------------------------------------------------------------------------------

/u01/app/oracle/oradata/ORA11GR2/redo03.log

/u01/app/oracle/oradata/ORA11GR2/redo02.log

/u01/app/oracle/oradata/ORA11GR2/redo01.log

/u01/app/oracle/oradata/ORA11GR2/redo01_a.log

/u01/app/oracle/oradata/ORA11GR2/redo02_a.log

/u01/app/oracle/oradata/ORA11GR2/redo03_a.log

/u01/app/FRA/redo01_b.log

/u01/app/FRA/redo02_b.log

/u01/app/FRA/redo03_b.log

 

9 rows selected.

 

3.查看數據庫的表空間及對應文件

SYS@ORA11GR2>select tablespace_name,file_name from dba_data_files;

TABLESPACE FILE_NAME

---------- -------------------------------------------------------

USERS      /u01/app/oracle/oradata/ORA11GR2/users01.dbf

UNDOTBS1   /u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

SYSAUX     /u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

SYSTEM     /u01/app/oracle/oradata/ORA11GR2/system01.dbf

EXAMPLE    /u01/app/oracle/oradata/ORA11GR2/example01.dbf

TS_ORA11GR2 /u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

UNDOTBS2   /u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

 

4.備份系統表空間:

SYS@ORA11GR2>alter tablespace SYSTEM begin backup;

 

Tablespace altered.

 

SYS@ORA11GR2>

 

——查看備份狀態:

SYS@ORA11GR2>select * from v$backup;

 

     FILE# STATUS                CHANGE# TIME

---------- ------------------ ---------- ---------

         1 ACTIVE                1548675 27-SEP-16

         2 NOT ACTIVE                  0

         3 NOT ACTIVE                  0

         4 NOT ACTIVE                  0

         5 NOT ACTIVE                  0

         6 NOT ACTIVE            1543727 27-SEP-16

         7 NOT ACTIVE                  0

 

7 rows selected.

 

SYS@ORA11GR2>select FILE_ID,TABLESPACE_NAME,FILE_NAME from dba_data_files order by 1;

 

   FILE_ID TABLESPACE FILE_NAME

---------- ---------- -------------------------------------------------------

         1 SYSTEM     /u01/app/oracle/oradata/ORA11GR2/system01.dbf

         2 SYSAUX     /u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

         3 UNDOTBS1   /u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

         4 USERS      /u01/app/oracle/oradata/ORA11GR2/users01.dbf

         5 EXAMPLE    /u01/app/oracle/oradata/ORA11GR2/example01.dbf

         6 TS_ORA11GR2 /u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

         7 UNDOTBS2   /u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

 

5.回到操作系統層copy 表空間system

[oracle@wang ORA11GR2]$ pwd

/u01/app/oracle/oradata/ORA11GR2

[oracle@wang ORA11GR2]$ cp system01.dbf /home/oracle/

[oracle@wang ORA11GR2]$cd

[oracle@wang ~]$ pwd

/home/oracle

[oracle@wang ~]$ ls system01.dbf

system01.dbf

[oracle@wang ~]$

 

6.結束備份:

SYS@ORA11GR2>alter tablespace system end backup;

 

Tablespace altered.

 

——查看備份狀態:

SYS@ORA11GR2>select * from v$backup;

 

     FILE# STATUS                CHANGE# TIME

---------- ------------------ ---------- ---------

         1 NOT ACTIVE            1548675 27-SEP-16

         2 NOT ACTIVE                  0

         3 NOT ACTIVE                  0

         4 NOT ACTIVE                  0

         5 NOT ACTIVE                  0

         6 NOT ACTIVE            1543727 27-SEP-16

         7 NOT ACTIVE                  0

 

7 rows selected.

 

SYS@ORA11GR2>select FILE_ID,TABLESPACE_NAME,FILE_NAME from dba_data_files order by 1;

 

   FILE_ID TABLESPACE FILE_NAME

---------- ---------- -------------------------------------------------------

         1 SYSTEM     /u01/app/oracle/oradata/ORA11GR2/system01.dbf

         2 SYSAUX     /u01/app/oracle/oradata/ORA11GR2/sysaux01.dbf

         3 UNDOTBS1   /u01/app/oracle/oradata/ORA11GR2/undotbs01.dbf

         4 USERS      /u01/app/oracle/oradata/ORA11GR2/users01.dbf

         5 EXAMPLE    /u01/app/oracle/oradata/ORA11GR2/example01.dbf

         6 TS_ORA11GR2 /u01/app/oracle/oradata/ORA11GR2/ts_ora11gr2_01.dbf

         7 UNDOTBS2   /u01/app/oracle/oradata/ORA11GR2/undotbs2_01.dbf

 

7 rows selected.

 

SYS@ORA11GR2>

 

8.  操作刪除system表空間下的數據文件

[oracle@wang ORA11GR2]$ pwd

/u01/app/oracle/oradata/ORA11GR2

[oracle@wang ORA11GR2]$ ls system01.dbf

system01.dbf

[oracle@wang ORA11GR2]$ rm system01.dbf

[oracle@wang ORA11GR2]$

[oracle@wang ORA11GR2]$ ls system01.dbf

ls: system01.dbf: No such file or directory

[oracle@wang ORA11GR2]$

 

——關庫:(模擬故障)

SYS@ORA11GR2>shutdown immediate;

ORA-01109: database not open

 

Database dismounted.

ORACLE instance shut down.

 

9.  啟動數據庫:(顯示故障)

SYS@ORA11GR2>startup

ORACLE instance started.

 

Total System Global Area  730714112 bytes

Fixed Size                  2256832 bytes

Variable Size             457179200 bytes

Database Buffers          268435456 bytes

Redo Buffers                2842624 bytes

Database mounted.

ORA-01157: cannot identify/lock data file 1 - see DBWR trace file

ORA-01110: data file 1: '/u01/app/oracle/oradata/ORA11GR2/system01.dbf'

 

9.將表空間置于offline進行恢復
SQL> select status from v$instance;

STATUS
------------
MOUNTED

SYS@ORA11GR2>alter tablespace system offline;

alter tablespace system offline

*

ERROR at line 1:

ORA-01541: system tablespace cannot be brought offline; shut down if necessary

system等系統表空間不能置于offline下進行恢復,必須關庫后恢復)

 

SYS@ORA11GR2>shutdown immediate;

Database closed.

Database dismounted.

ORACLE instance shut down.

SYS@ORA11GR2>

——將備份的system01.dbf復制到/u01/app/oracle/oradata/ORA11GR2/

[oracle@wang ~]$ pwd

/home/oracle

[oracle@wang ~]$ ls

system01.dbf  ts_ora11gr2_01.dbf

[oracle@wang ~]$

[oracle@wang ~]$ cp system01.dbf /u01/app/oracle/oradata/ORA11GR2/

驗證:

[oracle@wang ORA11GR2]$ pwd

/u01/app/oracle/oradata/ORA11GR2

[oracle@wang ORA11GR2]$

[oracle@wang ORA11GR2]$ ls system01.dbf

system01.dbf

[oracle@wang ORA11GR2]$

 

——再次啟動數據庫

SYS@ORA11GR2>startup

ORACLE instance started.

 

Total System Global Area  730714112 bytes

Fixed Size                  2256832 bytes

Variable Size             457179200 bytes

Database Buffers          268435456 bytes

Redo Buffers                2842624 bytes

Database mounted.

ORA-01113: file 1 needs media recovery

ORA-01110: data file 1: '/u01/app/oracle/oradata/ORA11GR2/system01.dbf'

 

——恢復表空間system;(熱備開啟了歸檔,所以可以recover

SYS@ORA11GR2>recover tablespace system

Media recovery complete.

SYS@ORA11GR2>select status from v$instance;

 

STATUS

------------

MOUNTED

 

SYS@ORA11GR2>alter database open;

 

Database altered.

 

SYS@ORA11GR2>select status from v$instance;

 

STATUS

------------

OPEN

 

完成!!!!!!!!!!!!!!!!

 

【備份恢復】物理熱備及恢復alert.txt 

 

向AI問一下細節

免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。

AI

平阴县| 修武县| 吉首市| 沁水县| 浦县| 洪江市| 西林县| 固始县| 东明县| 南和县| 石楼县| 隆安县| 灌南县| 泸西县| 巩义市| 合江县| 山东| 深圳市| 平昌县| 唐海县| 正阳县| 昌平区| 瓦房店市| 册亨县| 东乡族自治县| 乳源| 濮阳市| 南丰县| 荆州市| 台东县| 沿河| 大同市| 民丰县| 镇原县| 临潭县| 蒙自县| 九寨沟县| 五华县| 德清县| 司法| 张家川|