RMAN 異機 復(fù)制數(shù)據(jù)庫_第1頁
RMAN 異機 復(fù)制數(shù)據(jù)庫_第2頁
RMAN 異機 復(fù)制數(shù)據(jù)庫_第3頁
RMAN 異機 復(fù)制數(shù)據(jù)庫_第4頁
RMAN 異機 復(fù)制數(shù)據(jù)庫_第5頁
已閱讀5頁,還剩12頁未讀 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認(rèn)領(lǐng)

文檔簡介

1、RMAN 異機 復(fù)制數(shù)據(jù)庫 2014年4月24日15:48 RMAN 異機 復(fù)制數(shù)據(jù)庫 RMAN 異機復(fù)制和同機復(fù)制操作步驟是一樣的,不同的是我們需要把備份的文件copy到輔助庫上去,而且位置要和目標(biāo)庫上一致,因為備份集的位置是寫在控制文件里的。 實驗平臺: oraclelinux+ oracle 10g目標(biāo)庫信息:ORACLE_BASE: /u01/app/oracleORACLE_HOME: /u01/app/oracle/product/10.2.0/db_1ORACLE_SID:orclIP: 00輔助庫信息:ORACLE_BASE: /u01/app/

2、oracleORACLE_HOME: /u01/app/oracle/product/10.2.0/db_1ORACLE_SID:orclIP: 我們以實例名相同的為例,實例名不同也一樣,在pfile里修改對應(yīng)參數(shù)就可以了。步驟如下:(1)構(gòu)建輔助數(shù)據(jù)庫目錄結(jié)構(gòu)(2)創(chuàng)建pfile,并復(fù)制到輔助數(shù)據(jù)庫,修改相關(guān)內(nèi)容(3)創(chuàng)建輔助實例口令文件(4)RMAN 備份源庫(5)添加配置監(jiān)聽(6)將源庫備份文件拷貝到輔助庫相同位置(7)用pfile文件,將輔助數(shù)據(jù)庫啟動到nomount 狀態(tài)(8)執(zhí)行RMAN duplicate命令復(fù)制數(shù)據(jù)庫(9)創(chuàng)建spfile文件(10)在磁帶

3、上恢復(fù)備份(11)使用DBNEWID程序生成新的DBID一構(gòu)建輔助數(shù)據(jù)庫目錄結(jié)構(gòu)1.1 Oracle data 目錄oraclelocalhost oracle$ mkdir oradataoraclelocalhost oracle$ lsoradata oraInventory productoraclelocalhost oracle$ cd oradata/oraclelocalhost oracle$ mkdir orcl1.2 其他目錄oraclelocalhost oracle$ pwd/u01/app/oracleoraclelocalhost oracle$ mkdir ad

4、minoraclelocalhost oracle$ lsadmin oradata oraInventory productoraclelocalhost oracle$ cd adminoraclelocalhost admin$ lsoraclelocalhost admin$ mkdir orcloraclelocalhost admin$ lsorcloraclelocalhost admin$ cd orcloraclelocalhost orcl$ mkdir adumporaclelocalhost orcl$ mkdir bdumporaclelocalhost orcl$

5、mkdir cdumporaclelocalhost orcl$ mkdir dpdumporaclelocalhost orcl$ mkdir pfileoraclelocalhost orcl$ mkdir udumporaclelocalhost orcl$ lsadump bdump cdump dpdump pfile udump二 創(chuàng)建pfile,復(fù)制到輔助數(shù)據(jù)庫,并修改相關(guān)參數(shù)2.1 在源庫上創(chuàng)建pfile 文件SQL> conn sys/adminorcl as sysdba;Connected.SQL> create pfile from spfile;File

6、created.2.2 用scp 命令將pfile 文件傳到輔助庫。要放在$ORACLE_HOME/dbs目錄下,不然ORACLE 不識別。oracledb1 orcl$ cd /u01/app/oracle/product/10.2.0/db_1/dbsoracledb1 dbs$ lshc_DAVE.dat initdw.ora lkDAVE orapworcl spfileorcl.orahc_orcl.dat init.ora lkORCL snapcf_orcl.finitDAVE.ora initorcl.ora orapwDAVE spfileDAVE.oraoracledb1

7、dbs$ scp initorcl.ora 1:/$ORACLE_HOME/dbsThe authenticity of host '1 (1)' can't be established.RSA key fingerprint is 1a:20:7a:05:bd:e0:ac:04:21:02:b1:72:01:69:40:d6.Are you sure you want to continue connecting (yes/no)? yesWarning: Permanently added '

8、;1' (RSA) to the list of known hosts.oracle1's password:initorcl.ora 100% 1108 1.1KB/s 00:002.3 在輔助庫上確認(rèn)文件是否傳送過來oraclelocalhost orcl$ cd $ORACLE_HOME/dbsoraclelocalhost dbs$ lsinitdw.ora init.ora initorcl.ora2.4 在輔助庫上修改pfile參數(shù)oraclelocalhost dbs$ more initorcl.oraorcl._d

9、b_cache_size=167772160orcl._java_pool_size=4194304orcl._large_pool_size=4194304orcl._shared_pool_size=62914560orcl._streams_pool_size=0*.audit_file_dest='/u01/app/oracle/admin/orcl/adump'*.background_dump_dest='/u01/app/oracle/admin/orcl/bdump'*.compatible='.0'*.contr

10、ol_file_record_keep_time=14*.control_files='/u01/app/oracle/oradata/orcl/control01.ctl','/u01/app/oracle/oradata/orcl/control02.ctl','/u01/app/oracle/oradata/orcl/control03.ctl'*.core_dump_dest='/u01/app/oracle/admin/orcl/cdump'*.db_block_size=8192*.db_domain='

11、9;*.db_file_multiblock_read_count=16*.db_name='orcl'*.db_recovery_file_dest='/u01/app/oracle/flash_recovery_area'*.db_recovery_file_dest_size=2147483648*.dispatchers='(PROTOCOL=TCP) (SERVICE=orclXDB)'*.job_queue_processes=10*.log_archive_dest_1='location=/u01/archivelog&#

12、39;*.open_cursors=300*.pga_aggregate_target=81788928*.processes=150*.remote_login_passwordfile='EXCLUSIVE'*.sga_target=246415360*.undo_management='AUTO'*.undo_tablespace='UNDOTBS1'*.user_dump_dest='/u01/app/oracle/admin/orcl/udump'說明,在這里我沒有做修改,因為我異機復(fù)制實例名相同,存儲位置也相同。 如果

13、說你復(fù)制的不同的話,就需要修改相關(guān)的實例名。 如果存儲位置不同的話,還需要添加以下參數(shù),對數(shù)據(jù)文件位置進行轉(zhuǎn)換。db_file_name_convert = ('/u01/app/oracle/oradata/orcl','/u01/app/oracle/oradata/AUX')三創(chuàng)建輔助實例ORCL 的口令文件oraclelocalhost dbs$ cd $ORACLE_HOME/binoraclelocalhost bin$ orapwd file=$ORACLE_HOME/dbs/orapworcl password=adminoraclelocalh

14、ost bin$ cd $ORACLE_HOME/dbsoraclelocalhost dbs$ lsinitdw.ora init.ora initorcl.ora orapworclwindows下oracle默認(rèn)的位置是$ORACLE_HOME/database目錄,文件名格式是pwdSID.ora。 linux下oracle默認(rèn)的位置是$ORACLE_HOME/dbs目錄,文件名格式是orapwSID。 創(chuàng)建完后,數(shù)據(jù)庫需要重啟動,新的口令文件才能生效。 四RMAN 備份源庫(orcl)mkdir p /u01/backup oracledb1 backup$ rman target

15、sys/adminorclRecovery Manager: Release .0 - Production on Sun Jul 18 18:26:16 2010Copyright (c) 1982, 2005, Oracle. All rights reserved.connected to target database: ORCL (DBID=1248423599)RMAN>RUN allocate channel c1 type disk;allocate channel c2 type disk;BACKUP FORMAT '/u01/backup/o

16、rcl_%U_%T' skip inaccessible filesperset 5 DATABASE TAG orcl_hot_db_bk; sql 'alter system archive log current'BACKUP FORMAT '/u01/backup/arch_%U_%T' skip inaccessible filesperset 5 ARCHIVELOG ALL DELETE INPUT; backup current controlfile tag='bak_ctlfile' format='/u01/

17、backup/ctl_file_%U_%T'backup spfile tag='spfile' format='/u01/backup/ORCL_spfile_%U_%T'release channel c2;release channel c1; 五添加,配置監(jiān)聽5.1 在輔助庫的Listener.ora 文件中,添加如下內(nèi)容用圖形netmgr操作SID_LIST_LISTENER =(SID_LIST =(SID_DESC =(SID_NAME = PLSExtProc)(ORACLE_HOME = /u01/app/oracle/product/

18、10.2.0/db_1)(PROGRAM = extproc)(SID_DESC =(GLOBAL_DBNAME = orcl)(ORACLE_HOME = /u01/app/oracle/product/10.2.0/db_1)(SID_NAME = orcl)啟動偵聽 lsnrctl start Service "orcl" has 1 instance(s). Instance "orcl", status UNKNOWN, has 1 handler(s) for this service.  5.2 修改輔助庫的tnsnam

19、es.ora 文件,添加如下內(nèi)容TARGETORCL = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 00)(PORT = 1521) ) (CONNECT_DATA = (SERVICE_NAME = orcl) ) ) ORCL = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = )(PORT = 1521) ) (CONNECT_DATA = (SERVICE_NA

20、ME = orcl) ) )可以遠(yuǎn)程連接主庫服務(wù)名 5.3 修改源庫的tnsnames.ora 文件,添加如下內(nèi)容:AUXORCL = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = )(PORT = 1521) ) (CONNECT_DATA = (SERVICE_NAME = orcl) ) ) ORCL = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 00)(POR

21、T = 1521) ) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = orcl) ) )建議使用net manager 工具從界面來修改,這樣不容易出錯 六 將源庫的備份拷貝到輔助數(shù)據(jù)庫的相同位置 在輔助數(shù)據(jù)上建立一個文件/u01/backup 這里有兩種方法,一種直接在輔助庫上建相同的目錄結(jié)構(gòu),在用SCP 命令把這些備份文件copy過去,但是這樣會占用大量的網(wǎng)絡(luò)資源。 還有一種就是建好目錄結(jié)構(gòu)后用NFS直接Mount上去。 6.1 在輔助庫上建相同的備份目錄結(jié)構(gòu)因為我們在源庫上備份是備份到/u01/backup目錄中的,所以我們在輔

22、助庫上也建這個目錄rootlocalhost /# mkdir -p /u01/backup rootlocalhost /# chmod 777 /u01/backup6.2 將源庫的備份掛載到輔助庫上6.2.1 在源庫上將/u01/backup 目錄添加到共享rootdb1 # more /etc/exports/u01/backup (rw,async,anonuid=65534,anongid=65534)rootdb1 # service nfs start6.2.2 在輔助庫上掛載源庫的目錄,注意,mount命令必須以root用戶執(zhí)行rootlocalhost

23、 /# mount -t nfs -o rw,bg,hard,nointr,rsize=32768,wsize=32768,tcp,vers=3,timeo=600,actimeo=0 00:/u01/backup /u01/backup - 注意: 在掛載NFS的時候,一定要加上-t -o 參數(shù),不然在RMAN 復(fù)制的時候會報錯:-ORA-27054: NFS file system where the file is created or resides is not mounted with correct optionsrootlocalhost /# cd /u

24、01/backup/rootlocalhost backup# lsarch_3klj4676_1_1_20100718 orcl_3hlj45vf_1_1_20100718arch_3llj4676_1_1_20100718 orcl_3ilj465c_1_1_20100718ctl_file_3mlj467h_1_1_20100718 orcl_3jlj4661_1_1_20100718orcl_3glj45vf_1_1_20100718 ORCL_spfile_3nlj467k_1_1_20100718七 啟動輔助庫至nomount 狀態(tài),注意使用pfile參數(shù)啟動oraclelocal

25、host dbs$ sqlplus /nologSQL*Plus: Release .0 - Production on Tue Jul 20 03:53:53 2010Copyright (c) 1982, 2005, Oracle. All rights reserved.SQL> conn / as sysdbaConnected to an idle instance.SQL> startup nomount pfile=?/dbs/initorcl.oraORACLE instance started.Total System Global Area 24

26、7463936 bytesFixed Size 1218772 bytesVariable Size 79693612 bytesDatabase Buffers 163577856 bytesRedo Buffers 2973696 bytesSQL> exit - 啟動后就退出session,因為在duplicata的時候不能有session連接Disconnected from Oracle Database 10g Enterprise Edition Release .0 - ProductionWith the Partitioning, OLAP and D

27、ata Mining options八 RMAN 連接到目標(biāo)實例和輔助實例,運行duplicate 命令復(fù)制數(shù)據(jù)庫oracledb1 $ rman target sys/oracleorcl auxiliary sys/oracleauxorcl;Recovery Manager: Release .0 - Production on Sun Jul 18 20:41:19 2010Copyright (c) 1982, 2005, Oracle. All rights reserved.connected to target database: ORCL (DBID=1248

28、423599)connected to auxiliary database: ORCL (not mounted)RMAN> duplicate target database to orcl nofilenamechecklogfile'/u01/app/oracle/oradata/orcl/redo01.dbf' size 50m, '/u01/app/oracle/oradata/orcl/redo02.dbf' size 50m, '/u01/app/oracle/oradata/orcl/redo03.dbf' size 50

29、m;注: 這個地方有2個地方需要說明:(1) Nofilenamecheck 參數(shù): 如果在復(fù)制時,位置不同時,我們會用參數(shù)db_file_name_convert 對文件位置進行轉(zhuǎn)換。 但是在這個復(fù)制示例中我們用的是相同的位置。 所以這里必須加上nofilenamecheck參數(shù)。 該參數(shù)通知復(fù)制操作不必在執(zhí)行還原操作前確認(rèn)文件名是不同的。如果沒有指定nofilenamecheck參數(shù),rman會給出如下錯誤:RMAN-05001: auxiliary filename /u01/app/oracle/oradata/orcl/example01.dbf conflicts with a f

30、ile used by the target databaseRMAN-05001: auxiliary filename /u01/app/oracle/oradata/orcl/users01.dbf conflicts with a file used by the target database(2) logfile 參數(shù):在完成復(fù)制進程并執(zhí)行最有一條open resetlogs命令時,RMAN 必須為輔助數(shù)據(jù)庫構(gòu)建全新的日志文件。 如上面命令所示,我們可以在duplicate 命令中指定logfile參數(shù),并指定使用的日志文件的大小,數(shù)目和位置。 還可以在pfile里指定log_fi

31、le_name_convert 參數(shù)來進行轉(zhuǎn)換。 這種方法相對而言要簡單一點。 但因為我們在RMAN 同機復(fù)制數(shù)據(jù)庫的例子中用的就是這種方法,所以就換種方法來測試。 Starting Duplicate Db at 18-JUL-10using target database control file instead of recovery catalogallocated channel: ORA_AUX_DISK_1channel ORA_AUX_DISK_1: sid=155 devtype=DISKcontents of Memory Script:set until scn 7335

32、45;set newname for datafile 1 to "/u01/app/oracle/oradata/orcl/system01.dbf"set newname for datafile 2 to "/u01/app/oracle/oradata/orcl/undotbs01.dbf"set newname for datafile 3 to "/u01/app/oracle/oradata/orcl/sysaux01.dbf"set newname for datafile 4 to "/u01/app/or

33、acle/oradata/orcl/users01.dbf"set newname for datafile 5 to "/u01/app/oracle/oradata/orcl/example01.dbf"restorecheck readonlyclone database ;executing Memory Scriptexecuting command: SET until clauseexecuting command: SET NEWNAMEexecuting command: SET NEWNAMEexecuting command: SET NEW

34、NAMEexecuting command: SET NEWNAMEexecuting command: SET NEWNAMEStarting restore at 18-JUL-10using channel ORA_AUX_DISK_1channel ORA_AUX_DISK_1: starting datafile backupset restore - 開始restore 數(shù)據(jù)文件channel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup setrestoring datafile 00002 to /u

35、01/app/oracle/oradata/orcl/undotbs01.dbfrestoring datafile 00003 to /u01/app/oracle/oradata/orcl/sysaux01.dbfrestoring datafile 00005 to /u01/app/oracle/oradata/orcl/example01.dbfchannel ORA_AUX_DISK_1: reading from backup piece /u02/backup/orcl_3plj4ejl_1_1_20100718channel ORA_AUX_DISK_1: restored

36、backup piece 1piece handle=/u02/backup/orcl_3plj4ejl_1_1_20100718 tag=ORCL_HOT_DB_BKchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:01:48channel ORA_AUX_DISK_1: starting datafile backupset restorechannel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup setrestoring datafile 0

37、0001 to /u01/app/oracle/oradata/orcl/system01.dbfrestoring datafile 00004 to /u01/app/oracle/oradata/orcl/users01.dbfchannel ORA_AUX_DISK_1: reading from backup piece /u02/backup/orcl_3olj4ejk_1_1_20100718channel ORA_AUX_DISK_1: restored backup piece 1piece handle=/u02/backup/orcl_3olj4ejk_1_1_20100

38、718 tag=ORCL_HOT_DB_BKchannel ORA_AUX_DISK_1: restore complete, elapsed time: 00:01:14Finished restore at 18-JUL-10sql statement: CREATE CONTROLFILE REUSE SET DATABASE "ORCL" RESETLOGS ARCHIVELOG- 創(chuàng)建源庫的控制文件,然后根據(jù)這個文件進行相關(guān)的恢復(fù)MAXLOGFILES 16MAXLOGMEMBERS 3MAXDATAFILES 100MAXINSTANCES 8MAXLOGHIS

39、TORY 292LOGFILEGROUP 1 '/u01/app/oracle/oradata/orcl/redo01.dbf' SIZE 50 M ,GROUP 2 '/u01/app/oracle/oradata/orcl/redo02.dbf' SIZE 50 M ,GROUP 3 '/u01/app/oracle/oradata/orcl/redo03.dbf' SIZE 50 MDATAFILE'/u01/app/oracle/oradata/orcl/system01.dbf'CHARACTER SET WE8ISO8

40、859P1contents of Memory Script:switch clone datafile all;executing Memory Scriptreleased channel: ORA_AUX_DISK_1datafile 2 switched to datafile copyinput datafile copy recid=1 stamp=724831148 filename=/u01/app/oracle/oradata/orcl/undotbs01.dbfdatafile 3 switched to datafile copyinput datafile copy r

41、ecid=2 stamp=724831148 filename=/u01/app/oracle/oradata/orcl/sysaux01.dbfdatafile 4 switched to datafile copyinput datafile copy recid=3 stamp=724831148 filename=/u01/app/oracle/oradata/orcl/users01.dbfdatafile 5 switched to datafile copyinput datafile copy recid=4 stamp=724831148 filename=/u01/app/

42、oracle/oradata/orcl/example01.dbfcontents of Memory Script:set until scn 733545;recoverclone databasedelete archivelog ;executing Memory Scriptexecuting command: SET until clauseStarting recover at 18-JUL-10allocated channel: ORA_AUX_DISK_1channel ORA_AUX_DISK_1: sid=155 devtype=DISKstarting media r

43、ecoverychannel ORA_AUX_DISK_1: starting archive log restore to default destinationchannel ORA_AUX_DISK_1: restoring archive logarchive log thread=1 sequence=46channel ORA_AUX_DISK_1: reading from backup piece /u02/backup/arch_3tlj4er7_1_1_20100718channel ORA_AUX_DISK_1: restored backup piece 1piece

44、handle=/u02/backup/arch_3tlj4er7_1_1_20100718 tag=TAG20100718T205809channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01channel ORA_AUX_DISK_1: starting archive log restore to default destinationchannel ORA_AUX_DISK_1: restoring archive logarchive log thread=1 sequence=45channel ORA_AUX_

45、DISK_1: reading from backup piece /u02/backup/arch_3slj4er7_1_1_20100718channel ORA_AUX_DISK_1: restored backup piece 1piece handle=/u02/backup/arch_3slj4er7_1_1_20100718 tag=TAG20100718T205809channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:02archive log filename=/u01/archivelog/1_45_7

46、20642866.dbf thread=1 sequence=45channel clone_default: deleting archive log(s)archive log filename=/u01/archivelog/1_45_720642866.dbf recid=2 stamp=724831155archive log filename=/u01/archivelog/1_46_720642866.dbf thread=1 sequence=46channel clone_default: deleting archive log(s)archive log filename

47、=/u01/archivelog/1_46_720642866.dbf recid=1 stamp=724831153media recovery complete, elapsed time: 00:00:02Finished recover at 18-JUL-10contents of Memory Script:shutdown clone;startup clone nomount ;- 如果此時,輔助實例上有session連在上面,將一直等到session退出才能執(zhí)行,如果等了很長時間還沒有執(zhí)行,不妨檢查一下,有沒有session連在數(shù)據(jù)庫上。executing Memory Sc

48、riptdatabase dismountedOracle instance shut downconnected to auxiliary database (not started)Oracle instance startedTotal System Global Area 247463936 bytesFixed Size 1218772 bytesVariable Size 79693612 bytesDatabase Buffers 163577856 bytesRedo Buffers 2973696 bytessql statement: CREATE CONTROLFILE

49、REUSE SET DATABASE "ORCL" RESETLOGS ARCHIVELOG- 創(chuàng)建新的控制文件MAXLOGFILES 16MAXLOGMEMBERS 3MAXDATAFILES 100MAXINSTANCES 8MAXLOGHISTORY 292LOGFILEGROUP 1 '/u01/app/oracle/oradata/orcl/redo01.dbf' SIZE 50 M ,GROUP 2 '/u01/app/oracle/oradata/orcl/redo02.dbf' SIZE 50 M ,GROUP 3 '

50、/u01/app/oracle/oradata/orcl/redo03.dbf' SIZE 50 MDATAFILE'/u01/app/oracle/oradata/orcl/system01.dbf'CHARACTER SET WE8ISO8859P1contents of Memory Script:set newname for tempfile 1 to"/u01/app/oracle/oradata/orcl/temp01.dbf"switch clone tempfile all;catalog clone datafilecopy &q

51、uot;/u01/app/oracle/oradata/orcl/undotbs01.dbf"catalog clone datafilecopy "/u01/app/oracle/oradata/orcl/sysaux01.dbf"catalog clone datafilecopy "/u01/app/oracle/oradata/orcl/users01.dbf"catalog clone datafilecopy "/u01/app/oracle/oradata/orcl/example01.dbf"switch c

52、lone datafile all;executing Memory Scriptexecuting command: SET NEWNAMErenamed temporary file 1 to /u01/app/oracle/oradata/orcl/temp01.dbf in control filecataloged datafile copy datafile copy filename=/u01/app/oracle/oradata/orcl/undotbs01.dbf recid=1 stamp=724831185cataloged datafile copy datafile

53、copy filename=/u01/app/oracle/oradata/orcl/sysaux01.dbf recid=2 stamp=724831186cataloged datafile copy datafile copy filename=/u01/app/oracle/oradata/orcl/users01.dbf recid=3 stamp=724831186cataloged datafile copy datafile copy filename=/u01/app/oracle/oradata/orcl/example01.dbf recid=4 stamp=724831

54、186datafile 2 switched to datafile copy input datafile copy recid=1 stamp=724831185 filename=/u01/app/oracle/oradata/orcl/undotbs01.dbfdatafile 3 switched to datafile copy input datafile copy recid=2 stamp=724831186 filename=/u01/app/oracle/oradata/orcl/sysaux01.dbfdatafile 4 switched to datafile co

55、pyinput datafile copy recid=3 stamp=724831186 filename=/u01/app/oracle/oradata/orcl/users01.dbfdatafile 5 switched to datafile copyinput datafile copy recid=4 stamp=724831186 filename=/u01/app/oracle/oradata/orcl/example01.dbfcontents of Memory Script:Alter clone database open resetlogs;executing Me

56、mory Scriptexecuting Memory Scriptdatabase openedFinished Duplicate Db at 18-JUL-10九 創(chuàng)建spfile,并驗證數(shù)據(jù)庫通過上面8步的操作,復(fù)制操作已經(jīng)完成。 我們現(xiàn)在創(chuàng)建一個spfile。SQL> create spfile from pfile='/u01/app/oracle/product/10.2.0/db_1/dbs/initorcl.ora'File created.SQL> select name from v$database;NAME-ORCLSQL> sele

57、ct tablespace_name,file_name from dba_data_files;TABLESPACE_NAME FILE_NAME- -SYSTEM /u01/app/oracle/oradata/orcl/system01.dbfUNDOTBS1 /u01/app/oracle/oradata/orcl/undotbs01.dbfSYSAUX /u01/app/oracle/oradata/orcl/sysaux01.dbfUSERS /u01/app/oracle/oradata/orcl/users01.dbfEXAMPLE /u01/app/oracle/oradata/orcl/example01.dbf十 在遠(yuǎn)程服務(wù)器上復(fù)制磁帶備份如果在遠(yuǎn)程服務(wù)器上復(fù)制磁帶備份,必須配置輔助通道,以反映介質(zhì)管理器的需求。 除了指定介質(zhì)管理器和用于常規(guī)通道的類或池外,還必須指定目標(biāo)客戶端名稱,如下所示:RMAN> configure auxiliary channel 1 device type sb

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
  • 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論