所有的这些脚本都在目标库上运行
--先做一次包括archivelog的全备份
run {
allocate channel t1 type disk FORMAT='d:backupfull_%u';
backup current controlfile;
backup full database;
backup archivelog all;
release channel t1;
}
connect target /
connect auxiliary sys/oracle@clone
run{
allocate auxiliary channel t1 type disk;
set newname for datafile 1 to 'D:ORADATACLONESYSTEM01.DBF';
set newname for datafile 2 to 'D:ORADATACLONEUNDOTBS01.DBF';
set newname for datafile 3 to 'D:ORADATACLONETOOLS01.DBF';
DUPLICATE TARGET DATABASE TO 'CLONE'
LOGFILE
GROUP 1 ('D:ORADATACLONEREDO01.DBF') SIZE 5M,
GROUP 2 ('D:ORADATACLONEREDO02.DBF') SIZE 5M,
GROUP 3 ('D:ORADATACLONEREDO03.DBF') SIZE 5M;
}
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/29987/viewspace-51940/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/29987/viewspace-51940/