免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1805 | 回复: 4
打印 上一主题 下一主题

请教一个网络连接的问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2006-08-08 22:59 |只看该作者 |倒序浏览
hostnameramain IP:210.35.207.32  SID:stby 在这台机上连本地库或连IP为33的库都成功
hostnamerastanby IP:210.35.207.33  SID:tt 在这台机上连本地库成功,但连IP为32的库却不成功
下面给出了两台的listener.ora 和tnsnames.ora文件
33上的数据库版本是9.2.0.2
32上的数据库版本是9.2.0.4
请问是什么原因连接不上呢?????

[oracle@oramain admin]$ more listener.ora
STENER.ORA Network Configuration File: /opt/oracle/product/9.2.0.4/network/admin/listener.ora
# Generated by Oracle configuration tools.

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = /opt/oracle/product/9.2.0.4)
      (PROGRAM = extproc)
    )
  )
SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = stby)
      (ORACLE_HOME = /opt/oracle/product/9.2.0.4)
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = 210.35.207.32)(PORT = 1521))
      )
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
      )
    )
  )


[oracle@oramain admin]$ more tnsnames.ora
# TNSNAMES.ORA Network Configuration File: /opt/oracle/product/9.2.0.4/network/admin/tnsnames.ora
# Generated by Oracle configuration tools.

oramain =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = tcp)
                 (HOST=210.35.207.32)
                 (PORT=1521)
      )
    )
    (CONNECT_DATA =
      (SID = stby)
    )
  )

orastanby =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = tcp)
                 (HOST=210.35.207.33)
                 (PORT=1521)
      )
    )
    (CONNECT_DATA =
      (SID = tt)
    )
  )
[oracle@oramain admin]$


[oracle@oramain admin]$ sqlplus "sys/oracle@oramain as sysdba"

SQL*Plus: Release 9.2.0.2.0 - Production on Tue Aug 8 22:41:48 2006

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.


Connected to:
Oracle9i Enterprise Edition Release 9.2.0.2.0 - 64bit Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.2.0 - Production

SQL> exit
Disconnected from Oracle9i Enterprise Edition Release 9.2.0.2.0 - 64bit Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.2.0 - Production
[oracle@oramain admin]$ sqlplus "sys/change_on_install@orastanby as sysdba"

SQL*Plus: Release 9.2.0.2.0 - Production on Tue Aug 8 22:42:46 2006

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.


Connected to:
Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production

SQL> exit
Disconnected from Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production



[oracle@orastanby admin]$ more listener.ora
# LISTENER.ORA Network Configuration File: /opt/oracle/product/9.2.0.4/network/admin/listener.ora
# Generated by Oracle configuration tools.

SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = /opt/oracle/product/9.2.0.4)
      (PROGRAM = extproc)
    )
  )
SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = tt)
      (ORACLE_HOME = /opt/oracle/product/9.2.0.4)
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = TCP)(HOST = 210.35.207.33)(PORT = 1521))
      )
      (ADDRESS_LIST =
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
      )
    )
  )

[oracle@orastanby admin]$ more tnsnames.ora

orastanby=
    (DESCRIPTION =
       (ADDRESS_LIST =
         (ADDRESS=
            (PROTOCOL=tcp)(HOST=210.35.207.33) (PORT=1521)
         )
       )
       (CONNECT_DATA =
         (SID = tt)
       )
    )

oramain =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = tcp)
                 (HOST=210.35.207.32)
                 (PORT=1521)
      )
    )
    (CONNECT_DATA =
      (SID = stby)
    )
  )
[oracle@orastanby admin]$ sqlplus "sys/change_on_install@orastanby as sysdba"

SQL*Plus: Release 9.2.0.4.0 - Production on Tue Aug 8 22:50:03 2006

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.


Connected to:
Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production

SQL> exit
Disconnected from Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.4.0 - Production
[oracle@orastanby admin]$ sqlplus "sys/oracle@oramain as sysdba"

SQL*Plus: Release 9.2.0.4.0 - Production on Tue Aug 8 22:50:09 2006

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

ERROR:
ORA-12560: TNS:protocol adapter error


Enter user-name:
ERROR:
ORA-01017: invalid username/password; logon denied


Enter user-name:
ERROR:
ORA-01017: invalid username/password; logon denied


SP2-0157: unable to CONNECT to ORACLE after 3 attempts, exiting SQL*Plus
[oracle@orastanby admin]$

论坛徽章:
0
2 [报告]
发表于 2006-08-08 23:23 |只看该作者
本机连接走的是IPC,还有其他客户端能否正常连到32的机器上?

论坛徽章:
0
3 [报告]
发表于 2006-08-08 23:33 |只看该作者
把oramain的tnsnames.ora复制到orastandy上
在两个节点上都用下面命令试一下
tnsping oramain
tnsping orastanby

论坛徽章:
0
4 [报告]
发表于 2006-08-08 23:50 |只看该作者
oramain都通
orastanby TNSPING到ORAMAIN上不通


[oracle@oramain ~]$ tnsping orastandby

TNS Ping Utility for Linux IA64: Version 9.2.0.2.0 - Production on 08-AUG-2006 23:46:33

Copyright (c) 1997 Oracle Corporation.  All rights reserved.

Used parameter files:
/opt/oracle/product/9.2.0.4/network/admin/sqlnet.ora

TNS-03505: Failed to resolve name
[oracle@oramain ~]$ tnsping orastanby

TNS Ping Utility for Linux IA64: Version 9.2.0.2.0 - Production on 08-AUG-2006 23:46:41

Copyright (c) 1997 Oracle Corporation.  All rights reserved.

Used parameter files:
/opt/oracle/product/9.2.0.4/network/admin/sqlnet.ora


Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = tcp) (HOST=210.35.207.33) (PORT=1521))) (CONNECT_DATA = (SID = tt)))
OK (0 msec)
[oracle@oramain ~]$



[oracle@orastanby oracle]$ tnsping orastanby

TNS Ping Utility for Linux: Version 9.2.0.4.0 - Production on 08-AUG-2006 23:47:48

Copyright (c) 1997 Oracle Corporation.  All rights reserved.

Used parameter files:


Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS= (PROTOCOL=tcp)(HOST=210.35.207.33) (PORT=1521))) (CONNECT_DATA = (SID = tt)))
OK (0 msec)
[oracle@orastanby oracle]$ tnsping oramain

TNS Ping Utility for Linux: Version 9.2.0.4.0 - Production on 08-AUG-2006 23:47:57

Copyright (c) 1997 Oracle Corporation.  All rights reserved.

Used parameter files:


Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = tcp) (HOST=210.35.207.32) (PORT=1521))) (CONNECT_DATA = (SID = stby)))
TNS-12560: TNS:protocol adapter error
[oracle@orastanby oracle]$

论坛徽章:
0
5 [报告]
发表于 2006-08-09 00:17 |只看该作者
[size=-1]晕死,,我的刚才问题解决了,,原来 是没把ORAMAIN这台机的防火墙给关掉

已经第二次了,,记性不好


谢啦,,各位
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP