Thanks for taking time to explore my world and for the redstone breaking tip. It worked for those areas with redstone. My giant prison is no longer laggy, but I still have one problem. The spawn is laggy and I don't have any redstone circuits pulsing near the spawn. There are a lot of buildings, but I don't think that is causing the lag at spawn? It's like around 5-10 fps at spawn.
I'm going to be pretty busy this week and I won't be able give a look to you world again in a week more or less. So, don't expect an answer in at least that time.
I am so confused by this. How do I start diagnosing my server? And I have no experience whatsoever with this programming stuff. What do I put where and run?
I am so confused by this. How do I start diagnosing my server? And I have no experience whatsoever with this programming stuff. What do I put where and run?
Did you read the first post? Did you read the readme?
If you really want some step by step tutorial you have to give some more information. For example: operative system, how did you download region-fixer (source code, exe version).
If you are in windows you have to open a windows command line, in windows 7 you can do that writing "cmd" in the start menu search. After that move to the directory where region-fixer is and run it.
hmm i have a problem with my serverworld on nitrado (im using 15 mods) there never was a big problem but since today there is a chunk in my world that crashes the server and i always have to restart it until it works again and if anyone goes again in this chunk the server crashes again... My friend had to edit his players.dat coordinates otherwise the server crashes because he is inside. I have no idea what i can do pls help me
Have you tried region-fixer? Does it says anything about that chunk?
You could send me the region file that contains the problematic chunk, if you know what chunk is you know in what region file is, locate it and send me a link. I'll give it a look.
would be nice if this had the ability to do light updates for a map
Region Fixer strength (if it has one) is that it works in any minecraft version (with anvil region file format) and that is easy to maintain because the region file format doesn't change frequently. If I start to add things that are more blocky dependent (to update light in a chunk you need to know how every block affect lighting, and blocks change in every minecraft release!) is going to be really hard to maintain and it's going to need a lot of time of reverse engineering. I'm not doing it, at least for the moment.
TL;DR: At least for now, I'm sorry to say that it won't happen. Too hard, small benefit.
############################################################
############## Scanning separate region files ##############
############################################################
**********
*** Error while scanning:
*** /opt/minecraft/world/region/r.3.-4.mca
**********
*** Printing the child's Traceback:
*** Exception: <type 'exceptions.KeyError'> (30, 17)
**********
*** File /opt/minecraft/Minecraft-Region-Fixer-master/scan.py, line 241, in scan_region_file
*** if r[l[j]][TUPLE_STATUS] == world.CHUNK_WRONG_LOCATED:
**********
*** File /opt/minecraft/Minecraft-Region-Fixer-master/world.py, line 187, in __getitem__
*** return self.chunks[key]
**********
Traceback (most recent call last):
File "region-fixer.py", line 304, in <module>
value = main()
File "region-fixer.py", line 201, in main
scan_regionset(region_list, options)
File "/opt/minecraft/Minecraft-Region-Fixer-master/scan.py", line 412, in scan_regionset
raise ChildProcessException(r)
scan.ChildProcessException
############################################################
############## Scanning separate region files ##############
############################################################
**********
*** Error while scanning:
*** /opt/minecraft/world/region/r.3.-4.mca
**********
*** Printing the child's Traceback:
*** Exception: <type 'exceptions.KeyError'> (30, 17)
**********
*** File /opt/minecraft/Minecraft-Region-Fixer-master/scan.py, line 241, in scan_region_file
*** if r[l[j]][TUPLE_STATUS] == world.CHUNK_WRONG_LOCATED:
**********
*** File /opt/minecraft/Minecraft-Region-Fixer-master/world.py, line 187, in __getitem__
*** return self.chunks[key]
**********
Traceback (most recent call last):
File "region-fixer.py", line 304, in <module>
value = main()
File "region-fixer.py", line 201, in main
scan_regionset(region_list, options)
File "/opt/minecraft/Minecraft-Region-Fixer-master/scan.py", line 412, in scan_regionset
raise ChildProcessException®
scan.ChildProcessException
Sorry for the very late answer.
Could you send me that region file mentioned in the error? ( /opt/minecraft/world/region/r.3.-4.mca )
If you have a few servers sure you have found yourself with some corrupted maps. This tool is a python script that tries to fix problems in region files. It can find some typical errors (corrupted chunks, wrong located chunks, too many entities problems), and can fix these errors in various ways (deleting the chunks, replacing them with a backup copy, or relocating the chunk).
This is a command line application. You have to use it in a terminal in GNU/Linux or a command line (typical MS-DOS view) in Windows. To open the command line in windows run the plication "cmd". You can find usage examples in the readme.
What does this tool do?
Read about it in four questions here:
What does Minecraft Region-Fixer do?
It scans Minecraft worlds (Anvil format) searching for errors in the region file structure, wrong located chunks and chunks that have too many entities.
Does it fix worlds unredable by vanilla Minecraft because a mod inserted strange blocks, entities, etc?
No. In general Region-Fixer is mostly dedicated to check the integrity of region files, making it independent of the Minecraft version. So, in general it will work with moded worlds (unless the mod changes the world format or the region format), but it won't remove strange moded things from the world.
Then what can it fix?
It can detect these problems in region files: header problems, chunk header problems, chunk data corrupted problems (typically wrong CRC in compression), wrong located chunks and it can check if a chunk has an unusual amount of entities (zombies, spiders, primed TNT, etc...), this happens sometimes and makes the server to take 100% CPU and hang.
Can it fix these problems?
Well, yes, more or less... If the data of a chunk is corrupted then this chunk is lost. Region-Fixer can use a backup of the map to replace it or just delete it. Although deleting it sounds drastic, you won't notice. Minecraft will regenerate that chunk when needed and the map will look seamless (well, if there was anything built in there you will notice...). Wrong located chunks can be fixed in the same way, replacing it using back-up or by deleting them. And with entities, Region-Fixer can remove all the entities in a chunk that has too many of them.
News. IMPORTANT: Use region-fixer v0.1.3 or newer for 1.7 worlds. Bad things will happen if you use an older version.
v0.1.3 Update for 1.7 worlds!
- Update the NBT library (thanks nbt people!). Now 1.7 worlds work properly.
v0.1.2 Bug fix update
- Fixed a small bug that made impossible to scan worlds with a type of corrupted chunks.
v0.1.1 Another big update
- New code to detect: chunks sharing an offset, region files that are too small in size to be region files
- Improved the report of results (I think).
- Fixed a lot of bugs.
v0.1.0 Big update
- Lots of changes everywhere. Updated nbt library.
- A new interactive mode: scan the world and decide what to do with some commands.
- You can now scan single region files, a selection of region files, a world folder or a mix of all.
v0.0.8 Bug fix release
- Fixes a critical bug, it was impossible to delete entieies.
v0.0.7 Update for the new anvil format
- Anvil format support.- New "--interactive" option that starts region fixer as a console. Not really useful at the moment.
v0.0.6 Bugfixes and fresh windows compile
- Important bugfixes
- Solved problem with multiprocessing in Windows - New windows compile
v0.0.5 Big rewrite of some parts!
- Multiprocessing. - Better code - progressbar and verbose mode. - NOTE: There's no windows exe at the moment, but should work installing python
v0.0.4 Update with new features!
- Now it scans also the nether direcotory.
- Basic tests for the 'level.dat' and '*.dat' player files, it can say if they are corrupted. Not sure what to check here, if you have a problem with a level.dat or a player.dat that can be located and fixed, tell me about it and I'll problably implement it. At the moment can't fix any of these files, just point them out.
- Using '--deletet-entities' option doens't deletes chests items, singposts, etc anymore! Actually it never did that, it was a missunderstood of the chunk structure. The readme has been updated with fixing the wrong info.
- Added a warning when the entity number for a chunk is probably too big.
- NBT module updated fixing a bug.
v0.0.3 Added a windows executable!
- changes to Region Fixer to make it work in windows.
- Some changes in readme and copying txts.
v0.0.2 Maintenance update.
- NBT module updated, fix some possible problems.
- updated the readme with working python versions
v0.0.1 First version!
How-to download and use region-fixer:
For Windows:
Download the executable version of region-fixer (see the download section in this post). Note that you can also use the source code if you want to, for insights in how to download it see the GNU/Linux how to.
Decompress it using your favourite software in any place, but please, rememeber where you have decompressed it.
Now run a CMD window, if you have windows 7 is as easy as write cmd in the start menu search and run it. At this point you have to change directory you are on to the one that stores region-fixer. To do this use the "cd" command. For example:
c:\Users\Fenixin\> cd Desktop
c:\Users\Fenixin\Desktop\
If you don't know how, google it! There are a lot of good tutorials, youtube is also a good place to search.
Finally you can run region-fixer, for that you will have to run something simillar to this:
this command will scan the whole world and report any problems found.
Region-Fixer has a lot of useful options run "region-fixer.exe --help" to see them all.
For GNU/Linux:
Download the source code of region-fixer (see the download section in this post). If you know how to use git you can clone the repo, the master branch is intended to be always more or less stable. If you don't know how to clone a repo using git, don't worry, there is a button in the github web that let you download the source code in a zip file. The button is at left of the web page, just below the description that is below the buttons "Code", "Network", etc (it has a cloud with a down-pointing arrow and the ZIP word in it).
Decompress it using your favorite software in any place, but please, remember where. If you have cloned the repo you don't have to decompress anything.
Open a terminal and change directory where region-fixer is. If you are using linux you probably know how to move around in the terminal, if not, google for a tutorial, there are excellent things out there.
Finally you can run region-fixer, for that you will have to run something similar to this:
this command will scan the whole world and report any problems found. Please note that you need python to run region-fixer source code, but I think every GNU/Linux distribution has some sort of python installed in it.
Region-Fixer has a lot of useful options run "python region-fixer.py --help" to see them all
Usage.
Calling the tool with a world path will scan the world path and report the number of problems found:
$ python region-fixer.py ~/.minecraft/saves/corrupted-world
Welcome to Region Fixer!
############################################################
############ Scanning world: Testing corruption ############
############################################################
Scanning directory...
Info: No nether dimension in the world directory.
Info: No end dimension in the world directory.
There are 1 region files and 1 player files in the world directory.
-------------------- Checking level.dat --------------------
'level.dat' is redable
------------------ Checking player files -------------------
All player files are readable.
------------------ Scanning the overworld ------------------
Scanning: 1 / 1 100% [########################################] Time: 00:00:20
Found 19 corrupted, 0 wrong located chunks and 0 chunks with too many entities of a total of 625
Then you can use one of the options to fix this in some way, for example --delete-corrupted, --delete-wrong-located, --replace-corrupted. The option --replace-corrupted makes use of the option --backups, and tries to substitute the corrupted chunks with the same chunk in the backup. You can use a list of backup directories, for example:
--backups=/media/backup1,/media/backup2
Minecraft-Region-Fixer will use the list from left to right.
Some maps have problems with chunks holding thousands of entities (usually an entity duplicated over and over again), you can fix this using the options --entity-limit NUMBER, --delete-entities. This will scan the number of entities of the chunk and if it exceeds the given number it will delete all the entities in the chunk, but it won't touch the TileEntities.
For more info run:
python region-fixer.py --help
Or read the readme in github (you can do so in github).
What does it mean that a chunk is correupted/is wrong-located/has entities problem/ is sharing offset?
- Corrupted: Chunk inside a region-file are stored compressed. A corrupted chunk is a chunk that can't be decompressed anymore (usually a CRC error). Solution: Once a chunk is corrupted can't be decompressed and it's lost. When minecraft finds a chunk like this it will silently delete it a regenerate it. Region-fixer can automatically replace it using a backup or delete it.
- Wrong located: The region file has a header and in there is where it's written where the chunks are in the minecraft world. But inside the chunks there is also two coordinates with the same information. Sometimes these coordinates doesn't match, and when this happen, the server will complain about a wrong located stuff. Solution: This chunks can be read. Region-Fixer can remove them or replace them using a backup, extacly the same way as is done with corrupted chunks. This chunks can be much better fixed but for the moment is not implemented.
- Entities problem: This is not a problem by himself, is not like a corrupted chunk or a wrong located chunk. This problem happens when there is a lot of entities in the same chunk. Although it doesn't look like a problem, the server has to move all the entities in every in game tick. This can make the server lag or even make it non working (when the amount of entities is really big... thousands). Solution: Region-Fixer can delete all the entities in that chunk. Please note that entities are things like items in the ground (no in chests or users), mobs, animals... etc. See http://www.minecraft...net/wiki/Entity to know all the things that entities are.
- Sharing offset: Region files are like small file systems. A region file has a header (like the index in a book) where it stores where all the chunks are. Sometimes, in the region file herader there are two (or more) headers pointing to the same chunk (with the book, two chapters that are in the same pages) and this is not good. Solution: One of the chunks, is not really there, it jus has a reference in the region header. The solution is to remove the false reference from the region header.
- Too-small region file: It's a region file that it's so small in size that it doesn't have space to store the header. Any region file smaller than 8KiB is considered 'too-small'. Solution: Removing or replacing it with a backup are the only real solutions. The region file has almost no info in it, I would say it's not even ar egion file!
Tips & Tricks:
- You can run region-fixer in a single region file or an arbitrary amount of region files. If you have a huge world and you know where the problems are you don't have to scan every single region file every time you want to do something. You could do a first scan with:
In the first case you will have a file with a extensive summary of all the problem founds, in the second one region-fixer will print a line for every region file scanned and in there you can look which ones are broken, now you can try for example:
Note that using this method you can't use backups!
- If you are not sure what is going on in your minecraft world try using --interactive mode. This way, once the world is scanned, you will be able to see what the problems are and what do you want to do with them without the need of a new scan, saving precious time.
Download
You can download the source code from github:
Was Region-Fixer useful for you?
Take some time to write a positive feedback or donate if you feel like so.
Questions, feature requests, problems, suggestions...
If you have problems using region-fixer and want some help, please give some information in your post, for example:
- Operative system
- Are you running region-fixer using the .exe or the source code?
- Full command used to run it.
- Full error, everything, if possible, all the text visible until the next prompt.
- Just in case you've got an old version, Region-Fixer version, use --version to see it.
Suggestions and bugs should go to the github page:
Warning!
This tool works, and has been tested with a lot of worlds, but bugs can be anywhere, so please, use it with care and make a backup of your world before using it! And use it at your own risk!
Hi, i have problem with my Minecraft world. I have 1 wrong located chunk, i fix it using regin fixer. But theres second problem, i have too many entities, and cannot delete it, Can you help me please? Heres log:
Hello!
First, sorry for the late answer, I was in a trip.
That looks like you are ending up without memory to scan the world! Have you checked the RAM usage while scanning? Have you tried in a computer with more RAM? If this is happening after those tests, could you send me your world (or the region file with too many entities) so I can test it myself?
Please, if you can, report back with the results of the tests.
I hope this isn't the wrong place to ask for help. I've got a fairly large server world that is corrupt and I'm really hoping to get it fixed.
My problem is that when I try to delete entities I get this error:
WARNING: The region file 'region\r.2.-17.mca' had an error and couldn't be parsed as region file!
Error:<type 'exceptions.MemoryError'>
Note: this region file won't be scanned and won't be taken into acount.
Also, this may be a bug. Please, report it if you have the time.
I've got 24GB of RAM on my system and am running windows 7 Pro 64bit. I've checked a couple times and it's not using even close to all the RAM. It normally uses something in the range of 2GB or so before crashing.
My world file is just under 800MB.
I don't know if it matters but it normally hangs up on region 151/358.
The exact command I used to try to delete the entities:
I hope this isn't the wrong place to ask for help. I've got a fairly large server world that is corrupt and I'm really hoping to get it fixed.
My problem is that when I try to delete entities I get this error:
I've got 24GB of RAM on my system and am running windows 7 Pro 64bit. I've checked a couple times and it's not using even close to all the RAM. It normally uses something in the range of 2GB or so before crashing.
My world file is just under 800MB.
I don't know if it matters but it normally hangs up on region 151/358.
The exact command I used to try to delete the entities:
I think the problem is that the windows exe doesn't use the 64 bits, so it can only access to 2GB of ram.
You could try to install python 2.7.x (64bits) in your computer and run region-fixer using the source code and the interpreter. Although I'm not sure, this might work. I've had some problems with python + 64 bits + windows in the past. If you try this way, please, report your results as I'm really curious.
If the above suggestion doesn't work. You could send me your world (or only the region-file that make region-fixer crash) and I'll scan it, fix it and return it to you (using a linux 64bits box).
Good luck! Don't hesitate to ask if you need any more help.
So I'm having a of trouble running your program(the windows.exe) I just can't seem to figure it out. I've read through the help dox but those don't explain in detail what I need to do to get the program started, I've got my 12 GB world file down loaded, I simply need step-by-step instructions on how to do this, because I can't figure it out for the life of me. I'm running this on windows 8.
I believe I have a simple chunk error in my map that needs to be fixed ASAP
So I'm having a of trouble running your program(the windows.exe) I just can't seem to figure it out. I've read through the help dox but those don't explain in detail what I need to do to get the program started, I've got my 12 GB world file down loaded, I simply need step-by-step instructions on how to do this, because I can't figure it out for the life of me. I'm running this on windows 8.
I believe I have a simple chunk error in my map that needs to be fixed ASAP
Thanks,
Parker
Hello!
region-fixer is a command line application. You have to use the "MS-DOS window" to run it. If you are in windows 7 you can type "cmd" in the search box and hit enter, that will pop up a "MS-DOS window". You need how to navigate using the command line, don't worry, it's not hard, google and youtube are your firends (and they are going to explain how to use it much better than me). When you are in the command line you have to navigate to region-fixer folder and then run it pointing it to your world. Something like this:
I'm going to be pretty busy this week and I won't be able give a look to you world again in a week more or less. So, don't expect an answer in at least that time.
Good luck!
Did you read the first post? Did you read the readme?
If you really want some step by step tutorial you have to give some more information. For example: operative system, how did you download region-fixer (source code, exe version).
If you are in windows you have to open a windows command line, in windows 7 you can do that writing "cmd" in the start menu search. After that move to the directory where region-fixer is and run it.
Good luck!
http://themindcrafters.com/2013/02/13/minecraft-chunk-file-in-the-wrong-location/
There is a very nice step by step guide for windows users in that web.
Have you tried region-fixer? Does it says anything about that chunk?
You could send me the region file that contains the problematic chunk, if you know what chunk is you know in what region file is, locate it and send me a link. I'll give it a look.
IP - play.phanaticmc.com
Region Fixer strength (if it has one) is that it works in any minecraft version (with anvil region file format) and that is easy to maintain because the region file format doesn't change frequently. If I start to add things that are more blocky dependent (to update light in a chunk you need to know how every block affect lighting, and blocks change in every minecraft release!) is going to be really hard to maintain and it's going to need a lot of time of reverse engineering. I'm not doing it, at least for the moment.
TL;DR: At least for now, I'm sorry to say that it won't happen. Too hard, small benefit.
It comes with a bunch of bug fixes and new features.
As always update using git or downloading the new version in mediafire.
Thanks to Forquare (minecraftforums) for the bug report and the region files that has made possible a new feature for region-fixer.
Also, uploading the windows exe in mediafire I've seen that the windows version of region-fixer has been downloaded around 4700 times. Nice!
Good luck everyone!
(version: 0.1.2)
############################################################
############## Scanning separate region files ##############
############################################################
**********
*** Error while scanning:
*** /opt/minecraft/world/region/r.3.-4.mca
**********
*** Printing the child's Traceback:
*** Exception: <type 'exceptions.KeyError'> (30, 17)
**********
*** File /opt/minecraft/Minecraft-Region-Fixer-master/scan.py, line 241, in scan_region_file
*** if r[l[j]][TUPLE_STATUS] == world.CHUNK_WRONG_LOCATED:
**********
*** File /opt/minecraft/Minecraft-Region-Fixer-master/world.py, line 187, in __getitem__
*** return self.chunks[key]
**********
Traceback (most recent call last):
File "region-fixer.py", line 304, in <module>
value = main()
File "region-fixer.py", line 201, in main
scan_regionset(region_list, options)
File "/opt/minecraft/Minecraft-Region-Fixer-master/scan.py", line 412, in scan_regionset
raise ChildProcessException(r)
scan.ChildProcessException
mc.creepercountry.com
Economy Survival
Sorry for the very late answer.
Could you send me that region file mentioned in the error? ( /opt/minecraft/world/region/r.3.-4.mca )
That would be really helpful finding the problem.
This version works properly with 1.7 worlds. If you use an older version bad things will happen!
Code and exe in the sames places as always.
Good luck!
sounds really cool. im will try soon
Hello!
First, sorry for the late answer, I was in a trip.
That looks like you are ending up without memory to scan the world! Have you checked the RAM usage while scanning? Have you tried in a computer with more RAM? If this is happening after those tests, could you send me your world (or the region file with too many entities) so I can test it myself?
Please, if you can, report back with the results of the tests.
Good luck!
My problem is that when I try to delete entities I get this error:
I've got 24GB of RAM on my system and am running windows 7 Pro 64bit. I've checked a couple times and it's not using even close to all the RAM. It normally uses something in the range of 2GB or so before crashing.
My world file is just under 800MB.
I don't know if it matters but it normally hangs up on region 151/358.
The exact command I used to try to delete the entities:
My Initial Scan
http://pastebin.com/Kr5kSxDX
The full error log
http://pastebin.com/kPsn3R1H
Any help would be greatly appreciated!
Hello!
I think the problem is that the windows exe doesn't use the 64 bits, so it can only access to 2GB of ram.
You could try to install python 2.7.x (64bits) in your computer and run region-fixer using the source code and the interpreter. Although I'm not sure, this might work. I've had some problems with python + 64 bits + windows in the past. If you try this way, please, report your results as I'm really curious.
If the above suggestion doesn't work. You could send me your world (or only the region-file that make region-fixer crash) and I'll scan it, fix it and return it to you (using a linux 64bits box).
Good luck! Don't hesitate to ask if you need any more help.
I installed the 64bit version of python and ran the python (not the windows .exe) version of your program and it worked like a charm!
I'll have to buy you a coffee sir. (or PayPal you the equivalent)
I believe I have a simple chunk error in my map that needs to be fixed ASAP
Thanks,
Parker
Thanks you very much!
I'll write down in the FAQ (or somewhere else) this, so it helps to others.
Hello!
region-fixer is a command line application. You have to use the "MS-DOS window" to run it. If you are in windows 7 you can type "cmd" in the search box and hit enter, that will pop up a "MS-DOS window". You need how to navigate using the command line, don't worry, it's not hard, google and youtube are your firends (and they are going to explain how to use it much better than me). When you are in the command line you have to navigate to region-fixer folder and then run it pointing it to your world. Something like this:
Don't hesitate to ask if you need anything else.
Good luck!
I've got the CMD Prompt open I just can't figure out how to run the program or where my world file is "located" on my computer.