SpongePowered / SpongeForge

A Forge mod that implements SpongeAPI
http://www.spongepowered.org/
MIT License
1.14k stars 306 forks source link

World Corruption? #3220

Closed Shinesprite41 closed 4 years ago

Shinesprite41 commented 4 years ago

I am currently running I just haven't had a chance to update to the latest version of 1.12.2 spongeforge, which hasn't had any issues until now anyways. The server runs Pixelmon Reforged (version 8.0.2 still, I plan on updating this weekend)

/sponge mods: Minecraft, Minecraft Coder Pack, Forge Mod Loader, Minecraft Forge, SpongeAPI, Sponge, AquaAuras, AquaVaults, Biomes O' Plenty, FlashPlus, FlashSpec, In-game NBTEdit, Pixel Extras, Pixelmon, Pixelmon Reforged Additions, Pixelmon Trainer Commands, ShopKeeperLogger, SpongeForge, Unbreed, Wondertrade, WorldEdit

We had used the /worlds command provided by ProjectWorlds to create multiple worlds (in essence, creating another version of the main overworld you spawn in at, but with specifications such as being completely void or a world with only biomes o' plenty biomes.) These worlds existed for probably 6 months perfectly fine. Then, on some day between the 20th and 23rd (today), all the non-standard worlds (including the Ultra Space biome from Pixelmon) and the PvP world (a void world that was supposed to have a PvP area, but the build itself is gone. Not sure if this was due to the same issue or if this was done on purpose) just don't load and aren't accessible. They are still inside our "world" folder in the files, but they essentially just don't exist on the server. I tried recreating it with a "test123" world, but was unable to, as it is still accessible. None of the files were touched previously to the 20th, and as far as I'm aware, the only changes made was a build team staff member going into the "bop" world we had (biomes o' plenty biomes only) and working on a build inside of it. The only one accessible to the general public that is missing is the bop world. I am pretty sure the issue started on the 22nd, though, because if I look in the world folder (image below), it has a file called "level_sponge.dat.corrupted-2020-10-23T023209.796Z.dat" updated on the 22nd. It has nothing inside it, though. image

This was the entire start-up log. After this, FuzzledPukka joined the server, and then I restarted the server again to check the "test123" world https://gist.github.com/Shinesprite41/273780eb9fa70b74da95695f6e004dd4

dualspiral commented 4 years ago

I helped in Discord. I'm going to close this but I'll explain why in detail in case I need to point someone else to it.

Basically, we don't know, and while it's a strange reason for closing an issue, we have found no reason as to how Sponge could be doing this. We have mitigated this almost to death, and at least for level_sponge.dat, we restore from a backup. We found that for OP that there are non-zero length files that are the backed up dat files and they should be safe to use, preventing the data loss that could have occurred.

Do note that we recommend that you use 7.3.0 - we added additional safeguards in later versions than you are running.

While investigating this, I found that one possible culprit could be ProjectWorlds. It does dangerous operations on the level.dat and level_sponge.dat files when it thinks that things are out of sync during plugin construction, but it doesn't really know anything about the system it runs on so it could think that things are out of sync every time and cause failures. This can be particularly noticible if ProjectWorlds sets a dimension ID that a mod was claiming in a previous run, though I do not claim to know enough about the world manager to know.

However, I must stress that we've seen this error with players who do not have ProjectWorlds installed, so I cannot pin it on that - it is a potential factor though.