oracle 取消动态监听,[20160711]关闭监听的动态注册.txt

[20160711]关闭监听的动态注册.txt

--这个我给别人解决dg日志不应用的问题.问题是没有设置静态注册,又关闭动态注册.自己还第一次知道存在这个参数

--DYNAMIC_REGISTRATION_LISTENER = off

--再测试环境重复测试,做1个记录:

1.环境:

SCOTT@book> @ &r/ver1

PORT_STRING                    VERSION        BANNER

------------------------------ -------------- --------------------------------------------------------------------------------

x86_64/Linux 2.4.xx            11.2.0.4.0     Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production

2.修改监听文件:

$ cat  listener.ora

# listener.ora Network Configuration File: /u01/app/oracle/product/11.2.0.4/dbhome_1/network/admin/listener.ora

# Generated by Oracle configuration tools.

#SUBSCRIBE_FOR_NODE_DOWN_EVENT_LISTENER=OFF

#SID_LIST_LISTENER =

#   (SID_LIST =

#    (SID_DESC =

#      (SDU=32767)

#      (GLOBAL_DBNAME = book)

#      (ORACLE_HOME = /u01/app/oracle/product/11.2.0.4/dbhome_1)

#      (SID_NAME = book)

#      )

#    )

LISTENER =

(DESCRIPTION_LIST =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.100.78)(PORT = 1521))

(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))

)

)

ADR_BASE_LISTENER = /u01/app/oracle

DIAG_ADR_ENABLED_LISTENER=OFF

DYNAMIC_REGISTRATION_LISTENER = off

3.重启监听:

$ lsnrctl stop

$ lsnrctl start

SCOTT@book> alter system register ;

System altered.

$ lsnrctl status

LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 11-JUL-2016 09:21:05

Copyright (c) 1991, 2013, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.100.78)(PORT=1521)))

STATUS of the LISTENER

------------------------

Alias                     LISTENER

Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production

Start Date                11-JUL-2016 09:20:31

Uptime                    0 days 0 hr. 0 min. 34 sec

Trace Level               off

Security                  ON: Local OS Authentication

SNMP                      OFF

Listener Parameter File   /u01/app/oracle/product/11.2.0.4/dbhome_1/network/admin/listener.ora

Listener Log File         /u01/app/oracle/product/11.2.0.4/dbhome_1/network/log/listener.log

Listening Endpoints Summary...

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.100.78)(PORT=1521)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))

The listener supports no services

The command completed successfully

4.这样其他机器无法远程登陆.

--主要问题,单位要通过安全等保,设置这个参数,没有仔细测试,做dg时又没有配置静态监听注册,而导致的问题.

--设置静态监听注册,问题解决.

--只所以一直没出现问题,是因为监听没有重启或者reload。从另外一些也说明,对服务器做了什么改动,要有记录有据可查。

--不知道为什么做安全等保要设置这个参数.有什么好处?我自己不知道.

--取消注解:

SID_LIST_LISTENER =

(SID_LIST =

(SID_DESC =

(SDU=32767)

(GLOBAL_DBNAME = book)

(ORACLE_HOME = /u01/app/oracle/product/11.2.0.4/dbhome_1)

(SID_NAME = book)

)

)

$ lsnrctl reload

$ lsnrctl status

LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 11-JUL-2016 09:28:50

Copyright (c) 1991, 2013, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.100.78)(PORT=1521)))

STATUS of the LISTENER

------------------------

Alias                     LISTENER

Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production

Start Date                11-JUL-2016 09:23:40

Uptime                    0 days 0 hr. 5 min. 10 sec

Trace Level               off

Security                  ON: Local OS Authentication

SNMP                      OFF

Listener Parameter File   /u01/app/oracle/product/11.2.0.4/dbhome_1/network/admin/listener.ora

Listener Log File         /u01/app/oracle/product/11.2.0.4/dbhome_1/network/log/listener.log

Listening Endpoints Summary...

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.100.78)(PORT=1521)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))

Services Summary...

Service "book" has 1 instance(s).

Instance "book", status UNKNOWN, has 1 handler(s) for this service...

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

The command completed successfully

--这样远程机器就可以正常登录了。

--注解:#DYNAMIC_REGISTRATION_LISTENER = off

$ lsnrctl reload

SCOTT@book> alter system register ;

System altered.

$ lsnrctl status

LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 11-JUL-2016 09:31:38

Copyright (c) 1991, 2013, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.100.78)(PORT=1521)))

STATUS of the LISTENER

------------------------

Alias                     LISTENER

Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production

Start Date                11-JUL-2016 09:23:40

Uptime                    0 days 0 hr. 7 min. 58 sec

Trace Level               off

Security                  ON: Local OS Authentication

SNMP                      OFF

Listener Parameter File   /u01/app/oracle/product/11.2.0.4/dbhome_1/network/admin/listener.ora

Listener Log File         /u01/app/oracle/product/11.2.0.4/dbhome_1/network/log/listener.log

Listening Endpoints Summary...

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.100.78)(PORT=1521)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=gxqyydg4)(PORT=8888))(Presentation=HTTP)(Session=RAW))

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=gxqyydg4)(PORT=7777))(Presentation=FTP)(Session=RAW))

Services Summary...

Service "book" has 2 instance(s).

Instance "book", status UNKNOWN, has 1 handler(s) for this service...

Instance "book", status READY, has 2 handler(s) for this service...

Service "bookXDB" has 1 instance(s).

Instance "book", status READY, has 1 handler(s) for this service...

The command completed successfully

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值