java.net.SocketTimeoutException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • [JIRA] (JENKINS-37894) Unmarshall error when provisoning instance
    via by rxim...@ciandt.com (JIRA),
  • I opted to provide slaves on demand using Amazon EC2 Plugin, but sometimes it takes 30+ minutes to spawn an Instance. All I have in Jenkins logs are some exceptions like the one below. Then.. with no apparent reason it works.. I don't know if it is a serious problem or not since the stacktrace is not clear to me. {code:java} Exception during provisioning com.amazonaws.AmazonClientException: Unable to unmarshall response (Read timed out). Response Code: 200, Response Text: OK at com.amazonaws.http.AmazonHttpClient.handleResponse(AmazonHttpClient.java:1219) at com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:874) at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:597) at com.amazonaws.http.AmazonHttpClient.doExecute(AmazonHttpClient.java:363) at com.amazonaws.http.AmazonHttpClient.executeWithTimer(AmazonHttpClient.java:329) at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:308) at com.amazonaws.services.ec2.AmazonEC2Client.invoke(AmazonEC2Client.java:13032) at com.amazonaws.services.ec2.AmazonEC2Client.describeImages(AmazonEC2Client.java:9133) at com.amazonaws.services.ec2.AmazonEC2Client.describeImages(AmazonEC2Client.java:12577) at hudson.plugins.ec2.SlaveTemplate.getAmiBlockDeviceMappings(SlaveTemplate.java:671) at hudson.plugins.ec2.SlaveTemplate.getNewEphemeralDeviceMapping(SlaveTemplate.java:628) at hudson.plugins.ec2.SlaveTemplate.setupEphemeralDeviceMapping(SlaveTemplate.java:658) at hudson.plugins.ec2.SlaveTemplate.provisionOndemand(SlaveTemplate.java:458) at hudson.plugins.ec2.SlaveTemplate.provision(SlaveTemplate.java:377) at hudson.plugins.ec2.EC2Cloud.getNewOrExistingAvailableSlave(EC2Cloud.java:515) at hudson.plugins.ec2.EC2Cloud.provision(EC2Cloud.java:532) at hudson.slaves.NodeProvisioner$StandardStrategyImpl.apply(NodeProvisioner.java:701) at hudson.slaves.NodeProvisioner.update(NodeProvisioner.java:307) at hudson.slaves.NodeProvisioner.access$000(NodeProvisioner.java:60) at hudson.slaves.NodeProvisioner$NodeProvisionerInvoker.doRun(NodeProvisioner.java:798) at hudson.triggers.SafeTimerTask.run(SafeTimerTask.java:50) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Caused by: com.ctc.wstx.exc.WstxIOException: Read timed out at com.ctc.wstx.sr.StreamScanner.throwFromIOE(StreamScanner.java:708) at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1086) at com.ctc.wstx.evt.WstxEventReader.peek(WstxEventReader.java:306) at com.amazonaws.transform.StaxUnmarshallerContext.nextEvent(StaxUnmarshallerContext.java:207) at com.amazonaws.services.ec2.model.transform.BlockDeviceMappingStaxUnmarshaller.unmarshall(BlockDeviceMappingStaxUnmarshaller.java:42) at com.amazonaws.services.ec2.model.transform.ImageStaxUnmarshaller.unmarshall(ImageStaxUnmarshaller.java:123) at com.amazonaws.services.ec2.model.transform.DescribeImagesResultStaxUnmarshaller.unmarshall(DescribeImagesResultStaxUnmarshaller.java:47) at com.amazonaws.services.ec2.model.transform.DescribeImagesResultStaxUnmarshaller.unmarshall(DescribeImagesResultStaxUnmarshaller.java:32) at com.amazonaws.http.StaxResponseHandler.handle(StaxResponseHandler.java:99) at com.amazonaws.http.StaxResponseHandler.handle(StaxResponseHandler.java:42) at com.amazonaws.http.AmazonHttpClient.handleResponse(AmazonHttpClient.java:1174) ... 27 more Caused by: java.net.SocketTimeoutException: Read timed out at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.read(SocketInputStream.java:152) at java.net.SocketInputStream.read(SocketInputStream.java:122) at sun.security.ssl.InputRecord.readFully(InputRecord.java:442) at sun.security.ssl.InputRecord.readV3Record(InputRecord.java:554) at sun.security.ssl.InputRecord.read(InputRecord.java:509) at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:946) at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:903) at sun.security.ssl.AppInputStream.read(AppInputStream.java:102) at org.apache.http.impl.io.AbstractSessionInputBuffer.fillBuffer(AbstractSessionInputBuffer.java:160) at org.apache.http.impl.io.SocketInputBuffer.fillBuffer(SocketInputBuffer.java:84) at org.apache.http.impl.io.AbstractSessionInputBuffer.read(AbstractSessionInputBuffer.java:206) at org.apache.http.impl.io.ChunkedInputStream.read(ChunkedInputStream.java:174) at org.apache.http.conn.EofSensorInputStream.read(EofSensorInputStream.java:137) at com.amazonaws.internal.SdkFilterInputStream.read(SdkFilterInputStream.java:72) at com.amazonaws.event.ProgressInputStream.read(ProgressInputStream.java:151) at java.io.FilterInputStream.read(FilterInputStream.java:107) at com.ctc.wstx.io.UTF8Reader.loadMore(UTF8Reader.java:365) at com.ctc.wstx.io.UTF8Reader.read(UTF8Reader.java:110) at com.ctc.wstx.io.ReaderSource.readInto(ReaderSource.java:84) at com.ctc.wstx.io.BranchingReaderSource.readInto(BranchingReaderSource.java:57) at com.ctc.wstx.sr.StreamScanner.loadMoreFromCurrent(StreamScanner.java:1046) at com.ctc.wstx.sr.StreamScanner.parseLocalName2(StreamScanner.java:1796) at com.ctc.wstx.sr.StreamScanner.parseLocalName(StreamScanner.java:1756) at com.ctc.wstx.sr.BasicStreamReader.handleStartElem(BasicStreamReader.java:2914) at com.ctc.wstx.sr.BasicStreamReader.nextFromTree(BasicStreamReader.java:2848) at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1019) ... 36 more {code}
    via by Rafael Ximenes,
    • java.net.SocketTimeoutException: Read timed out at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.read(SocketInputStream.java:152) at java.net.SocketInputStream.read(SocketInputStream.java:122) at sun.security.ssl.InputRecord.readFully(InputRecord.java:442) at sun.security.ssl.InputRecord.read(InputRecord.java:480) at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:934) at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:891) at sun.security.ssl.AppInputStream.read(AppInputStream.java:102) at org.apache.http.impl.io.SessionInputBufferImpl.streamRead(SessionInputBufferImpl.java:139) at org.apache.http.impl.io.SessionInputBufferImpl.fillBuffer(SessionInputBufferImpl.java:155) at org.apache.http.impl.io.SessionInputBufferImpl.readLine(SessionInputBufferImpl.java:284) at org.apache.http.impl.io.ChunkedInputStream.getChunkSize(ChunkedInputStream.java:266) at org.apache.http.impl.io.ChunkedInputStream.nextChunk(ChunkedInputStream.java:227) at org.apache.http.impl.io.ChunkedInputStream.read(ChunkedInputStream.java:186) at org.apache.http.conn.EofSensorInputStream.read(EofSensorInputStream.java:137) at java.util.zip.InflaterInputStream.fill(InflaterInputStream.java:238) at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:158) at java.util.zip.GZIPInputStream.read(GZIPInputStream.java:116) at java.io.FilterInputStream.read(FilterInputStream.java:107) at org.apache.http.client.entity.LazyDecompressingInputStream.read(LazyDecompressingInputStream.java:67) at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:1792) at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:1769) at org.apache.commons.io.IOUtils.copy(IOUtils.java:1744) at org.apache.commons.io.IOUtils.toByteArray(IOUtils.java:462)

    Users with the same issue

    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    tvrmsmithtvrmsmith
    2 times, last one,
    bernardpaulusbernardpaulus
    2 times, last one,
    149 more bugmates