What OS are you using? Linux. What architecture is the OS you are running? x86 What version and architecture is your java install? Linux blockempires 2.6.35-30-server #59-Ubuntu SMP Tue Aug 30 19:16:40 UTC 2011 x86_64 GNU/Linux java version "1.6.0_26" Java(TM) SE Runtime Environment (build 1.6.0_26-b03) Java HotSpot(TM) 64-Bit Server VM (build 20.1-b02, mixed mode) Are you running any wrappers? No. What build of CraftBukkit are you running? CB #1240 (I've tried all builds to fix it but it still doesn't fix anything, even 1337) What command are you using to run your CraftBukkit server? ./launch.sh What plugins are you running? Announcer, BlockHat, bShortcut, ButtonWarp, ChestShop, Citizens, ColoredSigns, CommandIConomy, Conquest (Custom server plugin), Dynmap, Essentials, EssentialsSpawn, HeroChat, Heroes, HeroSneak, iConomy, KiwiAdmin, Lineage (Custom server plugin), LWC, Minequery, MobDisquise, MobRider, Mobster (Custom server plugin), NoCheat, NoFarm, PermissionsEx, PhatLoots, PlgDisableCmd, Residence, SafeCreeper, Showcase, SimpleClans, SupplySign, Votifier, VoxelSniper, WorldBorder, WorldEdit, WorldGuard Lots of plugins I can assure you none of the custom plugins are causing the problem. What error are you getting? Posted below. What have you tried already? Seeing as it is a too many files error I natural thought it was a plugin corrupt plugin opening too many files and causing the server to crash. So I did the following: First, I used the command "ps -eaf" to find the process ID of my server after it had crashed. Second, I used the command "ls -| /proc/ProcessIDhere/fd" to see the processes. And it only showed no more than 150 processes or so. I'm told that 300 is fairly normal and it should be like 4000+ for me to be having in order to get this error. So I'm guessing this isn't the error and this is why I'm coming to you for your help. Error: Note: This error happens about every 2-5 hours so it is quite urgent that I get fixed ASAP. Please help Code: [/B][/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] Too many open files[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] java.lang.NullPointerException[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] Too many open files[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] java.lang.NullPointerException[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] Too many open files[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] java.lang.NullPointerException[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] Too many open files[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] java.lang.NullPointerException[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] Too many open files[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] Too many open files[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] java.lang.NullPointerException[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] Too many open files[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] java.lang.NullPointerException[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] net.minecraft.server.MinecraftException: Failed to check session lock, aborting[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.PlayerNBTManager.b(PlayerNBTManager.java:71)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.j(World.java:2404)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkRegionLoader.a(SourceFile:54)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkProviderServer.saveChunk(ChunkProviderServer.java:152)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkProviderServer.unloadChunks(ChunkProviderServer.java:236)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.doTick(World.java:1624)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:461)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] net.minecraft.server.MinecraftException: Failed to check session lock, aborting[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.PlayerNBTManager.b(PlayerNBTManager.java:71)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.j(World.java:2404)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkRegionLoader.a(SourceFile:54)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkProviderServer.saveChunk(ChunkProviderServer.java:152)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkProviderServer.unloadChunks(ChunkProviderServer.java:236)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.doTick(World.java:1624)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:461)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] net.minecraft.server.MinecraftException: Failed to check session lock, aborting[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.PlayerNBTManager.b(PlayerNBTManager.java:71)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.j(World.java:2404)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkRegionLoader.a(SourceFile:54)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkProviderServer.saveChunk(ChunkProviderServer.java:152)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkProviderServer.unloadChunks(ChunkProviderServer.java:236)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.doTick(World.java:1624)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:461)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] net.minecraft.server.MinecraftException: Failed to check session lock, aborting[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.PlayerNBTManager.b(PlayerNBTManager.java:71)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.j(World.java:2404)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] net.minecraft.server.MinecraftException: Failed to check session lock, aborting[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.PlayerNBTManager.b(PlayerNBTManager.java:71)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.j(World.java:2404)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkRegionLoader.a(SourceFile:54)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkProviderServer.saveChunk(ChunkProviderServer.java:152)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ChunkProviderServer.unloadChunks(ChunkProviderServer.java:236)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.World.doTick(World.java:1624)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:461)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)[/B][/B] [B][B]2011-10-28 17:24:19 [SEVERE] net.minecraft.server.MinecraftException: Failed to check session lock, aborting[/B][/B] [B][B]2011-10-28 17:24:20 [SEVERE] Unexpected exception[/B][/B] [B][B]net.minecraft.server.MinecraftException: Failed to check session lock, aborting[/B][/B] [B][B] at net.minecraft.server.PlayerNBTManager.b(PlayerNBTManager.java:71)[/B][/B] [B][B] at net.minecraft.server.World.j(World.java:2404)[/B][/B] [B][B] at net.minecraft.server.World.w(World.java:241)[/B][/B] [B][B] at net.minecraft.server.World.save(World.java:231)[/B][/B] [B][B] at net.minecraft.server.World.doTick(World.java:1633)[/B][/B] [B][B] at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:461)[/B][/B] [B][B] at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)[/B][/B] [B][B] at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] java.net.SocketException: Too many open files[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.socketAccept(Native Method)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.implAccept(ServerSocket.java:462)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.accept(ServerSocket.java:430)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at net.minecraft.server.NetworkAcceptThread.run(SourceFile:35)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] java.net.SocketException: Too many open files[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.socketAccept(Native Method)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.implAccept(ServerSocket.java:462)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.accept(ServerSocket.java:430)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at net.minecraft.server.NetworkAcceptThread.run(SourceFile:35)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] java.net.SocketException: Too many open files[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.socketAccept(Native Method)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.implAccept(ServerSocket.java:462)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.accept(ServerSocket.java:430)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at net.minecraft.server.NetworkAcceptThread.run(SourceFile:35)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] java.net.SocketException: Too many open files[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.socketAccept(Native Method)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.implAccept(ServerSocket.java:462)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.accept(ServerSocket.java:430)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at net.minecraft.server.NetworkAcceptThread.run(SourceFile:35)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] java.net.SocketException: Too many open files[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.socketAccept(Native Method)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.implAccept(ServerSocket.java:462)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.accept(ServerSocket.java:430)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at net.minecraft.server.NetworkAcceptThread.run(SourceFile:35)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] java.net.SocketException: Too many open files[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.socketAccept(Native Method)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.implAccept(ServerSocket.java:462)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.accept(ServerSocket.java:430)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at net.minecraft.server.NetworkAcceptThread.run(SourceFile:35)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] java.net.SocketException: Too many open files[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.socketAccept(Native Method)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.implAccept(ServerSocket.java:462)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at java.net.ServerSocket.accept(ServerSocket.java:430)[/B][/B] [B][B]2011-10-28 17:24:31 [SEVERE] at net.minecraft.server.NetworkAcceptThread.run(SourceFile:35)[/B][/B] [B][B] [/code][/code][/B][/code][/B][/code][/B][/code][/B] Feel free to ask questions to help me solve this.... Is it a bukkit error or what? EDIT by Moderator: merged posts, please use the edit button instead of double posting.
You have contradictory information in your first post and the contents of the shell script are the important part, not the name of your script. That's irrelevant since your issue is that too many file descriptors have been assigned. You can modify the limit or get rid of the plugin that's forgetting to close() its FDs. Modifying the limit is well documented via Google. Finding the offender should be possible with the java dev tools and basic troubleshooting knowledge.
Try Conquest, Dynmap, Heroes, iConomy, KiwiAdmin, Lineage, LWC, Minequery, Mobster, Residence as I believe those maybe the largest. Don't mind me asking, but may I know what Conquest, Lineage and Mobster do?
Alright, I'll give that a try, but do you think deleting the "session.lock" file in the world folder would fix it? Since that is the actual file that is causing the problem it looks like. Lineage is a custom Race plugin for the server. Mobster is a custom dungeon plugin that allows us to create WG regions in a dungeon we have made. That allows to spawn mobs, modify their hp, speed, count, period when spawned and many more things. Conquest is a custom worldguard capturing plugin within races. So players can capture other Race's villages and gain money from it (Works kinda like the BF2 BF3 flag capturing system). Bump EDIT by Moderator: merged posts, please use the edit button instead of double posting.
I've programmed Conquest, Mobster, and Lineage. None of them even use files besides the default config.yml. Everything else with them is MySQL Unless creating lots of entities (Mobster) could cause this error, I don't think there's any other issues my plugins would have. When I use lsof I find there's quite a few "can't identify protocol" messages shown in there. Here's the lsof -p <pid> dump: http://pastebin.com/D96Tqjht Here's the /proc/<id>/fd dump: http://pastebin.com/KBJ6VFXG FWIW: Here's the simple bash script i use to launch it Code: #!/bin/sh rm /home/minecraft/server.log screen -S mc java -server -Xms2048M -Xmx4096M -jar craftbukkit.jar nogui Apparently, this is due to improperly closed sockets. I have no idea what plugin is causing this....what's the best way to debug remotely?? EDIT by Moderator: merged posts, please use the edit button instead of double posting.
Fixed by putting: ulimit -n 10000 Right before the java initializing command in my ./launch.sh Apparently, my server insists on setting the max limit of files open to 1024 per instance. However, Minecraft uses that up pretty quickly so manually setting it to 10,000 every time the server launches seems to clear it up. Hope this helps someone in the future!
You have a bad plugin in the mix there. While setting your ulimit higher may get around it, you're better off tracking down the offender and bringing up the issue with the dev. Glad you found a workaround though.
I tried tracking it down but it was fruitless. There was something opening sockets but not closing them later on. When I looked at the file descriptors used by the process there would be about 1 new "broken socket" descriptor about every 5 minutes. I've spent enough time on this already, hopefully from just weekly plugin updates it will eventually go away