[oracle@yangtk2 ~]$ lsnrctl status LSNRCTL for Linux: Version 11.1.0.6.0 – Production on 01-SEP-2008 17:36:03 Copyright (c) 1991, 2007, Oracle. All rights reserved. Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521))) STATUS of the LISTENER ———————— Alias LISTENER Version TNSLSNR for Linux: Version 11.1.0.6.0 – Production Start Date 01-SEP-2008 17:01:31 Uptime 0 days 0 hr. 34 min. 32 sec Trace Level off Security ON: Local OS Authentication SNMP OFF Listener Parameter File /data/oracle/product/11.1/network/admin/listener.ora Listener Log File /data/oracle/diag/tnslsnr/yangtk2/listener/alert/log.xml Listening Endpoints Summary… (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.25.1.104)(PORT=1521))) The listener supports no services The command completed successfully |
检查listener.ora和tnsnames.ora都未发现异常:
[oracle@yangtk2 admin]$ more listener.ora # listener.ora Network Configuration File: /data/oracle/product/11.1/network/admin/listener.ora # Generated by Oracle configuration tools. LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = 192.25.1.104)(PORT = 1521)) ) ) [oracle@yangtk2 admin]$ more tnsnames.ora # tnsnames.ora Network Configuration File: /data/oracle/product/11.1/network/admin/tnsnames.ora # Generated by Oracle configuration tools. ORA11G_S = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.25.1.104)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = ora11g_s.ytk-thinkpad) ) ) ORA11G_P = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.25.1.102)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = ora11g_p.ytk-thinkpad) ) ) |
而且以前这个配置没有任何问题,就是这次启动虚机后才出现的问题。
查询了metalink,虽然上面记载了很多ORA-12514错误,但是没有发现什么有帮助的线索。
由于这个错误以前并没有出现,所以怀疑是最近修改了什么东西导致了这个问题。而启动之后做了唯一的修改就是修改了主机的IP地址。
通过ifconfig修改了主机IP地址,莫非是修改错误导致了问题,不过现在通过IP地址可以正常的登陆主机,而且tnsping也没有任何的问题:
[oracle@yangtk2 admin]$ tnsping ora11g_s TNS Ping Utility for Linux: Version 11.1.0.6.0 – Production on 01-SEP-2008 17:54:31 Copyright (c) 1997, 2007, Oracle. All rights reserved. Used parameter files: /data/oracle/product/11.1/network/admin/sqlnet.ora Used TNSNAMES adapter to resolve the alias Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.25.1.104)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = ora11g_s.ytk-thinkpad))) OK (0 msec) 最后检查listner的日志: [oracle@yangtk2 admin]$ tail -20 /data/oracle/diag/tnslsnr/yangtk2/listener/alert/log.xml type=’UNKNOWN’ level=’16’ host_id=’yangtk2.ytk-thinkpad’ host_addr=’172.25.4.70’> 01-SEP-2008 17:54:31 * ping * 0 type=’UNKNOWN’ level=’16’ host_id=’yangtk2.ytk-thinkpad’ host_addr=’172.25.4.70’> WARNING: Subscription for node down event still pending type=’UNKNOWN’ level=’16’ host_id=’yangtk2.ytk-thinkpad’ host_addr=’172.25.4.70’> 01-SEP-2008 17:58:24 * (CONNECT_DATA=(CID=(PROGRAM=)(HOST=yangtk2.ytk-thinkpad)(USER=oracle))(COMMAND=status)(ARGUMENTS=64)(SERVICE=LISTENER)(VERSION=185599488)) * status * 0 |
发现日志中的IP地址并没有改变,看来是修改IP的时候遗漏了什么位置。
检查HOSTS文件,发现里面的配置忘了进行修改:
[oracle@yangtk2 admin]$ more /etc/hosts # Do not remove the following line, or various programs # that require network functionality will fail. 172.25.4.70 yangtk2.ytk-thinkpad 127.0.0.1 localhost.localdomain localhost |
将hosts文件中的ip也修改为当前的IP后,问题解决。
[oracle@yangtk2 ~]$ lsnrctl stop LSNRCTL for Linux: Version 11.1.0.6.0 – Production on 01-SEP-2008 18:01:00 Copyright (c) 1991, 2007, Oracle. All rights reserved. Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521))) The command completed successfully [oracle@yangtk2 ~]$ lsnrctl start LSNRCTL for Linux: Version 11.1.0.6.0 – Production on 01-SEP-2008 18:01:10 Copyright (c) 1991, 2007, Oracle. All rights reserved. Starting /data/oracle/product/11.1/bin/tnslsnr: please wait… TNSLSNR for Linux: Version 11.1.0.6.0 – Production System parameter file is /data/oracle/product/11.1/network/admin/listener.ora Log messages written to /data/oracle/diag/tnslsnr/yangtk2/listener/alert/log.xml Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.25.1.104)(PORT=1521))) Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521))) STATUS of the LISTENER ———————— Alias LISTENER Version TNSLSNR for Linux: Version 11.1.0.6.0 – Production Start Date 01-SEP-2008 18:01:10 Uptime 0 days 0 hr. 0 min. 0 sec Trace Level off Security ON: Local OS Authentication SNMP OFF Listener Parameter File /data/oracle/product/11.1/network/admin/listener.ora Listener Log File /data/oracle/diag/tnslsnr/yangtk2/listener/alert/log.xml Listening Endpoints Summary… (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.25.1.104)(PORT=1521))) The listener supports no services The command completed successfully |
稍等一会,通过sqlplus连接数据库:
[oracle@yangtk2 ~]$ sqlplus sys/test@ora11g_s as sysdba SQL*Plus: Release 11.1.0.6.0 – Production on Mon Sep 1 18:03:16 2008 Copyright (c) 1982, 2007, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 – Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> |
我们一直都在努力坚持原创.......请不要一声不吭,就悄悄拿走。
我原创,你原创,我们的内容世界才会更加精彩!
【所有原创内容版权均属TechTarget,欢迎大家转发分享。但未经授权,严禁任何媒体(平面媒体、网络媒体、自媒体等)以及微信公众号复制、转载、摘编或以其他方式进行使用。】
微信公众号
TechTarget
官方微博
TechTarget中国
相关推荐
-
甲骨文自治数据库亮相 带来云计算新希望
早前甲骨文还不在云计算公司之列,而现在该公司正在迅速弥补其失去的时间。甲骨文的云计算核心是甲骨文自治数据库(O […]
-
2017年12月数据库流行度排行榜 定格岁末排名瞬间
数据库知识网站DB-engines最近更新的2017年12月份数据库流行度排名情况是否能提供更多的看点呢?TechTarget数据库网站将与您分享12月份的榜单排名情况,让我们拭目以待。
-
2017年11月数据库流行度排行榜 半数以上数据库积分减少
数据库知识网站DB-engines更新了2016年11月份的数据库流行度排行榜。TechTarget数据库网站将与您一同关注11月份的榜单排名情况。
-
控制合约 不再畏惧Oracle
许多公司都与Oracle有无限制授权协议,他们害怕离开这个协议,所以就证明他们在使用Oracle的软件,即使因为需求单独购买部分授权许可也可能总体是省钱的。