Mono SIGSEGV崩溃,没有堆栈跟踪信息

时间:2015-04-24 02:49:22

标签: c# .net ubuntu mono

我有一个用C#实现的机器学习算法(随机梯度下降),它涉及在内存中缓存的~10GB数据的100次迭代。该程序在windows下运行正常,但是当部署到运行14.04.2 LTS的ubuntu mono 3.12.1时,程序RANDOMLY在约30次迭代(大约需要一天)后崩溃,输出如下:

Stacktrace:


Native stacktrace:

mono() [0x4accac]
mono() [0x50451f]
mono() [0x42a7c7]
/lib/x86_64-linux-gnu/libpthread.so.0(+0xfcb0) [0x7f678b0d1cb0]
mono() [0x61c48f]
mono() [0x5cdfe6]
mono() [0x5dd95a]
mono() [0x5dd9bc]
mono() [0x5d0ff4]
mono() [0x5c7458]
mono() [0x5c765f]
mono() [0x5c8d6a]
mono() [0x5c980a]
mono() [0x5ccc15]
mono() [0x5d2ab0]
mono() [0x5dfb70]
mono() [0x5dffeb]
[0x4196f62e]
Debug info from gdb:

Could not attach to process.  If your uid matches the uid of the target process, check the setting of /proc/sys/kernel/yama/ptrace_scope, or try again as the root user.  For more details, see /etc/sysctl.d/10-ptrace.conf ptrace: Operation not permitted.
No threads.

=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries 
used by your application.
=================================================================
  1. 如何获得有关堆栈跟踪的更详细信息(例如崩溃的实际线路),以便查明崩溃的原因?

  2. 如何从gdb获取详细的调试信息(而不是无法附加到进程错误)?

  3. 使用命令nohup mono MyProgram.exe &

    运行程序

2 个答案:

答案 0 :(得分:0)

这是一个黑暗的镜头,但也许你可以用这样的东西明确设置更大的内存限制,

MONO_GC_PARAMS max-heap-size=10G

确保您没有达到内存限制。

答案 1 :(得分:0)

非托管崩溃是单一运行时错误,请在http://bugzilla.xamarin.com/中提交一张票证,其中包含如何重现问题的最小测试用例。