10 G RAC (zz)

Q1. How to configure "listener.ora" and "tnsnames.ora"
A1. Usually, NETCA will launch automatically during the DBCA.
IF you have encountered some errors or want to reconfig
them later, please do the following things:

(1) Launch NETCA ;
(2) Choose the option "Cluster" in the first page;
(3) Choose one type such as "create listener",
"create local net service";
(4) Test the new created listener or local net service until success;
(5) By default, the application "srvctl" can only manage those
listeners with the suffix(host_name),So,please be very carefully
when modifying;
(6) Check and modify the initialization paratemter file if possible;

Steps:
Create a new initialization parameter file 'init.ora' on host (test1),
this file will be shared by each instance.

1. Invoke SQLPLUS, issue the following command:

SQL> create pfile='xxx' from spfile;

2. open "init.ora", add the following lines:

orcl1.local_listener=listener_orcl1
orcl2.local_listener=listener_orcl2
orcl1.remote_listener=listeners_orcl
orcl2.remote_listener=listeners_orcl

remove or comment this line:
*.remote_listener=listeners_orcl
(* represents this parameter will be used by each instance)

save the modification.

3. Invoke SQLPLUS again
SQL> shutdown immediate;
SQL> exit

SQL> startup pfile='xxx'
SQL> create spfile from pfile='xxx'
SQL> shutdown immediate;
SQL> exit

SQL> startup (new spfile will be used this time)


Note:
. If you don't change the listener's default port(1521), It's
unnecessary to add SID's entry in "listener.ora", Oracle
background process PMON will discovery all available
services every 60 seconds.

. If you use listener's default port(1521), It's unnecessary to
config parameter 'instance_name.local_listener=xxx' in
"init.ora" , you also shouldn't add this entry in
"tnsnames.ora" (local_listener_name = ...)

For example, a typical "listener.ora" should be like this:

listener_hostname =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(host=xxx)(port=1521))
(ADDRESS = (PROTOCOL = TCP)(host=your-vip-addr)(port=1521))
)

sid_list_listener_hostname =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = xxx)
(PROGRAM = extproc)
)

(SID_DESC =
(SID_NAME=xxx)
(ORACLE_HOME=xxx)
)
)

For example, a typical "tnsnames.ora" should be like this:

listener_hostname1=(address=(protocol=tcp)(host=test1)(port=1521))
listener_hostname2=(address=(protocol=tcp)(host=test2)(port=1521))

listeners_orcl =
(address_list =
(address=(protocol=tcp)(host=test1-vip)(port=1521))
(address=(protocol=tcp)(host=test2-vip)(port=1521))
)


# database connection: orcl
orcl =
(description =
(load_balance=on)
(address=(protocol=tcp)(host=test1-vip)(port=1521))
(address=(protocol=tcp)(host=test2-vip)(port=1521))
(connect_data =
(service_name=orcl)
)
)


# instance connection: orcl1
orcl1 =
(description =
(address=(protocol=tcp)(host=test1-vip)(port=1521))
(address=(protocol=tcp)(host=test2-vip)(port=1521))
(load_balance = yes)
(connect_data =
(server=dedicated)
(service_name=orcl)
(instance_name=orcl1)
)
)

# instance connection: orcl2
orcl2 =
(description =
(address=(protocol=tcp)(host=test1-vip)(port=1521))
(address=(protocol=tcp)(host=test2-vip)(port=1521))
(load_balance = yes)
(connect_data =
(server=dedicated)
(service_name=orcl2)
(failover_mode =
(type = select)
(method = basic)
(retries=180)
(delay=5)
)
)
)



Q2. How to recofig VIP ?
A2:
(1) delete the database using DBCA;
(2) delete the ASM(if configured) using documented procedure in 10g
Release notes;
(3) delete listeners using NetCA;
(4) delete nodeapps using srvctl as root user for all nodes.
for example:
srvctl stop nodeapps -n <node>
srvctl remove nodeapps -n <node>

Then you rerun vipca to reconfigure the VIPs, run netca to configure
listeners and dbca to create database to arrive at your initial state.


Q3: How to configure EM environment for RAC ?
1. Usually we only need run DBCA again to check the following
things exist:

. Check whether a schema "SYSMAN" has been created
(select username from all_users);

. Check if tablespace "SYSAUX" exists
(select tablespace_name from dba_tablespaces);

. Check if there is a directory <hostname_sid> has been
created under $ORACLE_HOME;

. Issue these commands to check dbconsole's status:

emctl start(stop/status) dbconsole

2. Trouble Shooting:

Q: Target's information is wrong or lost

A:
. Go to directory: $ORACLE_HOME/hostname_sid/emd,
open "targets.xml" to check if all available targets have
been discovered by EM;

. If the file <targets.xml> doesn't include all targets'
information you need, You can try:

emctl stop dbconsole;
remove all files under these directories;
$ORACLE_HOME/hostname_sid/sysman/emd/upload
$ORACLE_HOME/hostname_sid/sysman/emd/state

check file <targets.xml> again, make sure that at least
agent and host's info can be found from this file;

emctl start dbconsole; --wait for the new metic data
to be uploaded into the repository

3. If you've modified some settings of EM and the repository
has been created, you can execute "emca -r " to configure
the EM repository again;


4. Launch "http://host_name: port_number/em" on all nodes and
check them.

...


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值