tkrajcar / carbonmu

CarbonMU was experiments towards a general-purpose, extendable MUD/MUSH server written in Ruby.
MIT License
13 stars 5 forks source link

Error when connecting to server using PuTTYtel #28

Closed Qqwy closed 9 years ago

Qqwy commented 9 years ago

When connecting to the telnet port (127.0.0.1:8421) using the PuTTYtel telnet client, the server crashes.

Steps I took:

  1. Run 'rake console' , and then 'carbonmu start' once the console has loaded.
  2. Wait until the 'edge router sending connections to server' message appears (because of
  3. Now, start up the telnet client using localhost and the default port number 8421.

The server crashes, printing the following log:

$ rake console
c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/celluloid/depr
ecate.rb:13: warning: already initialized constant Celluloid::Logger
c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-essentials-0.20.0.pre17/lib/cel
luloid/essentials.rb:27: warning: previous definition of Logger was here
I, [2015-06-01T03:47:37.226786 #8624]  INFO -- : +------------------------------
--------------------+
I, [2015-06-01T03:47:37.227764 #8624]  INFO -- : |    Celluloid version running
now: 0.17.0.pre15   +
W, [2015-06-01T03:47:37.227764 #8624]  WARN -- : +------------------------------
--------------------+
W, [2015-06-01T03:47:37.228737 #8624]  WARN -- : |     Celluloid is running in B
ACKPORTED mode.     |
W, [2015-06-01T03:47:37.228737 #8624]  WARN -- : |   Time to update deprecated c
ode, before v1.0!   |
W, [2015-06-01T03:47:37.229723 #8624]  WARN -- : +------------------------------
--------------------+
W, [2015-06-01T03:47:37.229723 #8624]  WARN -- : |  Prepare! As of v0.17.5 you c
an begin updating.  |
W, [2015-06-01T03:47:37.230696 #8624]  WARN -- : +------------------------------
--------------------+
W, [2015-06-01T03:47:37.231675 #8624]  WARN -- : |    Want to read about it? htt
p://git.io/vJf3J    |
W, [2015-06-01T03:47:37.231675 #8624]  WARN -- : +------------------------------
--------------------+
WARN: Unresolved specs during Gem::Specification.reset:
      minitest (~> 5.1)
WARN: Clearing out unresolved specs.
Please report a bug if this causes problems.
I, [2015-06-01T03:48:12.502302 #8624]  INFO -- : MONGOID: Created indexes on Car
bonMU::GameObject:
I, [2015-06-01T03:48:12.503303 #8624]  INFO -- : MONGOID: Index: {:_special=>1},
 Options: {}
I, [2015-06-01T03:48:12.503303 #8624]  INFO -- : MONGOID: Index: {:location_id=>
1}, Options: {:background=>true}
I, [2015-06-01T03:48:12.504304 #8624]  INFO -- : MONGOID: Index: {:destination_i
[1] pry(CarbonMU)> carbonmucarbonmu starttart
I, [2015-06-01T03:48:22.988525 #8624]  INFO -- CarbonMU: *** Starting CarbonMU e
dge router.
I, [2015-06-01T03:48:22.990525 #8624]  INFO -- CarbonMU: *** Starting Telnet rec
eptor on 0.0.0.0 8421.
I, [2015-06-01T03:48:23.000532 #8624]  INFO -- CarbonMU: *** Edge router waiting
 for IPC on port 56091
I, [2015-06-01T03:48:45.697289 #26876]  INFO -- CarbonMU: *** Starting CarbonMU
game server to connect to edge router port 56091.
I, [2015-06-01T03:48:45.792357 #26876]  INFO -- : MONGOID: Created indexes on Ca
rbonMU::GameObject:
I, [2015-06-01T03:48:45.793358 #26876]  INFO -- : MONGOID: Index: {:_special=>1}
, Options: {}
I, [2015-06-01T03:48:45.794358 #26876]  INFO -- : MONGOID: Index: {:location_id=
>1}, Options: {:background=>true}
I, [2015-06-01T03:48:45.795359 #26876]  INFO -- : MONGOID: Index: {:destination_
id=>1}, Options: {:background=>true}
D, [2015-06-01T03:48:45.813370 #26876] DEBUG -- CarbonMU: SERVER SEND: <IPCMessa
ge: {:port=>56103, :pid=>26876, :op=>:started}>
D, [2015-06-01T03:48:45.849390 #26876] DEBUG -- CarbonMU: SERVER SEND: <IPCMessa
ge: {:op=>:retrieve_existing_connections}>
D, [2015-06-01T03:48:45.869404 #8624] DEBUG -- CarbonMU: EDGE ROUTER RECEIVE: <I
PCMessage: {:port=>56103, :pid=>26876, :op=>:started}>
D, [2015-06-01T03:48:45.870404 #8624] DEBUG -- CarbonMU: *** Edge router receive
d server IPC start. Pid 26876, port 56103.
D, [2015-06-01T03:48:45.875412 #8624] DEBUG -- CarbonMU: EDGE ROUTER RECEIVE: <I
PCMessage: {:op=>:retrieve_existing_connections}>
I, [2015-06-01T03:48:45.875412 #8624]  INFO -- CarbonMU: Sending connections to
server...

(This was the moment where I tried connecting using the telnet client. Now the server crashes:)

E, [2015-06-01T03:48:55.034487 #8624] ERROR -- CarbonMU: Actor crashed! ThreadError: deadlock; recursive locking c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/nio4r-1.1.0/lib/nio/selector.rb:4 0:insynchronize' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/nio4r-1.1.0/lib/nio/selector.rb:4 0:in deregister' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/nio4r-1.1.0/lib/nio/monitor.rb:40 :inclose' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-io-0.16.5.pre0/lib/cell uloid/io/reactor.rb:52:in wait' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-io-0.16.5.pre0/lib/cell uloid/io/reactor.rb:21:inwait_readable' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-io-0.16.5.pre0/lib/cell uloid/io.rb:53:in wait_readable' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-io-0.16.5.pre0/lib/cell uloid/io/tcp_server.rb:19:inaccept' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/carbonmu-0.0.3/lib/carbonmu/edge_ router/telnetreceptor.rb:23:in `block in run' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/carbonmu-0.0.3/lib/carbonmu/edge router/telnetreceptor.rb:23:in `loop' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/carbonmu-0.0.3/lib/carbonmu/edge router/telnet_receptor.rb:23:in run' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/cellul oid/calls.rb:28:inpublic_send' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/cellul oid/calls.rb:28:in dispatch' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/cellul oid/call/async.rb:7:indispatch' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/cellul oid/cell.rb:50:in block in dispatch' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/cellul oid/cell.rb:76:inblock in task' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/cellul oid/actor.rb:363:in block in task' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/cellul oid/task.rb:57:inblock in initialize' c:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/celluloid-0.17.0.pre15/lib/cellul oid/task/fibered.rb:14:in block in create'

My system: Windows 8.1, Ruby 2.1.6

tkrajcar commented 9 years ago

@qqwy Not sure exactly what the problem is, but I can see from the stack trace you're running a version of celluloid that's different than what is specified for CarbonMU. Instead of starting the game through the console, try running bundle exec bin/carbonmu start - the bundle exec should ensure the proper gems are used.

I've also done zero testing on Windows, so that could be the culprit.

tkrajcar commented 9 years ago

Closing due to lack of response, feel free to reopen with the info requested.