我在debian linux上执行一个控制器,它在无限循环中执行一个功能。与此同时,我使用Rufus Scheduler来安排一个功能,该功能在特定时间后运行1分钟。一旦函数在Rufus中正确执行,我就会收到以下错误
/usr/local/rvm/gems/ruby-2.1.0/gems/rufus-scheduler-3.0.4/lib/rufus/scheduler.rb:505: [BUG] Segmentation fault at 0x00000000000000
ruby 2.1.0p0 (2013-12-25 revision 44422) [x86_64-linux]
-- Control frame information -----------------------------------------------
c:0003 p:---- s:0008 e:000007 CFUNC :sleep
c:0002 p:0041 s:0004 e:000003 BLOCK /usr/local/rvm/gems/ruby-2.1.0/gems/rufus-scheduler-3.0.4/lib/rufus/scheduler.rb:505 [FINISH]
c:0001 p:---- s:0002 e:000001 TOP [FINISH]
/usr/local/rvm/gems/ruby-2.1.0/gems/rufus-scheduler-3.0.4/lib/rufus/scheduler.rb:505:in `block in start'
/usr/local/rvm/gems/ruby-2.1.0/gems/rufus-scheduler-3.0.4/lib/rufus/scheduler.rb:505:in `sleep'
-- C level backtrace information -------------------------------------------
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1b8bba) [0x2b1903679bba] vm_dump.c:685
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x7414c) [0x2b190353514c] error.c:307
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(rb_bug+0xb8) [0x2b1903535458] error.c:334
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x13be39) [0x2b19035fce39] signal.c:704
/lib/libpthread.so.0(+0xeff0) [0x2b190396cff0]
/usr/lib/libsybdb.so.5(+0x16a05) [0x2b1908457a05]
/usr/lib/libsybdb.so.5(+0x3cdcb) [0x2b190847ddcb]
/usr/lib/libsybdb.so.5(+0x3d5f1) [0x2b190847e5f1]
/usr/lib/libsybdb.so.5(+0x3d70b) [0x2b190847e70b]
/usr/lib/libsybdb.so.5(+0x2909e) [0x2b190846a09e]
/usr/lib/libsybdb.so.5(+0x290c9) [0x2b190846a0c9]
/usr/lib/libsybdb.so.5(dbsqlok+0x85) [0x2b1908451a15]
/usr/local/rvm/gems/ruby-2.1.0/extensions/x86_64-linux/2.1.0/tiny_tds-0.6.1/tiny_tds/tiny_tds.so(+0x44f1) [0x2b1907ff24f1] result.c:89
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1c73c2) [0x2b19036883c2] thread.c:1263
/usr/local/rvm/gems/ruby-2.1.0/extensions/x86_64-linux/2.1.0/tiny_tds-0.6.1/tiny_tds /tiny_tds.so(+0x5966) [0x2b1907ff3966] result.c:133
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1a1c9a) [0x2b1903662c9a] vm_insnhelper.c:1468
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1a5a01) [0x2b1903666a01] insns.def:1028
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1ab38c) [0x2b190366c38c] vm.c:1304
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1b01bb) [0x2b19036711bb] vm.c:732
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(rb_rescue2+0x113) [0x2b1903539443] eval.c:751
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x19e49e) [0x2b190365f49e] vm_eval.c:1042
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1a1c9a) [0x2b1903662c9a] vm_insnhelper.c:1468
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1b6a20) [0x2b1903677a20] vm_insnhelper.c:1558
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1a61a7) [0x2b19036671a7] insns.def:999
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x1ab38c) [0x2b190366c38c] vm.c:1304
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(rb_iseq_eval_main+0x300) [0x2b190366c9b0] vm.c:1562
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(+0x78a4a) [0x2b1903539a4a] eval.c:253
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(ruby_exec_node+0x1d) [0x2b1903539a7d] eval.c:318
/usr/local/rvm/rubies/ruby-2.1.0/lib/libruby.so.2.1(ruby_run_node+0x1e) [0x2b190353b2fe] eval.c:310
ruby() [0x40098b]
/lib/libc.so.6(__libc_start_main+0xfd) [0x2b190445fc8d]
ruby() [0x400879]
答案 0 :(得分:1)
这是一个异常,它是从本机库抛出的,而不是Ruby本身。看起来根本原因可能出在您正在使用的tiny_tds gem中:
/usr/local/rvm/gems/ruby-2.1.0/extensions/x86_64-linux/2.1.0/tiny_tds-0.6.1/tiny_tds/tiny_tds.so(+0x44f1) [0x2b1907ff24f1] result.c:89
您是否尝试升级到更高版本的tiny_tds以查看问题是否仍然存在?
编辑:我看到它是最新版本;也许用tiny_tds维护者提出这个问题 - 见https://github.com/rails-sqlserver/tiny_tds