Post Clone EBS時,執行adcfgclone.pl dbTier 發生了錯誤

今天在Clone EBS到測試機時,在DB先執行adautocfg.sh及adpreclone.pl,結果發現測試機上面剩餘空間不足,
所以新增了小容量的undo tablespace,並把原來的undo tablespace刪除,以減少使用空間。

複製所有的檔案之後,在DB執行adcfgclone.pl時發生了錯誤,查詢log之後發現下列的錯誤:

adcrdb.sh started at Sun Dec 15 07:12:10 EAT 2013
…略
SQL*Plus: Release 9.2.0.7.0 - Production on Sun Dec 15 07:12:10 2013

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

Connected to an idle instance.
ORACLE instance shut down.
Connected to an idle instance.
ORACLE instance started.

Total System Global Area  598699744 bytes
Fixed Size     736992 bytes
Variable Size  419430400 bytes
Database Buffers  167772160 bytes
Redo Buffers   10760192 bytes
CREATE CONTROLFILE REUSE SET DATABASE "CLONE"
*
ERROR at line 1:
ORA-01503: CREATE CONTROLFILE failed
ORA-01565: error in identifying file '/erptest/clonedata/UNDOTBS06.dbf'
ORA-27037: unable to obtain file status
HP-UX Error: 2: No such file or directory
Additional information: 3
…略

UNDOTBS06.dbf是舊有的undo tablespaces的Datafile,但是已經刪除了,
所以猜想應該是腳本其他地方錯誤的緣故。先檢查init<SID>.ora,內容是正確的,
接著在重新檢查log檔發會在執行adcrdb.sh時錯誤,再檢查該Script內容,
得知它會執行adcrdbclone.sql,而部份內容如下:

  …略
  '/erptest/clonedata/UNDOTBS06.dbf',
  …略

就是這裡發生了錯誤,將UNDOTBS06.dbf改成正確的UNDO Datafile名稱之後,
重新執行adcrdb.sh,結果還是出現了錯誤如下:

ORA-01503: CREATE CONTROLFILE failed
ORA-01223: RESETLOGS must be specified to set a new database name

再修改一次adcrdbclone.sql,增加關鍵字RESETLOGS如下:

…略
CREATE CONTROLFILE REUSE SET DATABASE "CLONE" resetlogs
…略

再重新執行adcrdb.sh,這次就成功了啟動DB了。接著往下執行APP的部份就好了。




Oracle Data Gurad Archive Gap