#[42.17] StatePacket null error spam on Linux VPS server causing lag

1 messages · Page 1 of 1 (latest)

karmic pewter
#

Hi, I’m trying to figure out the cause of a multiplayer crash and wanted to check if anyone has run into this before.

I’m getting this error when connecting to a dedicated server:

    java.lang.NullPointerException: Cannot invoke "Object.equals(Object)" because the return value of "zombie.characters.IsoGameCharacter.getCurrentState()" is null at StatePacket.apply(StatePacket.java:256). Message: Error with packet of type: State
    Stack trace:
        zombie.network.packets.actions.StatePacket.apply(StatePacket.java:256)
        zombie.network.packets.actions.StatePacket.processClient(StatePacket.java:132)
        zombie.network.PacketTypes$PacketType.onClientPacket(PacketTypes.java:999)
        zombie.network.GameClient.mainLoopHandlePacketInternal(GameClient.java:557)
        zombie.network.GameClient.mainLoopDealWithNetData(GameClient.java:540)
        zombie.network.GameClient.update(GameClient.java:387)
        zombie.GameWindow.logic(GameWindow.java:308)
        zombie.GameWindow.frameStep(GameWindow.java:801)
        zombie.GameWindow.mainThreadStep(GameWindow.java:579)
        zombie.MainThread.mainLoop(MainThread.java:69)
        java.base/java.lang.Thread.run(Unknown Source)```

What’s strange is:

- If I host a dedicated server on my **Windows PC** → everything works fine
- If I host the same setup on a **Linux VPS** → I get this error

So it only seems to happen on Linux.

I am using mods, but the exact same mod setup works perfectly on Windows, so I’m not sure if this is a Linux-related issue or something about how states are initialized/synced there.

Also, when connecting to the VPS server, this error keeps spamming in Zomboid/console.txt, and it seems to cause noticeable server lag.

This does NOT happen when hosting locally on Windows.

Has anyone seen this before, or know if this is a known issue with Build 42 on Linux servers?

Any ideas would really help ![nekocat_angel](https://cdn.discordapp.com/emojis/1476088690299375616.webp?size=128 "nekocat_angel")
grand dune
#

Some mods are not compatible on Linux specifically due to case sesitivity

#

Therefore the first thing to test is whether this issue happens with 0 mods

short zephyr
#

That would be my recommendation too. And then if we can confirm it doesn't occur with 0 mods, we would then go into cluster testing to figure out which mod or combination seems to be the culprit. Basically add a handful at a time back till the issues start again! if that makes sense.

karmic pewter
# grand dune Some mods are not compatible on Linux specifically due to case sesitivity

We’ve already implemented a script on our side (as shown) to fix case-sensitivity issues for XML files, particularly for AnimSets and animation-related paths.

However, if this issue also involves other asset types beyond .xml (such as textures, models, or clothing assets), then this becomes much harder to fully resolve on the server side alone.

Given that this has been reported since early Build 42.13 and is still present in 42.17, we’re wondering if there are any plans on the TIS side to improve handling for these cases (for example, fallback handling or more robust validation instead of causing null-related crashes).

karmic pewter
# short zephyr That would be my recommendation too. And then if we can confirm it doesn't occur...

That approach definitely makes sense, and I actually did something similar on a Windows environment to narrow things down before deploying to the Linux VPS.

However, the main limitation we’re facing right now is that the Linux server is live 24/7 with active players, so we’re not really able to freely disable all mods or perform proper cluster testing directly on that environment without disrupting everyone. Panda_cry

grand dune
#

Since you are on a VPS, you should have the freedom to easily do that

karmic pewter
grand dune
#

Since that is what the logs would imply, it is important to test new saves

karmic pewter
grand dune
# karmic pewter

I think I might need clarification in that case, do you mean that no players can join the server?

#

Since I have to rule out client issues first

karmic pewter
# grand dune I think I might need clarification in that case, do you mean that no players can...

Players can join the server normally, but they can’t really play because the game becomes very laggy due to this log spamming constantly.

When I test alone, the issue does not occur. However, as soon as other players join the server, this log starts spamming heavily—even if I’m just standing still.

It seems like this error is flooding the client logs and severely affecting the gameplay experience.

grand dune
#

I might suggest wiping everything and then retesting in that case

#

Wipe the whole server install, including SteamCMD itself

#

Then reinstall with SteamCMD

#

Also wipe the whole "Zomboid" folder (or move it somewhere as a backup)

#

Then start a server with all the default settings, no changes, this is for testing only

#

Then test if it happens

#

You can also send me the IP so I can test it

karmic pewter
# grand dune Then test if it happens

The issue still persists (yesterday I also tested on a Windows PC and encountered the same behavior as on the Linux VPS).

Today (in the evening, Thailand time), before following your suggested steps, I did the following:

  • Reinstalled SteamCMD
  • Reinstalled the PZ server
  • Deleted the entire "Zomboid" folder
  • Reinstalled the game
  • Unsubscribed from all Workshop mods

On the first run, I couldn’t join the server and encountered this log (just for your information):

ERROR: General      f:0 st:0> WorldDictionary.init> Exception thrown
    zombie.world.WorldDictionaryException: Missing dictionary string on client: NC_HandCraftPanelLayout at StringDictionary$StringRegister.parseLoadListClient(StringDictionary.java:183).
    Stack trace:
        zombie.world.StringDictionary$StringRegister.parseLoadListClient(StringDictionary.java:183)
        zombie.world.StringDictionary.parseRegisters(StringDictionary.java:276)
        zombie.world.WorldDictionary.init(WorldDictionary.java:324)
        zombie.iso.IsoWorld.init(IsoWorld.java:2250)
        zombie.gameStates.GameLoadingState$1.runInner(GameLoadingState.java:335)
        zombie.gameStates.GameLoadingState$1.run(GameLoadingState.java:295)
        java.base/java.lang.Thread.run(Unknown Source)
LOG  : General      f:0 st:0> WorldDictionary: Warning: error occurred loading dictionary!
ERROR: General      f:0 st:0> GameLoadingState$1.run> Exception thrown
    zombie.world.WorldDictionaryException: WorldDictionary: Cannot load world due to WorldDictionary error. at WorldDictionary.init(WorldDictionary.java:361).
    Stack trace:
        zombie.world.WorldDictionary.init(WorldDictionary.java:361)
        zombie.iso.IsoWorld.init(IsoWorld.java:2250)
        zombie.gameStates.GameLoadingState$1.runInner(GameLoadingState.java:335)
        zombie.gameStates.GameLoadingState$1.run(GameLoadingState.java:295)
        java.base/java.lang.Thread.run(Unknown Source)
LOG  : Lua          f:0 st:0> LuaEventManager: adding unknown event "OnPreUIDraw"
LOG  : Lua          f:0 st:0> LuaEventManager: adding unknown event "OnPostUIDraw"```

After that, I deleted:

- Zomboid\Saves\Multiplayer\servertest
- Zomboid\db

Then on the second run, when 3–4 players joined, the error `Cannot invoke "Object.equals(Object)"` started appearing again.