How do I troubleshoot "socket closed" errors?

  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord

Omicron

New Member
Jul 29, 2019
2,974
0
0
I have a server based on Techworld 2 (but with updated mod versions) that I play on with a friend - there's just the two of us. I start it up only when both of us have time to play together. For the first two evenings, this ran fine. Then sometime in the middle of the third, my friend started to get booted randomly with a "socket closed" error. This persisted even through restarting the server, and eventually, I got one too (and then the server became unresponsive).

I have hosted Minecraft servers for friends for nearly 3 years now. I have never once seen this error before. Also, I'm currently derping around on the server doing some thing that my friend said he was doing while crashing, and I absolutely cannot reproduce it. But we had at least 10 of them yesterday. No changes were made to the server, not before, not after.

I did notice that in the DOS window that runs alongside the standard server window, there was some java error spam when my friend disconnected. Unfortunately it seems that the output in that window isn't logged anywhere - it's not in server.log, and it's not in ForgeModLoader-server-0.log. My clientside logs show nothing either. That's the reason why I only remember "socket closed", it showed on screen ingame when I got disconnected but I can't actually find the exact error message logged anywhere.

How would I go about troubleshooting this issue? What usually causes this?
 

Omicron

New Member
Jul 29, 2019
2,974
0
0
An update:

This was super hard to get a hold on, but at the moment I am fairly convinced that this is a Java 8 issue. Not 8.20 mind you, I'm well aware that that doesn't work; I have 8.05 in use right now. And it works quite well, really. No issues.

Except when you try and use the "-XX:+UseConcMarkSweepGC" switch.

I ultimately managed to narrow it down to this. It seems that it causes a whole host of miscellaneous, random server instabilities when set, not limited just to socket errors. Removing it has made the server much more stable, and migrating to Cauldron removed any need for performance boosting java arguments anyway.