Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-18269

recv failed Exception related to mobs and/or network traffic

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • None
    • Minecraft 1.5.2
    • Unconfirmed
    • Survival

      Ever since v1.4, this "Software caused connection abort: recv failed" error started happening on a fairly regular basis.

      It seemed to be happening in areas containing excessive mobs, which probably contributes to the issue, due to network activity. However, the error does not appear to be related to the operation of the game at all, but related to a threaded background process, that checks your servers for a flag that an updated version is available.

      Simply trapping for this error will make a tremendous number of people happy. I can't count the number of people who have been complaining about this very error, with no clue why it's happening.

      There is no exception created when this happens. The client simply throws up the error message on the screen and allows you to return to the main menu. However, I run my Minecraft with a batch file that kicks Java off with additional memory activated. So I see the exception text come across in that window and have copied-n-pasted it below.

      java.net.SocketException: Software caused connection abort: recv failed
              at java.net.SocketInputStream.socketRead0(Native Method)
              at java.net.SocketInputStream.read(Unknown Source)
              at java.net.SocketInputStream.read(Unknown Source)
              at java.io.FilterInputStream.read(Unknown Source)
              at ei.a(SourceFile:185)
              at ci.i(SourceFile:250)
              at ci.c(SourceFile:16)
              at cj.run(SourceFile:94)
      
      java.io.FileNotFoundException: http://assets.minecraft.net/1_6_has_been_released.flag
              at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
              at kn.a(SourceFile:234)
              at bkg.run(SourceFile:113)
              at java.lang.Thread.run(Unknown Source)
      

      This problem appears to be related to mobs. I notice it most when attempting to breed sheep.

      I created a grid of 16 pens to hold sheep. I laid the pens out so that every other pen began on a new chunk line (block 0), and ran the full length of a chunk in the other direction. (7x15 to account for walls) Spanning 8 chunks. (to ensure that the sheep/chunk was consistent)

      I put 2 sheep in each pen and bred them consecutively with the following numbers of resulting sheep (3, 4, 6, 9) and the resulting numbers of baby sheep occurring during the breeding process (1, 1, 2, 3)

      Given the fact that this process was occurring on the factor of 16 (each color), the total numbers for the 8 chunks is as follows:

      Breeding phase 1: 16 Sheep, 8 Babies
      Breeding phase 2: 24 Sheep, 8 Babies
      Breeding phase 3: 32 Sheep, 16 Babies
      Breeding phase 4: 48 Sheep, 24 Babies

      At phase 4, the error starts occurring, and upon reconnecting, some of the new baby sheep were lost.

      Given the fact that the sheep mobs have nothing to do with the http get to the version update flag, I can only assume that it has to do with memory and/or thread issues relating to mobs, or the sheer amount of network traffic generated to the server to track the mobs. Either the "mature to adult" event, the "eating" event, the baby mob sound, collision detection, something...

      It seems to me that something is leaving a socket, thread, or memory in a bad state, which adversely affects the http get version check process.

      I assume this because if I only breed 2 sheep of each color on each phase (instead of all available), and never get above 16 Babies at a time, I can continue to breed sheep on up to about 11 sheep per pen. After all sheep mature, I am safe to breed another sheep of each color. I have not moved past 11 sheep of each color (176 Sheep in 8 chunks)

      However, whenever I am within range of those chunks so that they are loaded, I do run a risk of getting the socket error. It happens from time to time. Babies or no babies...

      I hope this information is useful in tracking down this very annoying issue. From what I have heard in the community, this problem affects a large base of users, and many people are getting rather frustrated with the situation. If you need anything specific from me, please don't hesitate to ask.

      NOTE: I tried this in a single-player world, and the problem did not occur. I will attach a Zip of that world, so you can have an example of the sheep farm I am experiencing this issue with

      I have attached a 1.5.2 World Save from Single Player, with a sheep farm, that, when built on a server in SMP, causes these exceptions to occur fairly regularly.

        1. POC-SocketError.zip
          350 kB
        2. screenshot-1.jpg
          screenshot-1.jpg
          109 kB
        3. screenshot-2.jpg
          screenshot-2.jpg
          137 kB

            Unassigned Unassigned
            Todd.Powers Todd Powers
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: