Posted 26 March 2013 - 08:15 PM
At the moment, I can't start my FTB server at all. As soon as all the startup stuff runs, it goes dead and doesn't respond to logins or console commands. I attached the Java debugger to it and saw many threads, a few of which were in the "waiting in a monitor" state. I've attached some of the debugger info below. It looks to me like wireless modem code is deadlocking the main server thread (notice the lock info at the very bottom).
Several people are using ComputerCraft for various things on the server and I don't know yet what particular program is triggering this. However, I have a build that uses about 20 turtles coordinating with each other over rednet, and the protocol can be rather chatty, so that may be the source. Odd thing is, even if I disable chunk loading in Forge, the server still won't start. There have got to be very few if any computers within the always-loaded area at spawn, so I don't understand where the 200 Lua threads are coming from.
What I really need is a way to start the server with all Lua VMs shutdown. Can that be done?
Several people are using ComputerCraft for various things on the server and I don't know yet what particular program is triggering this. However, I have a build that uses about 20 turtles coordinating with each other over rednet, and the protocol can be rather chatty, so that may be the source. Odd thing is, even if I disable chunk loading in Forge, the server still won't start. There have got to be very few if any computers within the always-loaded area at spawn, so I don't understand where the 200 Lua threads are coming from.
What I really need is a way to start the server with all Lua VMs shutdown. Can that be done?
Initializing jdb ...
>
> threads
Group system:
(java.lang.ref.Reference$ReferenceHandler)0x21c3 Reference Handler cond. waiting
(java.lang.ref.Finalizer$FinalizerThread)0x21c4 Finalizer cond. waiting
(java.lang.Thread)0x21c5 Signal Dispatcher running
(java.lang.Thread)0x21c6 Keep-Alive-SocketCleaner cond. waiting
Group main:
(java.lang.Thread)0x21c8 Thread-1 cond. waiting
(java.util.TimerThread)0x21c9 Snooper Timer cond. waiting
(hp)0x21ca Thread-3 sleeping
(fy)0x21cb Server thread waiting in a monitor
(java.lang.Thread)0x21cc DestroyJavaVM running
(hq)0x21cd Thread-5 running
(java.util.TimerThread)0x21ce Immibis Core background task cond. waiting
(java.lang.Thread)0x21cf Thread-10 sleeping
(java.lang.Thread)0x21d0 TC Aura Calculation Thread cond. waiting
(java.lang.Thread)0x21d1 TC Aura Deletion Thread cond. waiting
(java.lang.Thread)0x21d2 TC Aura Update Thread cond. waiting
(hu)0x21d3 Listen thread running
(java.lang.Thread)0x21d4 Thread-19 waiting in a monitor
(java.lang.Thread)0x21d5 Coroutine-1 cond. waiting
(java.lang.Thread)0x21d6 Coroutine-2 cond. waiting
(java.lang.Thread)0x21d7 Coroutine-3 cond. waiting
(java.lang.Thread)0x21d8 Coroutine-4 cond. waiting
(java.lang.Thread)0x21d9 Coroutine-5 cond. waiting
(java.lang.Thread)0x21da Coroutine-6 cond. waiting
(java.lang.Thread)0x21db Coroutine-7 cond. waiting
(java.lang.Thread)0x21dc Coroutine-8 cond. waiting
(java.lang.Thread)0x21dd Coroutine-9 cond. waiting
(java.lang.Thread)0x21de Coroutine-10 cond. waiting
(java.lang.Thread)0x21df Coroutine-11 cond. waiting
(java.lang.Thread)0x21e0 Coroutine-12 cond. waiting
(java.lang.Thread)0x21e1 Coroutine-13 cond. waiting
(java.lang.Thread)0x21e2 Coroutine-14 cond. waiting
(java.lang.Thread)0x21e3 Coroutine-15 cond. waiting
(java.lang.Thread)0x21e4 Coroutine-16 cond. waiting
(java.lang.Thread)0x21e5 Coroutine-17 cond. waiting
(java.lang.Thread)0x21e6 Coroutine-18 cond. waiting
(java.lang.Thread)0x21e7 Coroutine-19 cond. waiting
(java.lang.Thread)0x21e8 Coroutine-20 cond. waiting
(java.lang.Thread)0x21e9 Coroutine-21 cond. waiting
(java.lang.Thread)0x21ea Coroutine-22 cond. waiting
(java.lang.Thread)0x21eb Coroutine-23 cond. waiting
(java.lang.Thread)0x21ec Coroutine-24 cond. waiting
(java.lang.Thread)0x21ed Coroutine-25 cond. waiting
(java.lang.Thread)0x21ee Coroutine-26 cond. waiting
(java.lang.Thread)0x21ef Coroutine-27 cond. waiting
(java.lang.Thread)0x21f0 Coroutine-28 cond. waiting
(java.lang.Thread)0x21f1 Coroutine-29 cond. waiting
(java.lang.Thread)0x21f2 Coroutine-30 waiting in a monitor
(java.lang.Thread)0x21f3 Coroutine-31 cond. waiting
(java.lang.Thread)0x21f4 Coroutine-32 cond. waiting
(java.lang.Thread)0x21f5 Coroutine-33 cond. waiting
(java.lang.Thread)0x21f6 Coroutine-34 cond. waiting
(java.lang.Thread)0x21f7 Coroutine-35 cond. waiting
(java.lang.Thread)0x21f8 Coroutine-36 cond. waiting
(java.lang.Thread)0x21f9 Coroutine-37 cond. waiting
(java.lang.Thread)0x21fa Coroutine-38 cond. waiting
(java.lang.Thread)0x21fb Coroutine-39 cond. waiting
(java.lang.Thread)0x21fc Coroutine-40 cond. waiting
(java.lang.Thread)0x21fd Coroutine-41 cond. waiting
(java.lang.Thread)0x21fe Coroutine-42 cond. waiting
(java.lang.Thread)0x21ff Coroutine-43 cond. waiting
(java.lang.Thread)0x2200 Coroutine-44 cond. waiting
(java.lang.Thread)0x2201 Coroutine-45 cond. waiting
(java.lang.Thread)0x2202 Coroutine-46 cond. waiting
(java.lang.Thread)0x2203 Coroutine-47 cond. waiting
(java.lang.Thread)0x2204 Coroutine-48 cond. waiting
(java.lang.Thread)0x2205 Coroutine-49 cond. waiting
(java.lang.Thread)0x2206 Coroutine-50 cond. waiting
(java.lang.Thread)0x2207 Coroutine-51 cond. waiting
(java.lang.Thread)0x2208 Coroutine-52 cond. waiting
(java.lang.Thread)0x2209 Coroutine-53 cond. waiting
(java.lang.Thread)0x220a Coroutine-54 cond. waiting
(java.lang.Thread)0x220b Coroutine-55 cond. waiting
(java.lang.Thread)0x220c Coroutine-56 cond. waiting
(java.lang.Thread)0x220d Coroutine-57 cond. waiting
(java.lang.Thread)0x220e Coroutine-58 cond. waiting
(java.lang.Thread)0x220f Coroutine-59 cond. waiting
(java.lang.Thread)0x2210 Coroutine-60 cond. waiting
(java.lang.Thread)0x2211 Coroutine-61 cond. waiting
(java.lang.Thread)0x2212 Coroutine-62 cond. waiting
(java.lang.Thread)0x2213 Coroutine-63 cond. waiting
(java.lang.Thread)0x2214 Coroutine-64 cond. waiting
(java.lang.Thread)0x2215 Coroutine-65 cond. waiting
(java.lang.Thread)0x2216 Coroutine-66 cond. waiting
(java.lang.Thread)0x2217 Coroutine-67 cond. waiting
(java.lang.Thread)0x2218 Coroutine-68 cond. waiting
(java.lang.Thread)0x2219 Coroutine-69 cond. waiting
(java.lang.Thread)0x221a Coroutine-70 cond. waiting
(java.lang.Thread)0x221b Coroutine-71 cond. waiting
(java.lang.Thread)0x221c Coroutine-72 cond. waiting
(java.lang.Thread)0x221d Coroutine-73 cond. waiting
(java.lang.Thread)0x221e Coroutine-74 waiting in a monitor
(java.lang.Thread)0x221f Coroutine-75 cond. waiting
(java.lang.Thread)0x2220 Coroutine-76 cond. waiting
(java.lang.Thread)0x2221 Coroutine-77 cond. waiting
(java.lang.Thread)0x2222 Coroutine-78 cond. waiting
(java.lang.Thread)0x2223 Coroutine-79 cond. waiting
(java.lang.Thread)0x2224 Coroutine-80 cond. waiting
(java.lang.Thread)0x2225 Coroutine-81 cond. waiting
(java.lang.Thread)0x2226 Coroutine-82 cond. waiting
(java.lang.Thread)0x2227 Coroutine-83 cond. waiting
(java.lang.Thread)0x2228 Coroutine-84 cond. waiting
(java.lang.Thread)0x2229 Coroutine-85 cond. waiting
(java.lang.Thread)0x222a Coroutine-86 cond. waiting
(java.lang.Thread)0x222b Coroutine-87 cond. waiting
(java.lang.Thread)0x222c Coroutine-88 cond. waiting
(java.lang.Thread)0x222d Coroutine-89 cond. waiting
(java.lang.Thread)0x222e Coroutine-90 cond. waiting
(java.lang.Thread)0x222f Coroutine-91 cond. waiting
(java.lang.Thread)0x2230 Coroutine-92 cond. waiting
(java.lang.Thread)0x2231 Coroutine-93 cond. waiting
(java.lang.Thread)0x2232 Coroutine-94 cond. waiting
(java.lang.Thread)0x2233 Coroutine-95 cond. waiting
(java.lang.Thread)0x2234 Coroutine-96 cond. waiting
(java.lang.Thread)0x2235 Coroutine-97 cond. waiting
(java.lang.Thread)0x2236 Coroutine-98 cond. waiting
(java.lang.Thread)0x2237 Coroutine-99 cond. waiting
(java.lang.Thread)0x2238 Coroutine-100 cond. waiting
(java.lang.Thread)0x2239 Coroutine-101 cond. waiting
(java.lang.Thread)0x223a Coroutine-102 cond. waiting
(java.lang.Thread)0x223b Coroutine-103 cond. waiting
(java.lang.Thread)0x223c Coroutine-104 cond. waiting
(java.lang.Thread)0x223d Coroutine-105 cond. waiting
(java.lang.Thread)0x223e Coroutine-106 cond. waiting
(java.lang.Thread)0x223f Coroutine-107 cond. waiting
(java.lang.Thread)0x2240 Coroutine-108 cond. waiting
(java.lang.Thread)0x2241 Coroutine-109 cond. waiting
(java.lang.Thread)0x2242 Coroutine-110 cond. waiting
(java.lang.Thread)0x2243 Coroutine-111 cond. waiting
(java.lang.Thread)0x2244 Coroutine-112 cond. waiting
(java.lang.Thread)0x2245 Coroutine-113 cond. waiting
(java.lang.Thread)0x2246 Coroutine-114 cond. waiting
(java.lang.Thread)0x2247 Coroutine-115 cond. waiting
(java.lang.Thread)0x2248 Coroutine-116 cond. waiting
(java.lang.Thread)0x2249 Coroutine-117 cond. waiting
(java.lang.Thread)0x224a Coroutine-118 cond. waiting
(java.lang.Thread)0x224b Coroutine-119 cond. waiting
(java.lang.Thread)0x224c Coroutine-120 cond. waiting
(java.lang.Thread)0x224d Coroutine-121 cond. waiting
(java.lang.Thread)0x224e Coroutine-122 cond. waiting
(java.lang.Thread)0x224f Coroutine-123 cond. waiting
(java.lang.Thread)0x2250 Coroutine-124 cond. waiting
(java.lang.Thread)0x2251 Coroutine-125 cond. waiting
(java.lang.Thread)0x2252 Coroutine-126 cond. waiting
(java.lang.Thread)0x2253 Coroutine-127 cond. waiting
(java.lang.Thread)0x2254 Coroutine-128 cond. waiting
(java.lang.Thread)0x2255 Coroutine-129 cond. waiting
(java.lang.Thread)0x2256 Thread-196 waiting in a monitor
(java.lang.Thread)0x2257 Thread-197 waiting in a monitor
(java.lang.Thread)0x2258 Thread-198 waiting in a monitor
(java.lang.Thread)0x2259 Thread-203 cond. waiting
> suspend
All threads suspended.
> where 0x21cb
[1] dan200.computer.shared.WirelessModemPeripheral.pollChanged (WirelessModemPeripheral.java:90)
[2] dan200.turtle.shared.TurtleModem$Peripheral.update (TurtleModem.java:72)
[3] dan200.computer.core.apis.PeripheralAPI$PeripheralWrapper.update (PeripheralAPI.java:105)
[4] dan200.computer.core.apis.PeripheralAPI.advance (PeripheralAPI.java:354)
[5] dan200.computer.core.Computer.advance (Computer.java:560)
[6] dan200.computer.shared.NetworkedComputerHelper.update (NetworkedComputerHelper.java:111)
[7] dan200.turtle.shared.TileEntityTurtle.g (TileEntityTurtle.java:2,350)
[8] yc.h (World.java:2,153)
[9] in.h (WorldServer.java:516)
[10] net.minecraft.server.MinecraftServer.r (MinecraftServer.java:680)
[11] ho.r (DedicatedServer.java:269)
[12] net.minecraft.server.MinecraftServer.q (MinecraftServer.java:599)
[13] net.minecraft.server.MinecraftServer.run (MinecraftServer.java:497)
[14] fy.run (SourceFile:849)
Server thread[1] where 0x21d4
[1] dan200.computer.core.Computer.abort (Computer.java:283)
[2] dan200.computer.core.ComputerThread$1.run (ComputerThread.java:92)
[3] java.lang.Thread.run (null)
Thread-19[1] where 0x21f2
[1] dan200.computer.core.apis.PeripheralAPI.callMethod (PeripheralAPI.java:414)
[2] dan200.computer.core.LuaJLuaMachine$2.invoke (LuaJLuaMachine.java:304)
[3] org.luaj.vm2.lib.VarArgFunction.call (null)
[4] org.luaj.vm2.LuaClosure.execute (null)
[5] org.luaj.vm2.LuaClosure.call (null)
[6] org.luaj.vm2.LuaClosure.execute (null)
[7] org.luaj.vm2.LuaClosure.call (null)
[8] org.luaj.vm2.LuaClosure.execute (null)
[9] org.luaj.vm2.LuaClosure.onInvoke (null)
[10] org.luaj.vm2.LuaClosure.invoke (null)
[11] org.luaj.vm2.LuaThread$State.run (null)
[12] java.lang.Thread.run (null)
Coroutine-30[1] where 0x221e
[1] dan200.computer.core.Computer.queueLuaEvent (Computer.java:1,064)
[2] dan200.computer.core.Computer.access$300 (Computer.java:31)
[3] dan200.computer.core.Computer$APIEnvironment.queueEvent (Computer.java:91)
[4] dan200.computer.core.apis.PeripheralAPI$PeripheralWrapper.queueEvent (PeripheralAPI.java:220)
[5] dan200.computer.shared.WirelessModemPeripheral.receive (WirelessModemPeripheral.java:138)
[6] dan200.computer.shared.WirelessModemPeripheral$SingleChannelReceiver.receive (WirelessModemPeripheral.java:50)
[7] dan200.computer.shared.WirelessNetwork.tryTransmit (WirelessNetwork.java:87)
[8] dan200.computer.shared.WirelessNetwork.transmit (WirelessNetwork.java:75)
[9] dan200.computer.shared.WirelessModemPeripheral.callMethod (WirelessModemPeripheral.java:269)
[10] dan200.computer.core.apis.PeripheralAPI$PeripheralWrapper.call (PeripheralAPI.java:116)
[11] dan200.computer.core.apis.PeripheralAPI.callMethod (PeripheralAPI.java:464)
[12] dan200.computer.core.LuaJLuaMachine$2.invoke (LuaJLuaMachine.java:304)
[13] org.luaj.vm2.LuaClosure.execute (null)
[14] org.luaj.vm2.LuaClosure.call (null)
[15] org.luaj.vm2.LuaClosure.execute (null)
[16] org.luaj.vm2.LuaClosure.onInvoke (null)
[17] org.luaj.vm2.TailcallVarargs.eval (null)
[18] org.luaj.vm2.TailcallVarargs.arg1 (null)
[19] org.luaj.vm2.LuaClosure.call (null)
[20] org.luaj.vm2.LuaClosure.execute (null)
[21] org.luaj.vm2.LuaClosure.call (null)
[22] org.luaj.vm2.LuaClosure.execute (null)
[23] org.luaj.vm2.LuaClosure.call (null)
[24] org.luaj.vm2.LuaClosure.execute (null)
[25] org.luaj.vm2.LuaClosure.call (null)
[26] org.luaj.vm2.LuaClosure.execute (null)
[27] org.luaj.vm2.LuaClosure.onInvoke (null)
[28] org.luaj.vm2.LuaClosure.invoke (null)
[29] org.luaj.vm2.LuaClosure.execute (null)
[30] org.luaj.vm2.LuaClosure.onInvoke (null)
[31] org.luaj.vm2.LuaClosure.invoke (null)
[32] org.luaj.vm2.lib.BaseLib.pcall (null)
[33] org.luaj.vm2.lib.BaseLib$BaseLibV.invoke (null)
[34] org.luaj.vm2.LuaClosure.execute (null)
[35] org.luaj.vm2.LuaClosure.onInvoke (null)
[36] org.luaj.vm2.LuaClosure.invoke (null)
[37] org.luaj.vm2.LuaClosure.execute (null)
[38] org.luaj.vm2.LuaClosure.onInvoke (null)
[39] org.luaj.vm2.LuaClosure.invoke (null)
[40] org.luaj.vm2.LuaClosure.execute (null)
[41] org.luaj.vm2.LuaClosure.onInvoke (null)
[42] org.luaj.vm2.LuaClosure.invoke (null)
[43] org.luaj.vm2.lib.BaseLib.pcall (null)
[44] org.luaj.vm2.lib.BaseLib$BaseLibV.invoke (null)
[45] org.luaj.vm2.LuaClosure.execute (null)
[46] org.luaj.vm2.LuaClosure.onInvoke (null)
[47] org.luaj.vm2.LuaClosure.invoke (null)
[48] org.luaj.vm2.LuaClosure.execute (null)
[49] org.luaj.vm2.LuaClosure.onInvoke (null)
[50] org.luaj.vm2.TailcallVarargs.eval (null)
[51] org.luaj.vm2.TailcallVarargs.arg1 (null)
[52] org.luaj.vm2.LuaClosure.call (null)
[53] org.luaj.vm2.LuaClosure.execute (null)
[54] org.luaj.vm2.LuaClosure.onInvoke (null)
[55] org.luaj.vm2.LuaClosure.invoke (null)
[56] org.luaj.vm2.LuaClosure.execute (null)
[57] org.luaj.vm2.LuaClosure.onInvoke (null)
[58] org.luaj.vm2.LuaClosure.invoke (null)
[59] org.luaj.vm2.lib.BaseLib.pcall (null)
[60] org.luaj.vm2.lib.BaseLib$BaseLibV.invoke (null)
[61] org.luaj.vm2.LuaClosure.execute (null)
[62] org.luaj.vm2.LuaClosure.call (null)
[63] org.luaj.vm2.LuaClosure.execute (null)
[64] org.luaj.vm2.LuaClosure.onInvoke (null)
[65] org.luaj.vm2.LuaClosure.invoke (null)
[66] org.luaj.vm2.LuaThread$State.run (null)
[67] java.lang.Thread.run (null)
Coroutine-74[1] where 0x2256
[1] java.lang.Object.wait (native method)
[2] java.lang.Object.wait (Object.java:503)
[3] org.luaj.vm2.LuaThread$State.lua_resume (null)
[4] org.luaj.vm2.LuaThread.resume (null)
[5] org.luaj.vm2.lib.CoroutineLib.invoke (null)
[6] dan200.computer.core.LuaJLuaMachine.handleEvent (LuaJLuaMachine.java:183)
[7] dan200.computer.core.Computer$3.execute (Computer.java:1,086)
[8] dan200.computer.core.ComputerThread$1$1.run (ComputerThread.java:72)
[9] java.lang.Thread.run (null)
Thread-196[1] where 0x2257
[1] java.lang.Object.wait (native method)
[2] java.lang.Object.wait (Object.java:503)
[3] org.luaj.vm2.LuaThread$State.lua_resume (null)
[4] org.luaj.vm2.LuaThread.resume (null)
[5] org.luaj.vm2.lib.CoroutineLib.invoke (null)
[6] dan200.computer.core.LuaJLuaMachine.handleEvent (LuaJLuaMachine.java:183)
[7] dan200.computer.core.Computer$3.execute (Computer.java:1,086)
[8] dan200.computer.core.ComputerThread$1$1.run (ComputerThread.java:72)
[9] java.lang.Thread.run (null)
Thread-197[1] where 0x2258
[1] java.lang.Object.wait (native method)
[2] java.lang.Object.wait (Object.java:503)
[3] org.luaj.vm2.LuaThread$State.lua_resume (null)
[4] org.luaj.vm2.LuaThread.resume (null)
[5] org.luaj.vm2.lib.CoroutineLib.invoke (null)
[6] dan200.computer.core.LuaJLuaMachine.handleEvent (LuaJLuaMachine.java:183)
[7] dan200.computer.core.Computer$3.execute (Computer.java:1,086)
[8] dan200.computer.core.ComputerThread$1$1.run (ComputerThread.java:72)
[9] java.lang.Thread.run (null)
Thread-198[1]
Thread-198[1] threadlocks 0x21cb
Monitor information for thread Server thread:
Owned monitor: instance of dan200.computer.core.apis.PeripheralAPI$PeripheralWrapper[6] (id=8794)
Owned monitor: instance of dan200.computer.core.Computer(id=8795)
Owned monitor: instance of java.util.ArrayList(id=8796)
Waiting for monitor: instance of dan200.turtle.shared.TurtleModem$Peripheral(id=8797)
Server thread[1] threadlocks 0x221e
Monitor information for thread Coroutine-74:
Owned monitor: instance of dan200.computer.core.apis.PeripheralAPI$PeripheralWrapper(id=8798)
Owned monitor: instance of dan200.turtle.shared.TurtleModem$Peripheral(id=8797)
Owned monitor: instance of dan200.computer.shared.WirelessNetwork(id=8799)
Owned monitor: instance of dan200.turtle.shared.TurtleModem$Peripheral(id=8800)
Owned monitor: instance of dan200.computer.core.apis.PeripheralAPI$PeripheralWrapper(id=8801)
Owned monitor: instance of dan200.computer.core.LuaJLuaMachine$2(id=8802)
Owned monitor: instance of org.luaj.vm2.LuaThread$State(id=8803)
Waiting for monitor: instance of dan200.computer.core.Computer(id=8795)
Coroutine-74[1]