English 中文(简体)
是什么原因可以使联合选举机制无法在负荷下解决英国航天中心问题?
原标题:What can cause the JVM to fail to resolve DNS under load?

我用我们的服务来调查一个问题,因为这一问题未能在负荷下解决3个桶。

I m 强调单一1.medium ec2例:

root@ip-10-243-126-111:/mnt/log# uname -a
Linux ip-10-243-126-111 2.6.35-30-virtual #56-Ubuntu SMP Mon Jul 11 23:41:40 UTC 2011 i686 GNU/Linux
root@ip-10-243-126-111:/mnt/log# cat /etc/issue
Ubuntu 10.10 
 l
root@ip-10-243-126-111:/mnt/log# free
             total       used       free     shared    buffers     cached
Mem:       1746008    1681752      64256          0      29600    1582508
-/+ buffers/cache:      69644    1676364
Swap:       917500         32     917468

该申请使用-server, jvm Building 1.6.0_23-b05, 32bit

I m 看到的行为是网络通信开始成为“现实”,有时从我们的刚果人联系驱动力中抽出时间,例如:

Caused by: java.net.SocketTimeoutException: Read timed out
        at java.net.SocketInputStream.socketRead0(Native Method) ~[na:1.6.0_23]
        at java.net.SocketInputStream.read(SocketInputStream.java:129) ~[na:1.6.0_23]
        at java.io.BufferedInputStream.fill(BufferedInputStream.java:218) ~[na:1.6.0_23]
        at java.io.BufferedInputStream.read1(BufferedInputStream.java:258) ~[na:1.6.0_23]
        at java.io.BufferedInputStream.read(BufferedInputStream.java:317) ~[na:1.6.0_23]
        at org.bson.io.Bits.readFully(Bits.java:35) ~[mongo-java-driver-2.5.3.jar:na]
        at org.bson.io.Bits.readFully(Bits.java:28) ~[mongo-java-driver-2.5.3.jar:na]
        at com.mongodb.Response.<init>(Response.java:35) ~[mongo-java-driver-2.5.3.jar:na]
        at com.mongodb.DBPort.go(DBPort.java:110) ~[mongo-java-driver-2.5.3.jar:na]
        at com.mongodb.DBPort.go(DBPort.java:75) ~[mongo-java-driver-2.5.3.jar:na]
        at com.mongodb.DBPort.call(DBPort.java:65) ~[mongo-java-driver-2.5.3.jar:na]
        at com.mongodb.DBTCPConnector.call(DBTCPConnector.java:201) ~[mongo-java-driver-2.5.3.jar:na]
        ... 43 common frames omitted

有时发生下列情况:

Caused by: java.net.UnknownHostException: bucket-system.s3.amazonaws.com
        at java.net.InetAddress.getAllByName0(InetAddress.java:1158) ~[na:1.6.0_23]
        at java.net.InetAddress.getAllByName(InetAddress.java:1084) ~[na:1.6.0_23]
        at java.net.InetAddress.getAllByName(InetAddress.java:1020) ~[na:1.6.0_23]
        at org.apache.http.impl.conn.DefaultClientConnectionOperator.resolveHostname(DefaultClientConnectionOperator.java:242) ~[httpclient-4.1.jar:4.1]
        at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:130) ~[httpclient-4.1.jar:4.1]
        at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:149) ~[httpclient-4.1.jar:4.1]
        at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:121) ~[httpclient-4.1.jar:4.1]
        at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:562) ~[httpclient-4.1.jar:4.1]
        at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:415) ~[httpclient-4.1.jar:4.1]
        at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:820) ~[httpclient-4.1.jar:4.1]
        at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:754) ~[httpclient-4.1.jar:4.1]
        at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:732) ~[httpclient-4.1.jar:4.1]
        at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:240) ~[aws-java-sdk-1.2.5.jar:na]
        ... 48 common frames omitted

这样做是不可推卸的,但并不一致。 一旦机器上装货(50份同时用http://www.un.org/www.un.org/Depts/html),机器就在每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台每台

怎样才能造成这种行为? 是否有任何限制或其他制度,使我可以设法改进这方面的情况? 寻找烟lu的更重要之处?

另一种选择 我怀疑的是亚马孙(东北1区)的基础设施,我怀疑路由者在服务上积极推行某种预防家庭暴力的政策,因为要求几乎立即从0到50。 一段时间后,它稳定在50个同时率上,此时,硬件调整适应新交通。 远远没有根据? 我没有发现任何提到这种模式的地方。

最佳回答

Looks like you are trying to just DoS the amazon DNS servers. Cache the IP of the host you re trying to reach and periodically update the cache. This will also increase overall performance of the application

Update: from the trace it s visible that the DNS host is just not responding to your requests. If you were to reach a ulimit, you would be faced with another Exception (something like unable to create socket).

问题回答

Are you simply running out of file descriptors? The first stack trace doesn t look anything DNS-specific.

What does ulimit -n say? Does the problem go away if you give your process a (much) higher open file descriptor limit?

(Open / half-closed sockets consume file descriptors).





相关问题
Spring Properties File

Hi have this j2ee web application developed using spring framework. I have a problem with rendering mnessages in nihongo characters from the properties file. I tried converting the file to ascii using ...

Logging a global ID in multiple components

I have a system which contains multiple applications connected together using JMS and Spring Integration. Messages get sent along a chain of applications. [App A] -> [App B] -> [App C] We set a ...

Java Library Size

If I m given two Java Libraries in Jar format, 1 having no bells and whistles, and the other having lots of them that will mostly go unused.... my question is: How will the larger, mostly unused ...

How to get the Array Class for a given Class in Java?

I have a Class variable that holds a certain type and I need to get a variable that holds the corresponding array class. The best I could come up with is this: Class arrayOfFooClass = java.lang....

SQLite , Derby vs file system

I m working on a Java desktop application that reads and writes from/to different files. I think a better solution would be to replace the file system by a SQLite database. How hard is it to migrate ...

热门标签