Change Domainname of OracleAS Server on Solaris

Simple life posted @ Tue, 11 Aug 2009 04:09:47 +0800 in Oracle Application Server with tags oracle Application Server Domainname Hostname , 3764 readers

        Oracle Application Server修改主机名或者域名时, 除了修改DNS之外还需要更新Oracle Application Server的相关配置。修改Oracle Infrastructure Server的主机名或域名情况类似。

        具体可参照Oracle的相关文档。

        http://download.oracle.com/docs/cd/B14099_19/core.1012/b13995/host.htm#CHDGAIFH

        下面针对Linux环境下安装middle-tier instanceApplication Server例举一下主要步骤整个过程中数据库、OracleAS基础应用数据库、Oracle基础应用服务都处于启动状态。

        1>检测环境变量:

echo $ORACLE_HOME

//Set to the full path of the installation's Oracle home, /app/oraias/OraHome_1

echo $LD_LIBRARY_PATH

//$ORACLE_HOME/lib32

echo $LD_LIBRARY_PATH_64

//$ORACLE_HOME/lib

echo $PATH
//contains $ORACLE_HOME/bin,$ORACLE_HOME/dcm/bin,$ORACLE_HOME/opmn/bin

 

        2>InstanceFarm中移除

如果是属于OracleAS File-Based Farm, 使用如下命令移除Instance

ORACLE_HOME/dcm/bin/dcmctl leavefarm

 

If the host contains a J2EE and Web Cache instance that is part of an OracleAS File-Based Farm that uses a repository on another host or an OracleAS Database-Based Farm, remove the instance from the farm:         

ORACLE_HOME/dcm/bin/dcmctl leavefarm 

 

        3>停止Application Server的控制台和相关服务进程。命令如下:

        停止控制台服务: ORACLE_HOME/bin/emctl stop iasconsole
       
停止相关服务进程: ORACLE_HOME/opmn/bin/opmnctl stopall

        确保该middle tire所使用的OID(Oracle Internet Directory)服务处于开启状态。

        4>修改主机名、域名或者ip地址。

                修改域名需要修改以下文件中的配置:

                /etc/inet/hosts

                /etc/inet/ipnodes

                修改主机名还需要修改以下文件:

/etc/nodename

/etc/hostname.*

 

修改完后重启机器。重启后检查more /etc/hosts

 

        5>运行chgiphost命令。

        首先设置log的级别。修改文件$ORACLE_HOME/chgip/config/chgip.log.properties,将参数java.util.logging.ConsoleHandler.level设置为CONFIG

                使用命令

grep java.util.logging.ConsoleHandler.level $ORACLE_HOME/chgip/config/chgip.log.properties

                确认修改完毕。

                cd $ORACLE_HOME/chgip/scripts
                ./chgiphost.sh –mid

                该命令运行过程中根据提示,依次

1.       输入新的hostname.domainname

2.       输入新的hostname.domainname

3.       输入新的ip地址

4.       输入旧的ip地址,

5.       输入OIDAdmin的密码。即Oracle Internet Directorycn=orcladmin用户的密码。

     

        more $ORACLE_HOME/chgip/log, 查看日志文件是否修改成功。日志文件位于$ORACLE_HOME/chgip/log
       chgiphost命令实际是在$OACLE_HOME/chgip/config/hostname.lst列出的文件中执行替换工作。

        6>启动Application Server相关服务和控制台。

        ORACLE_HOME/opmn/bin/opmnctl startall
        ORACLE_HOME/bin/emctl start iasconsole

        7>Instance添加到Farm

If the host contained an instance that stored the file-based repository used by an OracleAS File-Based farm:

ORACLE_HOME/dcm/bin/dcmctl getRepositoryID
ORACLE_HOME/dcm/bin/dcmctl joinfarm -r repository_ID

If you removed any J2EE and Web Cache instances from an OracleAS File-Based Farm

ORACLE_HOME/dcm/bin/dcmctl joinfarm -r repository_ID
 
If you removed any J2EE and Web Cache instances from an OracleAS Database-Based Farm at the beginning of this procedure
ORACLE_HOME/dcm/bin/dcmctl joinfarm
 

耐心等待该步骤完成后,需要再次启动服务:

$ORACLE_HOME/opmn/bin/opmnctl startall

 

        8>更新OracleAS Portal, OracleAS Wireless, OracleAS Single Sign-On, Oracle Ultra Search

                Refer: http://download.oracle.com/docs/cd/B14099_19/core.1012/b13995/host.htm#CIHHADCE

1.       Update OracleAS Portal with the new OracleAS Wireless service URL.

Refer: http://download.oracle.com/docs/cd/B14099_19/portal.1012/b14037/cg_basic.htm#i1050271

2.       Update OracleAS Single Sign-On server with the new OracleAS Wireless SSO Partner URL.

ORACLE_HOME/wireless/bin/reRegisterSSO.sh

根据提示进行。

3.       Re-register OracleAS Portal as an Oracle Ultra Search Content Source.

Refer: http://download.oracle.com/docs/cd/B14099_19/portal.1012/b14037/cg_srch.htm#POCFG404

               

        9>手动修改文件中的hostname. 这些文件与配置无关。

       位于$ORACLE_HOME/Apache/Apache/htdocs目录下面。

index.html.de
  index.html.es_ES
  index.html.fr
  index.html.it
  index.html.ja
  index.html.ko
  index.html.pt_BR
  index.html.zh_CN
  index.html.zh_TW

               

                运行如下命令:

                cd $ORACLE_HOME/Apache/Apache/htdocs

grep old_hostname.domainname index.html.*

 

for indexHtml in index.html.*

do

cat $indexHtml | sed 's/old_hostname.domainname/new_hostname.domainname/g' > tmp.txt

mv -f tmp.txt $indexHtml

done

 

Avatar_small
Kalinda said:
Thu, 18 Feb 2010 01:17:45 +0800

Hello everyone. At a dinner party one should eat wisely but not too well, and talk well but not too wisely. Help me! Need information about: Degrees through distance education. I found only this - <a href="http://indipendentifiorenzuola.it/Members/DistanceEducation/distance-education-masters">distance education masters</a>. Icfai adopts preferred among the applicable programs, distance education. While tertiary skills are hosting in undertaking the previous marketing, most administration on time asks set and considered in full term, distance education. Best regards :cool:, Kalinda from Cyprus.

Avatar_small
Maria said:
Sun, 21 Feb 2010 06:18:47 +0800

Good Day. There?s so much comedy on television. Does that cause comedy in the streets? Help me! Looking for sites on: Sale of structured settlement. I found only this - <a href="http://shliga.sh.cvut.cz/shliga/Members/StructuredSettlement">structured settlement program</a>. The way was known by a treatment understory said increase adorned ernest f, structured settlement. until 1787 it was tweed of bladen county, structured settlement. Its heart to homestead, florida and its part offer it one of the most uncovered troops in the institution, structured settlement. With best wishes ;-), Maria from San.

Avatar_small
AAA said:
Wed, 11 May 2022 19:57:18 +0800

You are so cool man, the post on your blogs are super great.*;:;” How to Start a Merchant Processing Company

 

==============================================

 

You have a very nice layout for your blog, i want it to use on my site too .     starting up a credit card processing company


Login *


loading captcha image...
(type the code from the image)
or Ctrl+Enter