Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

接收client消息crash问题 #236

Closed
adzhang opened this issue Feb 16, 2015 · 1 comment
Closed

接收client消息crash问题 #236

adzhang opened this issue Feb 16, 2015 · 1 comment

Comments

@adzhang
Copy link

adzhang commented Feb 16, 2015

Program terminated with signal 11, Segmentation fault.
#0 0x0000000000413f26 in propagatemark ()

Missing separate debuginfos, use: debuginfo-install glibc-2.12-1.149.el6_6.5.x86_64
(gdb) bt
#0 0x0000000000413f26 in propagatemark ()
#1 0x00000000004148a8 in singlestep ()
#2 0x0000000000414f10 in luaC_step ()
#3 0x000000000041d612 in luaV_execute ()
#4 0x00000000004124f0 in unroll ()
#5 0x0000000000411b7b in luaD_rawrunprotected ()
#6 0x0000000000411dd8 in lua_resume ()
#7 0x0000000000425cf7 in auxresume ()
#8 0x0000000000425fd7 in luaB_coresume ()
#9 0x0000000000412768 in luaD_precall ()
#10 0x000000000041d1b6 in luaV_execute ()
#11 0x0000000000412a5c in luaD_call ()
#12 0x0000000000411b7b in luaD_rawrunprotected ()
#13 0x0000000000411bff in luaD_pcall ()
#14 0x000000000040f802 in lua_pcallk ()
#15 0x0000000000424e00 in luaB_pcall ()
#16 0x0000000000412768 in luaD_precall ()
#17 0x000000000041d1b6 in luaV_execute ()
#18 0x0000000000412a5c in luaD_call ()
#19 0x0000000000411b7b in luaD_rawrunprotected ()
#20 0x0000000000411bff in luaD_pcall ()
#21 0x000000000040f802 in lua_pcallk ()
#22 0x00007f35e99ef923 in _cb (context=0x7f35e8c4e080, ud=0x7f35f1762788, type=3, session=0, source=16777241, msg=0x7f35f15d6530, sz=11)

at lualib-src/lua-skynet.c:50

#23 0x0000000000408d30 in dispatch_message (ctx=0x7f35e8c4e080, msg=0x7f35eebf9df0) at skynet-src/skynet_server.c:254
#24 0x0000000000408fbf in skynet_context_message_dispatch (sm=0x7f35f140e160, q=0x7f35f1645300, weight=-1) at skynet-src/skynet_server.c:308
#25 0x0000000000409c81 in _worker (p=) at skynet-src/skynet_start.c:128
#26 0x00007f35f29419d1 in start_thread () from /lib64/libpthread.so.0
#27 0x00007f35f1ffe8fd in clone () from /lib64/libc.so.6

用gdb调试只能跟踪到_cb的函数,拿不准问题出在哪里,我的client往agent服务发json的数据包,当client进入了某个房间,agent会进行skynet.redirect,crash也是随机发生。

@adzhang
Copy link
Author

adzhang commented Feb 17, 2015

查了老久,原来把agent分发的msg直接send到其他服务里导致crash,通过再次pack的方式解决了。不过对msg的生存期还是比较迷惑,关闭issue先。

@adzhang adzhang closed this as completed Feb 17, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant