Chinaunix首页 | 论坛 | 博客
  • 博客访问: 2925896
  • 博文数量: 454
  • 博客积分: 4860
  • 博客等级: 上校
  • 技术积分: 6375
  • 用 户 组: 普通用户
  • 注册时间: 2011-03-13 10:08
个人简介

10年工作经验,专研网站运维。

文章分类

全部博文(454)

文章存档

2017年(11)

2016年(13)

2015年(47)

2014年(36)

2013年(147)

2012年(64)

2011年(136)

分类: Oracle

2012-11-22 19:46:51

Hostname:ebs.hisoft.com 改成 ebsdev.ge.com
 
1. 启动所有服务
动 Database
[root@ebs oracle]# su - oracle
[oracle@ebslouis ~]$ source /home/oracle/.ora
[oracle@ebslouis VIS_ebslouis]$ lsnrctl start
[oracle@ebs ~]$ sqlplus /nolog
SQL> conn /as sysdba
SQL> startup
SQL> quit
启动 Application:
[root@ebs oracle]# source /home/oracle/.app
[root@ebs oracle]#cd $COMMON_TOP/admin/scripts/VIS_ebslouis/
[root@ebs VIS_ebs]# sh adstrtal.sh apps/apps

2. Prepare the Source System
Prepare Database
[root@ebslouis ~]# su - oracle
[oracle@ebs VIS_ebs]$ source /home/oracle/.ora
[oracle@ebs VIS_ebs]$ cd /d01/oracle/visdb/9.2.0/appsutil/scripts/VIS_ebs
[oracle@ebs VIS_ebs]$ perl adpreclone.pl dbTier
Prepare Application
[oracle@ebs VIS_ebs]$ source /home/oracle/.app
[oracle@ebs VIS_ebs]$ cd /d01/oracle/viscomn/admin/scripts/VIS_ebs
[oracle@ebs VIS_ebs]$ perl adpreclone.pl appsTier

3. Stop all the services .
停止DB
[oracle@ebs VIS_ebs]$ source /home/oracle/.app
[oracle@ebs VIS_ebs]$ pwd
/d01/oracle/viscomn/admin/scripts/VIS_ebs
[oracle@ebs VIS_ebs]$ sh adstpall.sh apps/apps
停止DB
[oracle@ebs VIS_ebs]$ source /home/oracle/.ora
[oracle@ebs VIS_ebs]$ lsnrctl stop
[oracle@ebs VIS_ebs]$ sqlplus /nolog
SQL> conn /as sysdba
Connected.
SQL> shutdown immediate
SQL> quit

4. 修改主机名,重启服务器
[root@ebs11i ~]# vim /etc/hosts
[root@ebs11i ~]# vim /etc/sysconfig/network
[root@ebs11i ~]# init 6
 
4.1 给/tmp目录权限:
[root@ebsdalian ~]# chmod -R 777 /tmp

5. Configure the System
Configure Database
[oracle@ebs VIS_ebs]$ cd /d01/oracle/visdb/9.2.0/appsutil/clone/bin/
[oracle@ebs bin]$ source /home/oracle/.ora
[oracle@ebs11i bin]$ export KSH_VERSION="@(#)PD KSH v5.2.14 99/07/13.2"
[oracle@ebs bin]$ perl adcfgclone.pl dbTier
如果这么执行后肯定会报错:
Beginning database tier Apply - Wed Dec  5 10:31:26 2012
Log file located at /d01/oracle/visdb/9.2.0/appsutil/log/VIS_ebsdalian/ApplyDBTier_12051031.log
  -    100% completed       ERROR: InDbCtxFile.uploadCtx() : Exception : Error executng BEGIN fnd_gsm_util.append_ctx_fragment(?,?,?); END;: 1; Oracle error -25153: ORA-25153: Temporary Tablespace is Empty has been detected in FND_GSM_UTIL.APPEND_CTX_FRAGMENT.
oracle.apps.ad.autoconfig.oam.InDbCtxFileException: Error executng BEGIN fnd_gsm_util.append_ctx_fragment(?,?,?); END;: 1; Oracle error -25153: ORA-25153: Temporary Tablespace is Empty has been detected in FND_GSM_UTIL.APPEND_CTX_FRAGMENT.
那么就添加几步骤:
在开一个终端
su - oracle
把环境变量文件修改成现在的路径:
[root@ebsdalian ~]# vim /home/oracle/.ora
. /d01/oracle/visdb/9.2.0/VIS_ebs.env 修改成相应的环境变量:
. /d01/oracle/visdb/9.2.0/VIS_ebsdalian.env
[oracle@ebsdalian ~]$ lsnrctl stop
[oracle@ebsdalian bin]$ sqlplus /nolog
SQL> conn /as sysdba
SQL> alter tablespace temp add tempfile '/d01/oracle/visdata/tmp1.dbf';
SQL> exit
[oracle@ebsdalian VIS_ebsdalian]$ cd /d01/oracle/visdb/9.2.0/appsutil/scripts/VIS_ebsdalian
[oracle@ebsdalian VIS_ebsdalian]$ ls
adautocfg.sh  addbctl.sh   adexecsql.pl  adpreclone.pl  adstrtdb.sql
adchknls.pl   addlnctl.sh  adlsnodes.sh  adstopdb.sql
[oracle@ebsdalian VIS_ebsdalian]$ ./adautocfg.sh
[oracle@ebsdalian bin]$ cd /d01/oracle/visdb/9.2.0/appsutil/clone/bin
在执行一遍“[oracle@ebs bin]$ perl adcfgclone.pl dbTier”
[oracle@ebsdalian bin]$ perl adcfgclone.pl dbTier
如果期间出现问题,那么就:
[root@ebsdalian ~]# vim /home/oracle/.ora
. /d01/oracle/visdb/9.2.0/VIS_ebs.env  修改成相应的环境变量:
. /d01/oracle/visdb/9.2.0/VIS_ebsdalian.env
[oracle@ebsdalian ~]$ lsnrctl stop
 
Configure Database
[oracle@ebsdalian ~]$ su - oracle
[oracle@ebsdalian ~]$ source /home/oracle/.app
[oracle@ebs bin]$ cd /d01/oracle/viscomn/clone/bin/
perl adcfgclone.pl appsTier
[oracle@ebs bin]$ perl adcfgclone.pl appsTier
 
配置完成!!!
 

报错解决办法:

报错信息:

Beginning database tier Apply - Thu Nov 22 20:40:55 2012
Log file located at /d01/oracle/visdb/9.2.0/appsutil/log/VIS_ebshello/ApplyDBTier_11220840.log
RC-50004: Fatal: Error occurred in ApplyDatabase:
Control file creation failed

ERROR while running Apply...

ERROR: Failed to execute /d01/oracle/visdb/9.2.0/appsutil/clone/bin/adclone.pl

 

解决方法:

[oracle@ebs11i ~]$ source /home/oracle/.ora

[oracle@ebs11i ~]$ sqlplus '/as sysdba'

SQL> startup mount

SQL>recover database using backup controlfile until cancel;
SQL>CANCEL

SQL>alter database open resetlogs;

 

ksh报错解决办法:

Checking for ar... found - /usr/bin/ar
Checking for ksh...
Unable to find 'kshell' in path
Unable to locate all utilities with system path.

[oracle@ebs11i bin]$ export KSH_VERSION="@(#)PD KSH v5.2.14 99/07/13.2"


Configure the Target System Application Tier Server Nodes
Log on to the Target System as the APPLMGR user and type the following commands:
cd [COMMON_TOP]/clone/bin
perl adcfgclone.pl appsTier

 

.

 

This will create appsutil.zip in $APPL_TOP/admin/out . 注意看命令后面的提示,告诉你文件生成在哪里了。

Copy   the appsutil.zip file to the

 

 

[oracle@ebs bin]$ cp -rap /d01/oracle/visappl/admin/out/appsutil.zip /d01/oracle/visdb/9.2.0/

 

[oracle@ebs 9.2.0]$ cd  /d01/oracle/visdb/9.2.0

[oracle@ebs 9.2.0]$ source /home/oracle/.ora

replace appsutil/driver/adrdbtmpl.drv? [y]es, [n]o, [A]ll, [N]one, [r]ename: A

这里选择“A

接下来在执行一遍clone

[oracle@ebs 9.2.0]$ source /home/oracle/.ora

[oracle@ebs VIS_ebs]$ cd /d01/oracle/visdb/9.2.0/appsutil/clone/bin/

[oracle@ebs bin]$ perl adcfgclone.pl dbTier

参考文档见附件一。

 

 
附件一:
SolutionTo implement the solution, please execute the following steps :

1. On the Source Instance, please synchronize the APPS-Tier Autoconfig files with the DB-Tier, as documented in the Autoconfig
Note 165195.1 :
...
Update the RDBMS ORACLE_HOME file system with the AutoConfig files by performing the following steps:

On the Application Tier (as the APPLMGR user):
1. Log in to the APPL_TOP environment (source the environment file)
2. Create appsutil.zip file
perl /bin/admkappsutil.pl
This will create appsutil.zip in $APPL_TOP/admin/out .

On the Database Tier (as the ORACLE user):

3. Copy or FTP the appsutil.zip file to the
4. Change into the RDBMS $ ORACLE_HOME :
cd
5. Install the Autoconfig file by uncompressing the transfered ZIP-file :
unzip -o appsutil.zip
...

6. Start the Clone from the Source- to the Target-System again, starting with Pre-Cloning steps.
阅读(3820) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~