- 浏览: 645242 次
- 性别:
- 来自: 北京
文章分类
- 全部博客 (608)
- Java (125)
- Struts (16)
- Spring (19)
- iBatis (11)
- Hibernate (14)
- Oracle (33)
- Mysql (22)
- JBoss (4)
- JavaScript (46)
- Ajax (9)
- jQuery (5)
- web (25)
- Html (14)
- Exception (26)
- Linux (106)
- Vim (11)
- Python (12)
- ComputerTech (25)
- 文章 (50)
- Maven (20)
- FreeMarker (5)
- Json (0)
- Tomcat (6)
- ActiveMQ (2)
- Test (1)
- Git (5)
- Shell (1)
- 《Java并发编程实践》 (2)
- 产品设计 (1)
- xxx (0)
- diamond (1)
- dubbo (1)
- Raspbian (1)
- IDE (3)
- 并发编程 (1)
最新评论
-
mikzhang:
抱歉,写这篇文章时,博主开发的程序只面对IE浏览器,故没考虑其 ...
JS 中改变confirm默认按钮提示“确定""取消" -
poterliu:
测试过了,发现execScript方法只支持IE浏览器。目前已 ...
JS 中改变confirm默认按钮提示“确定""取消"
PROBLEM | ||||
|
||||
REDISCOVERY |
||||
To verify whether you are hitting this problem, verify whether the Oracle
instance is configured for Multithreaded Server (MTS). If the Oracle instance is
not configured for MTS, you are probably encountering a different problem.
Otherwise, continue. Try forcing the JDBC connection to use a dedicated server
instead of a shared server. This can be accomplished in several ways. For JDBC
OCI or Thin, this can be done by reconfiguring the server for dedicated
connections only. This approach, however, may not be feasible in many cases. In
such cases, the following options apply: For JDBC OCI: |
||||
1) Add the (SERVER=DEDICATED) property to the TNS connect string stored in the tnsnames.ora file on the client. 2) Set the user_dedicated_server=ON in sqlnet.ora on the client.For JDBC Thin: You must specify a full name-value pair connect string (the same as it might appear in the tnsnames.ora file) instead of the short JDBC Thin syntax. For example, instead of "jdbc:oracle:thin:@host:port:sid" you would need to use a string of the form "jdbc:oracle:thin:@(DESCRIPTION=" + "(ADDRESS_LIST=" + "(ADDRESS=(PROTOCOL=TCP)" + "(HOST=host)" + = "(PORT=port)" + ")" + ")" + "(CONNECT_DATA=" + "(SERVICE_NAME=sid)" + "(SERVER=DEDICATED)" + ")" + ")" |
||||
If the connection works fine after having made these changes, it is very
likely that this is the problem you are encountering. In this case, one last
test will help to verify this fact.
Log into the remote host on which the Oracle instance is running and execute the appropriate command to determine what the server 'thinks' its hostname is (i.e. the name that was configured when the server was installed and configured). For example, on a Unix host the 'hostname' command can be used for this purpose. Using the name displayed (e.g. by the hostname command), exactly as it appeared (i.e. if the output from the hostname command had the domain name included, then include it), return to the client which was unable to connect and try pinging the server. NOTE: It is critical that you attempt to ping the server using EXACTLY the same hostname you got from the server. If you are unable to ping the server via this hostname, then you almost certainly hitting this problem. If not, this may be a new issue, but at least you will have found a workaround (i.e. use a dedicated connection). |
||||
EXPLANATION |
||||
To understand why this problem occurs, one must first understand the
differences in how the listener handles connections to shared servers versus
dedicated servers.
When connecting to a dedicated server, the client connects to the listener (via hostname or IP address). The listener then spawns a dedicated server process and hands off the socket used to accept the client connection to that server. The client and server then start communicating via the endpoints established by the initial connection. NOTE: There is only one connection in this case. When connecting to a shared server, the initial client connection to the listener is the same. However, with MTS, there is no need to spawn a new server process; a pool of shared processes already exists. Also, clients do not communicate directly with the server processes in MTS; rather, they communicate with a dispatcher. For this reason, when setting up an MTS connection, the listener sends a redirect message back to the client asking the client to close the connection to the listener and connect to a dispatcher. The information in this message includes the hostname and a port number for the appropriate dispatcher. The redirect message will ALWAYS specify a hostname, even if the client initially provided an IP address. If, for any reason, the hostname provided to the listener (e.g. by the 'hostname' or another command) doesn't agree with the hostname by which the server is known on the client, the connection fails. On the other hand, if "(SERVER=DEDICATED)" already appears in the TNS connect string in tnsnames.ora or if "use_dedicated_server=ON" already appears in the sqlnet.ora file, you may find that SQL*Plus and/or JDBC OCI work fine, while JDBC Thin fails. |
||||
SOLUTION |
||||
Obviously, one solution is to use dedicated servers. However, this may not
always be feasible.
The key is to make sure the hostname on both the client and server agree. This can be accomplished by reconfiguring either the client or the server, but there are things to be aware of in both cases. If the server is configured to return a different hostname, then it is possible that other clients which used to work will now fail. In some cases, it may not be feasible to reconfigure the client. For example, if the server version of the hostname does not include the domain, you would need to remove the domain portion of the hostname on the client; but, if the client needs to connect to more than one server with the same base name in different domains, this may not be possible, as the hostname may be ambiguous |
发表评论
-
Oracle_ojdbc6 使用 报错
2015-06-10 14:29 947via: http://sd8089730.iteye.c ... -
It is indirectly referenced from required .class file
2014-08-19 15:30 406via: http://www.blogjava.net/z ... -
Hibernate_a different object with the same identifier value was already associat
2014-07-05 17:03 479via: http://www.blogjava.net/h ... -
Connection reset by peer: socket write error
2013-03-14 10:24 822Connection reset by peer: soc ... -
java.sql.SQLException: 索引中丢失 IN 或 OUT 参数
2012-05-07 17:00 2525java.sql.SQLException: 索引中丢失 ... -
org.apache.coyote.tomcat5.CoyoteResponseFacade.sendRedirec
2012-03-19 15:25 1589【from http://www.cxy.me/bbs/vie ... -
request.getHeader("referer") is null
2012-03-19 15:23 921referer 用来判断上一页是不是自己的网站 如果我 ... -
ORA-14551: cannot perform a DML operation inside a query
2012-04-26 14:49 1055ORA-14551: cannot perform a ... -
Struts FileUpload - Processing of multipart/form-data request failed
2011-09-16 15:52 7262Struts FileUpload 异常处 ... -
HTTP Status 500 - No action instance for path could be created
2011-09-16 15:03 1678HTTP Status 500 - No action ... -
java.sql.SQLException: ORA-01830: date format picture ends before converting ent
2011-08-17 17:48 3366java.sql.SQLException: ORA-0 ... -
Bean property 'xxDao' is not writable or has an invalid setter method
2011-08-08 16:25 8696Bean property 'xxDao' is not ... -
SqlMapClient operation; uncategorized SQLException for SQL []; SQL state [null];
2011-08-04 15:38 2184网上解决方案 1.起初没有创建序列s_log,因此需要在Or ... -
org.xml.sax.SAXParseException: Document root element "struts-config", must match
2011-08-01 22:19 1645org.xml.sax.SAXParseException: ... -
Error creating form bean of class...
2011-08-01 10:44 976Error creating form bean of cla ... -
java.text.ParseException: Unparseable date: "11/10/10" at java.text.DateFormat.
2011-08-01 10:39 5561使用DateFormat的使用,然后自己试了下,结果出来个错误 ... -
[interceptor.FileUploadInterceptor:intercept] [Removing file filesXXX .tmp]
2011-07-25 11:18 4466上传完文件时控制台显示[interceptor.FileUpl ... -
The Network Adapter could not establish the connection
2011-07-15 17:05 12271、oracle配置 oracle9i2中把C:\ora ... -
java.sql.SQLException: ORA-00933: SQL 命令未正确结束
2011-06-30 12:16 2088java.sql.SQLException: ORA-0093 ... -
ORA-00942 Table or View Does Not Exist Oracle Error
2011-06-22 23:55 4411Cause: java.sql.SQLException: ...
相关推荐
Oracle Database Problem Solving and Troubleshooting Handbook
Oracle Database Problem Solving and Troubleshooting Handbook 英文epub 本资源转载自网络,如有侵权,请联系上传者或csdn删除 本资源转载自网络,如有侵权,请联系上传者或csdn删除
Oracle Database 21c 是最新的版本; 21.3 - 企业版(也包括标准版 2) 适用于Linux x86-64位系统。oracle-database-ee-21c-1.0-1.ol8文件分割成 三个 压缩包,必须集齐 三个 文件后才能一起解压一起使用: Oracle ...
Welcome to “Beginning SQL for Oracle Database 18C”! Thanks for picking up this book. It’s safe to say you’re interested in learning about Oracle database, as that’s what this book is about. Why ...
Oracle Database 19c 是最新的长期版本,支持期限最长; 19.3 - 企业版(也包括标准版 2) 适用于Linux x86-64系统。oracle-database-ee-19c文件分割成 三个 压缩包,必须集齐 三个 文件后才能一起解压一起使用: ...
Expert Oracle Database 11g Administration Expert Oracle Database 11g Administration
Oracle Database 21c 是最新的版本; 21.3 - 企业版(也包括标准版 2) 适用于Linux x86-64位系统。oracle-database-ee-21c-1.0-1.ol8文件分割成 三个 压缩包,必须集齐 三个 文件后才能一起解压一起使用: Oracle ...
Oracle Database 10g for Windows安装
Master Oracle Database 12c Release 2 Real Application Clusters with this comprehensive, fully updated guide Now you can maintain a dynamic enterprise computing infrastructure with expert instruction ...
Oracle Database Problem Solving and Troubleshooting Handbook 英文azw3 本资源转载自网络,如有侵权,请联系上传者或csdn删除 本资源转载自网络,如有侵权,请联系上传者或csdn删除
Practical Oracle Database Appliance Description: Practical Oracle Database Appliance is a hands-on book taking you through the components and implementation of the Oracle Database Appliance. Learn ...
Beginning Oracle Database 12c Administration, 2nd Edition
Oracle Database 19c 是最新的长期版本,支持期限最长; 19.3 - 企业版(也包括标准版 2) 适用于WINDOWS X64位系统。 WINDOWS.X64_193000_db_home文件分割成 三个 压缩包,必须集齐 三个 文件后才能一起解压一起...
第1章 Oracle Database 10g体系结构 第2章 安装Oracle Database 10g和创建数据库 第3章 升级到Oracle Database 10g 第4章 规划Oracle应用程序——方法、风险和标准 第Ⅱ部分 SQL和SQL*Plus 第5章 SQL中的基本语法 第...
Oracle Database 21c 是最新的版本; 21.3 - 企业版(也包括标准版 2) 适用于Linux x86-64位系统。oracle-database-ee-21c-1.0-1.ol8文件分割成 三个 压缩包,必须集齐 三个 文件后才能一起解压一起使用: Oracle ...
Now in its third edition, this best-selling book continues to bring you some of the best thinking on how to apply Oracle Database to produce scalable applications that perform well and deliver correct...
Oracle Database 12C 多租户,Amazon 5星,好书。 Master the Powerful Multitenant Features of Oracle Database 12c Govern a scalable, extensible, and highly available enterprise database environment ...
Oracle Database 11gR2性能调整与优化 Oracle Database 12cR2性能调整与优化(前78页,第一章内容完整)
applications based on the Oracle database. The book is basically a reflection of what I do every day and of the issues I see people encountering each and every day. I covered what I felt was most ...