Oracle 11G Duplicate Database

梓沐發表於2017-02-04

1.輔助庫建立密碼檔案

[oracle@oracle dbs]$ cat initneal.ora

*.audit_file_dest='/u01/oracle/admin/neal/adump'

*.audit_trail='db'

*.compatible='11.2.0.4.0'

*.control_files='/u01/oracle/oradata/neal/control01.ctl','/u01/oracle/fast_recovery_area/neal/control02.ctl'

*.db_block_size=8192

*.db_name='neal'

db_file_name_convert=('/u01/oracle/oradata/orcl/','/u01/oracle/oradata/neal/')

log_file_name_convert=('/u01/oracle/oradata/orcl/','/u01/oracle/oradata/neal/')


2.輔助庫建立相應目錄

[oracle@oracle dbs]$ mkdir -p /u01/oracle/oradata/neal/

[oracle@oracle dbs]$ mkdir -p /u01/oracle/fast_recovery_area/neal/

[oracle@oracle dbs]$ mkdir -p /u01/oracle/admin/neal/adump/


3.輔助庫將資料庫啟動到nomount階段

[oracle@oracle dbs]$ export ORACLE_SID=neal

[oracle@oracle dbs]$ sqlplus / as sysdba


SQL*Plus: Release 11.2.0.4.0 Production on Sat Feb 4 09:58:29 2017


Copyright (c) 1982, 2013, Oracle. All rights reserved.


Connected to an idle instance.


SQL> startup nomount

ORACLE instance started.


Total System Global Area 217157632 bytes

Fixed Size         2251816 bytes

Variable Size         159384536 bytes

Database Buffers     50331648 bytes

Redo Buffers         5189632 bytes


SQL> show parameter db_name


NAME     TYPE VALUE

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

db_name string neal


4.從源庫scp密碼檔案到輔助庫

[oracle@oracle dbs]$ scp orapworcl 192.168.8.221:/u01/oracle/product/11.2.0/db_1/dbs/

The authenticity of host '192.168.8.221 (192.168.8.221)' can't be established.

RSA key fingerprint is c0:6c:19:4e:a2:68:7f:84:d8:d7:d2:31:0d:d3:d6:0d.

Are you sure you want to continue connecting (yes/no)? yes

Warning: Permanently added '192.168.8.221' (RSA) to the list of known hosts.

oracle@192.168.8.221's password:

orapworcl 100% 1536 1.5KB/s 00:00


5.修改從源庫scp過來的密碼檔名

[oracle@oracle dbs]$ mv orapworcl orapwneal


6.修改源庫和輔助庫tnsnames.ora檔案

6.1輔助庫

[oracle@oracle admin]$ vim tnsnames.ora

# tnsnames.ora Network Configuration File: /u01/oracle/product/11.2.0/db_1/network/admin/tnsnames.ora

# Generated by Oracle configuration tools.


ORCL =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.8.205)(PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME = orcl)

)

)


NEAL =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP)(HOST = oracle)(PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME = neal)

)

)


6.2源庫

[oracle@oracle admin]$ vim tnsnames.ora

# tnsnames.ora Network Configuration File: /u01/oracle/product/11.2.0/db_1/network/admin/tnsnames.ora

# Generated by Oracle configuration tools.


ORCL =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP)(HOST = oracle)(PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME = orcl)

)

)


NEAL =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.8.221)(PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME = neal)

)

)


7.源庫rman,準備複製

[oracle@oracle admin]$ rman target sys/oracle@orcl auxiliary sys/oracle@neal


Recovery Manager: Release 11.2.0.4.0 - Production on Sat Feb 4 10:17:58 2017


Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.


connected to target database: ORCL (DBID=1458962993)

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-00554: initialization of internal recovery manager package failed

RMAN-04006: error from auxiliary database: ORA-12528: TNS:listener: all appropriate instances are blocking new connections


7.1這裡rman連線報錯,是因為輔助庫在nomount階段監聽未註冊上,將主源庫和輔助庫修改如下

[oracle@oracle admin]$ vim listener.ora

# listener.ora Network Configuration File: /u01/oracle/product/11.2.0/db_1/network/admin/listener.ora

# Generated by Oracle configuration tools.


SID_LIST_LISTENER =

(SID_LIST =

(SID_DESC =

(SID_NAME = PLSExtProc)

(ORACLE_HOME = /u01/oracle/product/11.2.0/db_1)

(PROGRAM = extproc)

)

(SID_DESC =

(GLOBAL_DBNAME = neal)

(ORACLE_HOME = /u01/oracle/product/11.2.0/db_1)

(SID_NAME = neal)

)

)


LISTENER =

(DESCRIPTION_LIST =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))

(ADDRESS = (PROTOCOL = TCP)(HOST = oracle)(PORT = 1521))

)

)


ADR_BASE_LISTENER = /u01/oracle


[oracle@oracle admin]$ vim listener.ora

# listener.ora Network Configuration File: /u01/oracle/product/11.2.0/db_1/network/admin/listener.ora

# Generated by Oracle configuration tools.


SID_LIST_LISTENER =

(SID_LIST =

(SID_DESC =

(SID_NAME = PLSExtProc)

(ORACLE_HOME = /u01/oracle/product/11.2.0/db_1)

(PROGRAM = extproc)

)

(SID_DESC =

(GLOBAL_DBNAME = orcl)

(ORACLE_HOME = /u01/oracle/product/11.2.0/db_1)

(SID_NAME = orcl)

)

)



LISTENER =

(DESCRIPTION_LIST =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))

(ADDRESS = (PROTOCOL = TCP)(HOST = oracle)(PORT = 1521))

)

)


ADR_BASE_LISTENER = /u01/oracle


7.2重啟監聽

[oracle@oracle admin]$ lsnrctl start


LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 04-FEB-2017 10:25:32


Copyright (c) 1991, 2013, Oracle. All rights reserved.


Starting /u01/oracle/product/11.2.0/db_1/bin/tnslsnr: please wait...


TNSLSNR for Linux: Version 11.2.0.4.0 - Production

System parameter file is /u01/oracle/product/11.2.0/db_1/network/admin/listener.ora

Log messages written to /u01/oracle/diag/tnslsnr/oracle/listener/alert/log.xml

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521)))


Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))

STATUS of the LISTENER

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

Alias LISTENER

Version TNSLSNR for Linux: Version 11.2.0.4.0 - Production

Start Date 04-FEB-2017 10:25:32

Uptime 0 days 0 hr. 0 min. 0 sec

Trace Level off

Security ON: Local OS Authentication

SNMP OFF

Listener Parameter File /u01/oracle/product/11.2.0/db_1/network/admin/listener.ora

Listener Log File /u01/oracle/diag/tnslsnr/oracle/listener/alert/log.xml

Listening Endpoints Summary...

(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521)))

Services Summary...

Service "PLSExtProc" has 1 instance(s).

Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...

Service "neal" has 1 instance(s).

Instance "neal", status UNKNOWN, has 1 handler(s) for this service...

The command completed successfully



[oracle@oracle admin]$ lsnrctl start


LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 04-FEB-2017 10:25:46


Copyright (c) 1991, 2013, Oracle. All rights reserved.


Starting /u01/oracle/product/11.2.0/db_1/bin/tnslsnr: please wait...


TNSLSNR for Linux: Version 11.2.0.4.0 - Production

System parameter file is /u01/oracle/product/11.2.0/db_1/network/admin/listener.ora

Log messages written to /u01/oracle/diag/tnslsnr/oracle/listener/alert/log.xml

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521)))


Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))

STATUS of the LISTENER

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

Alias LISTENER

Version TNSLSNR for Linux: Version 11.2.0.4.0 - Production

Start Date 04-FEB-2017 10:25:46

Uptime 0 days 0 hr. 0 min. 0 sec

Trace Level off

Security ON: Local OS Authentication

SNMP OFF

Listener Parameter File /u01/oracle/product/11.2.0/db_1/network/admin/listener.ora

Listener Log File /u01/oracle/diag/tnslsnr/oracle/listener/alert/log.xml

Listening Endpoints Summary...

(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521)))

Services Summary...

Service "PLSExtProc" has 1 instance(s).

Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...

Service "orcl" has 1 instance(s).

Instance "orcl", status UNKNOWN, has 1 handler(s) for this service...

The command completed successfully


7.3重新rman連線

[oracle@oracle admin]$ rman target sys/oracle@orcl auxiliary sys/oracle@neal


Recovery Manager: Release 11.2.0.4.0 - Production on Sat Feb 4 10:26:19 2017


Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.


connected to target database: ORCL (DBID=1458962993)

connected to auxiliary database: NEAL (not mounted)


7.4源庫插入測試資料

SQL> insert into test values(1);


1 row created.


SQL> insert into test values(2);


1 row created.


SQL> insert into test values(3);


1 row created.


SQL> commit;


Commit complete.




7.5如果源庫未開啟歸檔模式,將會報如下錯誤

RMAN-03009: failure of backup command on ORA_DISK_1 channel at 02/04/2017 10:29:13

ORA-19602: cannot backup or copy active file in NOARCHIVELOG mode

continuing other job steps, job failed will not be re-run

channel ORA_DISK_1: starting datafile copy

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-03002: failure of Duplicate Db command at 02/04/2017 10:29:13

RMAN-05501: aborting duplication of target database

RMAN-03015: error occurred in stored script Memory Script

RMAN-03009: failure of backup command on ORA_DISK_1 channel at 02/04/2017 10:29:13

ORA-19602: cannot backup or copy active file in NOARCHIVELOG mode


7.6開啟歸檔

SQL> archive log list

Database log mode     No Archive Mode

Automatic archival     Disabled

Archive destination     USE_DB_RECOVERY_FILE_DEST

Oldest online log sequence 41

Current log sequence     43

SQL> shutdown immediate;

Database closed.

Database dismounted.

ORACLE instance shut down.

SQL> startup mount;

ORACLE instance started.


Total System Global Area 784998400 bytes

Fixed Size         2257352 bytes

Variable Size         478154296 bytes

Database Buffers     301989888 bytes

Redo Buffers         2596864 bytes

Database mounted.

SQL> alter database archivelog;


Database altered.


SQL> alter database open;


Database altered.


7.7 duplicate發生報錯,開啟歸檔找不到歸檔檔案

RMAN> duplicate target database to neal from active database;


Starting Duplicate Db at 04-FEB-17

using target database control file instead of recovery catalog

allocated channel: ORA_AUX_DISK_1

channel ORA_AUX_DISK_1: SID=20 device type=DISK

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-03002: failure of Duplicate Db command at 02/04/2017 10:31:46

RMAN-05501: aborting duplication of target database

RMAN-05541: no archived logs found in target database


RMAN> exit



Recovery Manager complete.


7.8源庫switch logfile


SQL> alter system switch logfile;


System altered.


SQL> alter system switch logfile;


System altered.



7.9重新rman連線,進行duplicate

[oracle@oracle admin]$ rman target sys/oracle@orcl auxiliary sys/oracle@neal


Recovery Manager: Release 11.2.0.4.0 - Production on Sat Feb 4 10:32:31 2017


Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.


connected to target database: ORCL (DBID=1458962993)

connected to auxiliary database: NEAL (not mounted)


RMAN> duplicate target database to neal from active database;


Starting Duplicate Db at 04-FEB-17

using target database control file instead of recovery catalog

allocated channel: ORA_AUX_DISK_1

channel ORA_AUX_DISK_1: SID=18 device type=DISK


contents of Memory Script:

{

sql clone "create spfile from memory";

}

executing Memory Script


sql statement: create spfile from memory


contents of Memory Script:

{

shutdown clone immediate;

startup clone nomount;

}

executing Memory Script


Oracle instance shut down


connected to auxiliary database (not started)

Oracle instance started


Total System Global Area 217157632 bytes


Fixed Size 2251816 bytes

Variable Size 159384536 bytes

Database Buffers 50331648 bytes

Redo Buffers 5189632 bytes


contents of Memory Script:

{

sql clone "alter system set db_name =

''ORCL'' comment=

''Modified by RMAN duplicate'' scope=spfile";

sql clone "alter system set db_unique_name =

''NEAL'' comment=

''Modified by RMAN duplicate'' scope=spfile";

shutdown clone immediate;

startup clone force nomount

backup as copy current controlfile auxiliary format '/u01/oracle/oradata/neal/control01.ctl';

restore clone controlfile to '/u01/oracle/fast_recovery_area/neal/control02.ctl' from

'/u01/oracle/oradata/neal/control01.ctl';

alter clone database mount;

}

executing Memory Script


sql statement: alter system set db_name = ''ORCL'' comment= ''Modified by RMAN duplicate'' scope=spfile


sql statement: alter system set db_unique_name = ''NEAL'' comment= ''Modified by RMAN duplicate'' scope=spfile


Oracle instance shut down


Oracle instance started


Total System Global Area 217157632 bytes


Fixed Size 2251816 bytes

Variable Size 159384536 bytes

Database Buffers 50331648 bytes

Redo Buffers 5189632 bytes


Starting backup at 04-FEB-17

allocated channel: ORA_DISK_1

channel ORA_DISK_1: SID=35 device type=DISK

channel ORA_DISK_1: starting datafile copy

copying current control file

output file name=/u01/oracle/product/11.2.0/db_1/dbs/snapcf_orcl.f tag=TAG20170204T103241 RECID=3 STAMP=935058761

channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:01

Finished backup at 04-FEB-17


Starting restore at 04-FEB-17

allocated channel: ORA_AUX_DISK_1

channel ORA_AUX_DISK_1: SID=18 device type=DISK


channel ORA_AUX_DISK_1: copied control file copy

Finished restore at 04-FEB-17


database mounted


contents of Memory Script:

{

set newname for datafile 1 to

"/u01/oracle/oradata/neal/system01.dbf";

set newname for datafile 2 to

"/u01/oracle/oradata/neal/sysaux01.dbf";

set newname for datafile 3 to

"/u01/oracle/oradata/neal/undotbs01.dbf";

set newname for datafile 4 to

"/u01/oracle/oradata/neal/users01.dbf";

set newname for datafile 5 to

"/u01/oracle/oradata/neal/example01.dbf";

backup as copy reuse

datafile 1 auxiliary format

"/u01/oracle/oradata/neal/system01.dbf" datafile

2 auxiliary format

"/u01/oracle/oradata/neal/sysaux01.dbf" datafile

3 auxiliary format

"/u01/oracle/oradata/neal/undotbs01.dbf" datafile

4 auxiliary format

"/u01/oracle/oradata/neal/users01.dbf" datafile

5 auxiliary format

"/u01/oracle/oradata/neal/example01.dbf" ;

sql 'alter system archive log current';

}

executing Memory Script


executing command: SET NEWNAME


executing command: SET NEWNAME


executing command: SET NEWNAME


executing command: SET NEWNAME


executing command: SET NEWNAME


Starting backup at 04-FEB-17

using channel ORA_DISK_1

channel ORA_DISK_1: starting datafile copy

input datafile file number=00001 name=/u01/oracle/oradata/orcl/system01.dbf

output file name=/u01/oracle/oradata/neal/system01.dbf tag=TAG20170204T103248

channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:25

channel ORA_DISK_1: starting datafile copy

input datafile file number=00002 name=/u01/oracle/oradata/orcl/sysaux01.dbf

output file name=/u01/oracle/oradata/neal/sysaux01.dbf tag=TAG20170204T103248

channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:26

channel ORA_DISK_1: starting datafile copy

input datafile file number=00005 name=/u01/oracle/oradata/orcl/example01.dbf

output file name=/u01/oracle/oradata/neal/example01.dbf tag=TAG20170204T103248

channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:15

channel ORA_DISK_1: starting datafile copy

input datafile file number=00003 name=/u01/oracle/oradata/orcl/undotbs01.dbf

output file name=/u01/oracle/oradata/neal/undotbs01.dbf tag=TAG20170204T103248

channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:07

channel ORA_DISK_1: starting datafile copy

input datafile file number=00004 name=/u01/oracle/oradata/orcl/users01.dbf

output file name=/u01/oracle/oradata/neal/users01.dbf tag=TAG20170204T103248

channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:01

Finished backup at 04-FEB-17


sql statement: alter system archive log current


contents of Memory Script:

{

backup as copy reuse

archivelog like "/u01/oracle/fast_recovery_area/ORCL/archivelog/2017_02_04/o1_mf_1_45_d9bhdthg_.arc" auxiliary format

"/u01/oracle/product/11.2.0/db_1/dbs/arch1_45_931182260.dbf" ;

catalog clone archivelog "/u01/oracle/product/11.2.0/db_1/dbs/arch1_45_931182260.dbf";

switch clone datafile all;

}

executing Memory Script


Starting backup at 04-FEB-17

using channel ORA_DISK_1

channel ORA_DISK_1: starting archived log copy

input archived log thread=1 sequence=45 RECID=3 STAMP=935058842

output file name=/u01/oracle/product/11.2.0/db_1/dbs/arch1_45_931182260.dbf RECID=0 STAMP=0

channel ORA_DISK_1: archived log copy complete, elapsed time: 00:00:01

Finished backup at 04-FEB-17


cataloged archived log

archived log file name=/u01/oracle/product/11.2.0/db_1/dbs/arch1_45_931182260.dbf RECID=3 STAMP=935058842


datafile 1 switched to datafile copy

input datafile copy RECID=3 STAMP=935058843 file name=/u01/oracle/oradata/neal/system01.dbf

datafile 2 switched to datafile copy

input datafile copy RECID=4 STAMP=935058843 file name=/u01/oracle/oradata/neal/sysaux01.dbf

datafile 3 switched to datafile copy

input datafile copy RECID=5 STAMP=935058843 file name=/u01/oracle/oradata/neal/undotbs01.dbf

datafile 4 switched to datafile copy

input datafile copy RECID=6 STAMP=935058843 file name=/u01/oracle/oradata/neal/users01.dbf

datafile 5 switched to datafile copy

input datafile copy RECID=7 STAMP=935058843 file name=/u01/oracle/oradata/neal/example01.dbf


contents of Memory Script:

{

set until scn 1787417;

recover

clone database

delete archivelog

;

}

executing Memory Script


executing command: SET until clause


Starting recover at 04-FEB-17

using channel ORA_AUX_DISK_1


starting media recovery


archived log for thread 1 with sequence 45 is already on disk as file /u01/oracle/product/11.2.0/db_1/dbs/arch1_45_931182260.dbf

archived log file name=/u01/oracle/product/11.2.0/db_1/dbs/arch1_45_931182260.dbf thread=1 sequence=45

media recovery complete, elapsed time: 00:00:01

Finished recover at 04-FEB-17

Oracle instance started


Total System Global Area 217157632 bytes


Fixed Size 2251816 bytes

Variable Size 159384536 bytes

Database Buffers 50331648 bytes

Redo Buffers 5189632 bytes


contents of Memory Script:

{

sql clone "alter system set db_name =

''NEAL'' comment=

''Reset to original value by RMAN'' scope=spfile";

sql clone "alter system reset db_unique_name scope=spfile";

shutdown clone immediate;

startup clone nomount;

}

executing Memory Script


sql statement: alter system set db_name = ''NEAL'' comment= ''Reset to original value by RMAN'' scope=spfile


sql statement: alter system reset db_unique_name scope=spfile


Oracle instance shut down


connected to auxiliary database (not started)

Oracle instance started


Total System Global Area 217157632 bytes


Fixed Size 2251816 bytes

Variable Size 159384536 bytes

Database Buffers 50331648 bytes

Redo Buffers 5189632 bytes

sql statement: CREATE CONTROLFILE REUSE SET DATABASE "NEAL" RESETLOGS ARCHIVELOG

MAXLOGFILES 16

MAXLOGMEMBERS 3

MAXDATAFILES 100

MAXINSTANCES 8

MAXLOGHISTORY 292

LOGFILE

GROUP 1 ( '/u01/oracle/oradata/neal/redo01.log' ) SIZE 50 M REUSE,

GROUP 2 ( '/u01/oracle/oradata/neal/redo02.log' ) SIZE 50 M REUSE,

GROUP 3 ( '/u01/oracle/oradata/neal/redo03.log' ) SIZE 50 M REUSE

DATAFILE

'/u01/oracle/oradata/neal/system01.dbf'

CHARACTER SET ZHS16GBK



contents of Memory Script:

{

set newname for tempfile 1 to

"/u01/oracle/oradata/neal/temp01.dbf";

switch clone tempfile all;

catalog clone datafilecopy "/u01/oracle/oradata/neal/sysaux01.dbf",

"/u01/oracle/oradata/neal/undotbs01.dbf",

"/u01/oracle/oradata/neal/users01.dbf",

"/u01/oracle/oradata/neal/example01.dbf";

switch clone datafile all;

}

executing Memory Script


executing command: SET NEWNAME


renamed tempfile 1 to /u01/oracle/oradata/neal/temp01.dbf in control file


cataloged datafile copy

datafile copy file name=/u01/oracle/oradata/neal/sysaux01.dbf RECID=1 STAMP=935058853

cataloged datafile copy

datafile copy file name=/u01/oracle/oradata/neal/undotbs01.dbf RECID=2 STAMP=935058853

cataloged datafile copy

datafile copy file name=/u01/oracle/oradata/neal/users01.dbf RECID=3 STAMP=935058853

cataloged datafile copy

datafile copy file name=/u01/oracle/oradata/neal/example01.dbf RECID=4 STAMP=935058853


datafile 2 switched to datafile copy

input datafile copy RECID=1 STAMP=935058853 file name=/u01/oracle/oradata/neal/sysaux01.dbf

datafile 3 switched to datafile copy

input datafile copy RECID=2 STAMP=935058853 file name=/u01/oracle/oradata/neal/undotbs01.dbf

datafile 4 switched to datafile copy

input datafile copy RECID=3 STAMP=935058853 file name=/u01/oracle/oradata/neal/users01.dbf

datafile 5 switched to datafile copy

input datafile copy RECID=4 STAMP=935058853 file name=/u01/oracle/oradata/neal/example01.dbf


contents of Memory Script:

{

Alter clone database open resetlogs;

}

executing Memory Script


database opened

Finished Duplicate Db at 04-FEB-17


OK.成功!

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

相關文章