本實(shí)驗(yàn)是將ASM文件利用cp命令拷貝到操縱系統(tǒng)文件系統(tǒng)后,如何注冊到database,打開數(shù)據(jù)庫
環(huán)境是linux5.7+oracle11.2.0.4
RMAN> catalog datafilecopy '/s01/oracle/USERS.268.962900225';
cataloged datafile copy
datafile copy file name=/s01/oracle/USERS.268.962900225 RECID=2 STAMP=963047096
RMAN> run
2> {
3> set newname for datafile '+DATA/DAVID/DATAFILE/USERS.268.962900225' to '/s01/oracle/USERS.268.962900225';
4> switch datafile all;
5> }
executing command: SET NEWNAME
datafile 4 switched to datafile copy
input datafile copy RECID=2 STAMP=963047096 file name=/s01/oracle/USERS.268.962900225
RMAN> recover datafile 4;
Starting recover at 18-DEC-17
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=20 device type=DISK
starting media recovery
media recovery complete, elapsed time: 00:00:01
Finished recover at 18-DEC-17
RMAN> exit
Recovery Manager complete.
[oracle@rac1 ~]$ sqlplus /nolog
SQL*Plus: Release 11.2.0.4.0 Production on Mon Dec 18 09:06:09 2017
Copyright (c) 1982, 2013, Oracle. All rights reserved.
SQL> connect / as sysdba
Connected.
SQL> alter database open;
Database altered.
SQL> select file_name
2 from dba_data_files;
FILE_NAME
--------------------------------------------------------------------------------
/s01/oracle/USERS.268.962900225
+DATA/david/datafile/undotbs1.261.962900225
+DATA/david/datafile/sysaux.260.962900225
+DATA/david/datafile/system.270.962900225
+DATA/david/datafile/example.262.962900447
SQL> select *
2 from scott.dept;
DEPTNO DNAME LOC
---------- -------------- -------------
10 ACCOUNTING NEW YORK
20 RESEARCH DALLAS
30 SALES CHICAGO
40 OPERATIONS BOSTON
SQL>
分享標(biāo)題:ASM文件移出后的注冊和打開數(shù)據(jù)庫
標(biāo)題鏈接:http://jinyejixie.com/article30/johhpo.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供企業(yè)建站、、手機(jī)網(wǎng)站建設(shè)、網(wǎng)站設(shè)計(jì)、搜索引擎優(yōu)化、外貿(mào)網(wǎng)站建設(shè)
廣告
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會(huì)在第一時(shí)間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時(shí)需注明來源:
創(chuàng)新互聯(lián)