在线精品99_中国九九盗摄偷拍偷看_91免费版在线观看_91.app_91高清视频在线_99热最新网站

如何监听Oracle

102次阅读
没有评论

共计 4611 个字符,预计需要花费 12 分钟才能阅读完成。

这篇文章将为大家详细讲解有关如何监听 Oracle,丸趣 TV 小编觉得挺实用的,因此分享给大家做个参考,希望大家阅读完这篇文章后可以有所收获。

Oracle 监听

一:没有 listener.ora 监听文件

监听文件 listener.ora 文件丢失;
没有 listener.ora 文件情况时,以默认方式运行监听器,此时,监听器将在解析为计算机主机名 (端口 1521) 的任何地址上进行监听;
建议始终配置 listener.ora 文件,使 Oracle Net 环境可以自我记录;

[oracle@chen admin]$ pwd
/u01/app/oracle/product/11.2.0.4/network/admin

[oracle@chen admin]$ ls
samples  shrept.lst  tnsnames.ora

没有配置 listener.ora 时,自动使用动态注册
[oracle@chen admin]$
lsnrctl status
LSNRCTL for Linux: Version 11.2.0.4.0 – Production on 20-JUL-2017 15:05:25
Copyright (c) 1991, 2013, Oracle.  All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
STATUS of the LISTENER
————————
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 11.2.0.4.0 – Production
Start Date                20-JUL-2017 15:03:54
Uptime                    0 days 0 hr. 1 min. 30 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Log File         /u01/app/oracle/diag/tnslsnr/chen/listener/alert/log.xml
Listening Endpoints Summary…
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=chen)(PORT=1521)))
Services Summary…
Service orcl has 1 instance(s).
  Instance orcl , status READY, has 1 handler(s) for this service…
Service orclXDB has 1 instance(s).
  Instance orcl , status
READY, has 1 handler(s) for this service…
The command completed successfully

二:监听静态注册

[oracle@chen admin]$ pwd
/u01/app/oracle/product/11.2.0.4/network/admin

[oracle@chen admin]$ cat listener.ora 
SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (GLOBAL_DBNAME = orcl)
      (ORACLE_HOME = /u01/app/oracle/product/11.2.0.4)
      (SID_NAME = orcl)
    )
  )

静态注册时:
可以远程启动数据库(需要有口令文件);

C:\Users\Administrator sqlplus sys/[email protected]:1521/orcl as sysdba

SQL*Plus: Release 11.2.0.4.0 Production on 星期四 7 月 20 13:33:09 2017

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

已连接到空闲例程。

SQL
startup
ORACLE 例程已经启动。

Total System Global Area  839282688 bytes
Fixed Size                  2257880 bytes
Variable Size             545262632 bytes
Database Buffers          289406976 bytes
Redo Buffers                2355200 bytes
数据库装载完毕。
数据库已经打开。 [oracle@chen admin]$ lsnrctl status
…..
Listening Endpoints Summary…
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=chen)(PORT=1521)))
Services Summary…
Service orcl has 2 instance(s).
  Instance orcl , status
UNKNOWN, has 1 handler(s) for this service…
  Instance orcl , status READY, has 1 handler(s) for this service…
Service orclXDB has 1 instance(s).
  Instance orcl , status READY, has 1 handler(s) for this service…
The command completed successfully

配置 DG,EM 等建议使用静态注册

三:监听动态注册

[oracle@chen admin]$ cat listener.ora 
LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = chen)(PORT = 1521))
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    )
  )
 
SQL alter system register;
System altered.

[oracle@chen admin]$ lsnrctl status
Services Summary…
Service orcl has 1 instance(s).
  Instance orcl , status
READY, has 1 handler(s) for this service…
Service orclXDB has 1 instance(s).
  Instance orcl , status
READY, has 1 handler(s) for this service…
The command completed successfully

实例未启动时,注册不了服务
Services Summary…
Listening Endpoints Summary…
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=chen)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
The listener supports no services
The command completed successfully

动态注册时无法远程启动数据库
C:\Users\Administrator sqlplus sys/[email protected]:1521/orcl as sysdba

SQL*Plus: Release 11.2.0.4.0 Production on 星期四 7 月 20 14:26:57 2017

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

ERROR:
ORA-12514: TNS: 监听程序当前无法识别连接描述符中请求的服务

请输入用户名:

四:监听动态注册 + 静态注册

[oracle@chen admin]$ cat listener.ora 
SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (GLOBAL_DBNAME = orcl)
      (ORACLE_HOME = /u01/app/oracle/product/11.2.0.4)
      (SID_NAME = orcl)
    )
  )
LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = chen)(PORT = 1521))
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    )
  )

[oracle@chen admin]$ lsnrctl status
……  
Services Summary…
Service orcl has 2 instance(s).
  Instance orcl , status
UNKNOWN, has 1 handler(s) for this service…
  Instance orcl , status
READY, has 1 handler(s) for this service…
Service orclXDB has 1 instance(s).
  Instance orcl , status
READY, has 1 handler(s) for this service…
The command completed successfully

可以远程启动数据库
C:\Users\Administrator sqlplus sys/[email protected]:1521/orcl as sysdba

SQL*Plus: Release 11.2.0.4.0 Production on 星期四 7 月 20 14:22:59 2017

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

已连接到空闲例程。

SQL
startup
ORACLE 例程已经启动。

Total System Global Area  839282688 bytes
Fixed Size                  2257880 bytes
Variable Size             545262632 bytes
Database Buffers          289406976 bytes
Redo Buffers                2355200 bytes
数据库装载完毕。
数据库已经打开。官方文档位置如下:
Oracle Database Net Services Reference
http://docs.oracle.com/cd/E11882_01/network.112/e10835/listener.htm#NETRF008
Oracle Net Listener Parameters (listener.ora)
http://docs.oracle.com/cd/E11882_01/network.112/e10835/listener.htm#NETRF008

关于“如何监听 Oracle”这篇文章就分享到这里了,希望以上内容可以对大家有一定的帮助,使各位可以学到更多知识,如果觉得文章不错,请把它分享出去让更多的人看到。

正文完
 
丸趣
版权声明:本站原创文章,由 丸趣 2023-07-17发表,共计4611字。
转载说明:除特殊说明外本站除技术相关以外文章皆由网络搜集发布,转载请注明出处。
评论(没有评论)
主站蜘蛛池模板: 久久精品一区二区三区资源网 | 一级毛片免费观看不卡的 | 四虎影视免费观看免费观看 | 亚洲熟妇无码av不卡在线播放 | 奇米一区二区三区四区久久 | 国产无遮挡无码视频在线观看 | 男人和女人做免费做爽爽视频 | 宅男666在线永久免费观看 | 国产成人久久精品亚洲小说 | a毛片基地免费全部香蕉 | 中文乱码在线观看 | 久久国产精品久久久 | 免费观看又色又爽又黄的韩国 | 欧美亚洲综合另类成人 | 国产女人aaa级久久久级 | 青青青在线观看国产精品 | 亚洲精品另类有吗中文字幕 | 亚洲好穴 | 中文字幕一区精品欧美 | 亚洲熟妇av日韩熟妇在线 | 国产精品久久久久久妇女 | 国内外爱鲁吧免费网 | 欧美人与物videos另类 | 中字幕人妻一区二区三区 | 一区二区三区不卡在线 | 天天鲁一鲁 | 国产高清在线精品一区二区三区 | 少妇人妻偷人精品免费视频 | 久久综合五月天 | 伊人色综合九久久天天蜜桃 | 欧洲美熟女乱又伦av影片 | 国产99在线播放 | 亚洲小视频在线播放 | 拔插拔插最新网址 | 日韩免费一区二区三区 | 露脸一二三区国语对白 | 久久人人爽人人人人片 | 日韩一级伦理片 | 久久久久亚洲av无码观看 | 亚洲精品乱码久久久久久麻豆 | 男女性杂交内射妇女bbwxz |