Jump to content

Netty Update on Forge Server


hakasapl

Recommended Posts

Hello all,

I run a server with a few of my friends with many many mods on it, and I have recently come across the issue where players will randomly disconnect with the error:

io.netty.channel.unix.Errors$NativeIoException

Sometimes this would happen when they first signed in, or after hours of playing, it would happen completely randomly.

I did my research, and many people were updating Netty to fix this issue. I went ahead and downloaded the newest final version of Netty from here, and I put the "all-in-one" jar file into my minecraft server folder. I then ran the following startup parameter to start the server:

java -cp netty-all-4.1.25.Final.jar:forge-universal.jar net.minecraft.server.MinecraftServer --nogui

(I renamed my forge universal jar into that simpler version)

I quickly realized that this would only launch the vanilla version of the server and not the forge version, so I went out looking for how to update it on forge servers, with no luck, which is why I am here.

Any help would be greatly appreciated and I will leave all of my information below!

 

Forge Version: 14.23.4.2705 (1.12.2)

OS: Ubuntu 16.04 LTS (Running on a Dedicated Server)

 

- Hakan S.

Link to comment
Share on other sites

You can't just update a library by putting it in the mods folder. The people updating netty were most definitely not using it for Minecraft related projects. The only way you could update net is if you made a PR into the forge Github with the updated library and all the fixes that need to go with it but it probably will never get approved because it will break mods and such probably making your situation worse. The error you most likely are experiencing is usually related to slow internet speeds. Try connecting all the computers over ethernet if you are in the same building or host it somewhere with a better internet connection. If this advice doesn't solve your issue please post the client and server logs.

Link to comment
Share on other sites

You should be able to just do java -cp {netty} -jar {forge} --nogui

If not Forge's server main class is net.minecraftforge.fml.relauncher.ServerLaunchWrapper

But you'll need to add every other library to the classpath. The server's MANIFEST file specifies all this.

  • Thanks 1

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Link to comment
Share on other sites

  • 3 months later...
Quote

You should be able to just do java -cp {netty} -jar {forge} --nogui

I tested this out, and after a few hours my server still became unreachable.

 

Quote

But you'll need to add every other library to the classpath. The server's MANIFEST file specifies all this.

Just to clarify, this would be the proper format for that?

Spoiler

java -d64 -Xms4G -Xmx4G -cp netty-all-4.1.25.Final.jar;forge-1.12.2-14.23.4.2759-universal.jar net.minecraftforge.fml.relauncher.ServerLaunchWrapper libraries/net/minecraft/launchwrapper/1.12/launchwrapper-1.12.jar libraries/org/ow2/asm/asm-all/5.2/asm-all-5.2.jar libraries/org/jline/jline/3.5.1/jline-3.5.1.jar libraries/net/java/dev/jna/jna/4.4.0/jna-4.4.0.jar libraries/com/typesafe/akka/akka-actor_2.11/2.3.3/akka-actor_2.11-2.3.3.jar libraries/com/typesafe/config/1.2.1/config-1.2.1.jar libraries/org/scala-lang/scala-actors-migration_2.11/1.1.0/scala-actors-migration_2.11-1.1.0.jar libraries/org/scala-lang/scala-compiler/2.11.1/scala-compiler-2.11.1.jar libraries/org/scala-lang/plugins/scala-continuations-library_2.11/1.0.2/scala-continuations-library_2.11-1.0.2.jar libraries/org/scala-lang/plugins/scala-continuations-plugin_2.11.1/1.0.2/scala-continuations-plugin_2.11.1-1.0.2.jar libraries/org/scala-lang/scala-library/2.11.1/scala-library-2.11.1.jar libraries/org/scala-lang/scala-parser-combinators_2.11/1.0.1/scala-parser-combinators_2.11-1.0.1.jar libraries/org/scala-lang/scala-reflect/2.11.1/scala-reflect-2.11.1.jar libraries/org/scala-lang/scala-swing_2.11/1.0.1/scala-swing_2.11-1.0.1.jar libraries/org/scala-lang/scala-xml_2.11/1.0.2/scala-xml_2.11-1.0.2.jar libraries/lzma/lzma/0.0.1/lzma-0.0.1.jar libraries/net/sf/jopt-simple/jopt-simple/5.0.3/jopt-simple-5.0.3.jar libraries/java3d/vecmath/1.5.2/vecmath-1.5.2.jar libraries/net/sf/trove4j/trove4j/3.0.3/trove4j-3.0.3.jar libraries/org/apache/maven/maven-artifact/3.5.3/maven-artifact-3.5.3.jar minecraft_server.1.12.2.jar nogui
pause

As taken from the manifest. It does launch, I just haven't gotten around to waiting for the server to be up for several hours again.

Edited by Swampfox
Link to comment
Share on other sites

  • 1 year later...
On 6/4/2018 at 11:50 PM, LexManos said:

You should be able to just do java -cp {netty} -jar {forge} --nogui

If not Forge's server main class is net.minecraftforge.fml.relauncher.ServerLaunchWrapper

But you'll need to add every other library to the classpath. The server's MANIFEST file specifies all this.

 Sorry to pull this out again but I am having the same issue. Where can I find the servers MANIFEST file?

 

Any help is appreciated!

Link to comment
Share on other sites

  • Guest locked this topic
Guest
This topic is now closed to further replies.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • I want to download Forge 1.20.6, but when I press download, it redirects me to Adfocus and does not provide any download. I have never encountered such a problem when I downloaded Forge 1.18.2 at least 12 months ago.
    • did you find any solutions? i have the same problem and also that mahito doesnt transform
    • Here's a simple example to solve this particular issue: public class ModArmorMaterials { public static final DeferredRegister<ArmorMaterial> ARMORS = DeferredRegister.create(Registries.ARMOR_MATERIAL, MyModName.MOD_ID); public static final RegistryObject<ArmorMaterial> COPPER = registerArmor("copper", Util.make(new EnumMap<>(ArmorItem.Type.class), enumMap -> { enumMap.put(ArmorItem.Type.BOOTS, 1); enumMap.put(ArmorItem.Type.LEGGINGS, 4); enumMap.put(ArmorItem.Type.CHESTPLATE, 5); enumMap.put(ArmorItem.Type.HELMET, 2); enumMap.put(ArmorItem.Type.BODY, 4); }), 12, SoundEvents.ARMOR_EQUIP_IRON, 0.0F, 0.0F, () -> Ingredient.of(Items.COPPER_INGOT)); private static RegistryObject<ArmorMaterial> registerArmor(String pGroup, EnumMap<ArmorItem.Type, Integer> pEnumMap, int pEnchantmentValue, Holder<SoundEvent> pEquipSound, float pToughness, float pKnockbackResistance, Supplier<Ingredient> pRepairIngredient) { List<ArmorMaterial.Layer> pLayerList = List.of(new ArmorMaterial.Layer(new ResourceLocation(pGroup))); return registerArmor(pGroup, pEnumMap, pEnchantmentValue, pEquipSound, pToughness, pKnockbackResistance, pRepairIngredient, pLayerList); } private static RegistryObject<ArmorMaterial> registerArmor( String pGroup, EnumMap<ArmorItem.Type, Integer> pEnumMap, int pEnchantmentValue, Holder<SoundEvent> pEquipSound, float pToughness, float pKnockbackResistance, Supplier<Ingredient> pRepairIngredient, List<ArmorMaterial.Layer> pLayerList) { return ARMORS.register(pGroup, () -> new ArmorMaterial(pEnumMap, pEnchantmentValue, pEquipSound, pRepairIngredient, pLayerList, pToughness, pKnockbackResistance)); } public static void register(IEventBus eventBus) { ARMORS.register(eventBus); } } Essentially, the TierSortingRegistry has been removed and so you now need to set up your own DeferredRegister. Please see the minecraftforge GitHub for more information; I found this solution through their issues (https://github.com/MinecraftForge/MinecraftForge/issues/9961)
    • How did I even leave that in there? I’ll try it in a bit, that very well could be it.
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.