Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Crash on Raspberry Pi #898

Open
Open
@climblinne

Description

@climblinne

Environment

  • Pythonnet version: actual dev version fc7d8a4
  • Python version: 3.7.3
  • Operating System: Raspian (2019-06-20-raspbian-buster-lite)

Details

  • I installed the following:
 # install 2019-06-20-raspbian-buster-lite
 raspi-config : change password, name & extend sd card
 sudo apt update 
 sudo apt dist-upgrade
 sudo reboot
 
 # Mono install (5.20.1.19)
sudo apt install apt-transport-https dirmngr gnupg ca-certificates
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
echo "deb https://download.mono-project.com/repo/debian stable-raspbianstretch main" | sudo tee /etc/apt/sources.list.d/mono-official-stable.list
sudo apt update 
sudo apt install mono-complete
sudo apt install ca-certificates-mono
 
 
 sudo apt install git
 sudo apt install clang
 sudo apt install libglib2.0-dev
 sudo apt-get install python3-pip # Python 3.7.3 already installed
 pip3 install -U setuptools
 pip3 install -U wheel
 pip3 install -U pip
 pip3 install --user pycparser
 pip3 install --user git+https://github.com/pythonnet/pythonnet
 
 pip3 install --user pytest
 
 python3 -m pytest

When run test, the following output happen:

    :~/pythonnet $ python3 -m pytest
======================================= test session starts =======================================
platform linux -- Python 3.7.3, pytest-4.6.3, py-1.8.0, pluggy-0.12.0
rootdir: /home/pi/pythonnet, inifile: setup.cfg
collecting ...
=================================================================
        Native Crash Reporting
=================================================================
Got a SIGILL while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================
/proc/self/maps:
00010000-003a6000 r-xp 00000000 b3:02 9763       /usr/bin/python3.7
003b5000-003b6000 r--p 00395000 b3:02 9763       /usr/bin/python3.7
003b6000-00434000 rw-p 00396000 b3:02 9763       /usr/bin/python3.7
00434000-00447000 rw-p 00000000 00:00 0
01bfa000-02026000 rw-p 00000000 00:00 0          [heap]
72985000-72c8d000 r--p 00000000 b3:02 125337     /usr/lib/mono/gac/System.Xml/4.0.0.0__b77a5c561934e089/System.Xml.dll
72c8d000-72f00000 r--p 00000000 b3:02 125364     /usr/lib/mono/gac/System/4.0.0.0__b77a5c561934e089/System.dll
72f00000-73000000 rw-p 00000000 00:00 0
730bb000-730fb000 rw-p 00000000 00:00 0
730fb000-73200000 r--p 00000000 b3:02 125319     /usr/lib/mono/gac/System.Core/4.0.0.0__b77a5c561934e089/System.Core.dll
73200000-73221000 rw-p 00000000 00:00 0
73221000-73300000 ---p 00000000 00:00 0
73305000-73306000 ---p 00000000 00:00 0
73306000-73406000 rwxp 00000000 00:00 0
73406000-73b90000 r-xp 00000000 b3:02 125209     /usr/lib/mono/aot-cache/arm/mscorlib.dll.so
73b90000-73b9f000 ---p 0078a000 b3:02 125209     /usr/lib/mono/aot-cache/arm/mscorlib.dll.so
73b9f000-73ba0000 r--p 00789000 b3:02 125209     /usr/lib/mono/aot-cache/arm/mscorlib.dll.so
73ba0000-73ba1000 rw-p 0078a000 b3:02 125209     /usr/lib/mono/aot-cache/arm/mscorlib.dll.so
73ba1000-73bb5000 rw-p 00000000 00:00 0
73bb5000-73fff000 r--p 00000000 b3:02 125310     /usr/lib/mono/4.5/mscorlib.dll
73fff000-747ff000 rw-p 00000000 00:00 0
747ff000-74800000 ---p 00000000 00:00 0
74800000-75000000 rwxp 00000000 00:00 0
75000000-75400000 rw-p 00000000 00:00 0
7542e000-7544e000 rwxp 00000000 00:00 0

=================================================================
        Basic Fault Adddress Reporting
=================================================================
Memory around native instruction pointer (0x7658500c):0x76584ffc

When just opening python3 and

import clr 
exit()

I got the following ouptut:

>>> import clr
>>> exit()

=================================================================
        Native Crash Reporting
=================================================================
Got a SIGILL while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================
/proc/self/maps:
00010000-003a6000 r-xp 00000000 b3:02 9763       /usr/bin/python3.7
003b5000-003b6000 r--p 00395000 b3:02 9763       /usr/bin/python3.7
003b6000-00434000 rw-p 00396000 b3:02 9763       /usr/bin/python3.7
00434000-00447000 rw-p 00000000 00:00 0
00f52000-012bf000 rw-p 00000000 00:00 0          [heap]
73285000-7358d000 r--p 00000000 b3:02 125337     /usr/lib/mono/gac/System.Xml/4.0.0.0__b77a5c561934e089/System.Xml.dll
7358d000-73800000 r--p 00000000 b3:02 125364     /usr/lib/mono/gac/System/4.0.0.0__b77a5c561934e089/System.dll
73800000-73900000 rw-p 00000000 00:00 0
739dd000-739fb000 r--p 00000000 b3:02 125355     /usr/lib/mono/gac/System.Configuration/4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
739fb000-73b00000 r--p 00000000 b3:02 125319     /usr/lib/mono/gac/System.Core/4.0.0.0__b77a5c561934e089/System.Core.dll
73b00000-73b21000 rw-p 00000000 00:00 0
73b21000-73c00000 ---p 00000000 00:00 0
73c06000-74390000 r-xp 00000000 b3:02 125209     /usr/lib/mono/aot-cache/arm/mscorlib.dll.so
74390000-7439f000 ---p 0078a000 b3:02 125209     /usr/lib/mono/aot-cache/arm/mscorlib.dll.so
7439f000-743a0000 r--p 00789000 b3:02 125209     /usr/lib/mono/aot-cache/arm/mscorlib.dll.so
743a0000-743a1000 rw-p 0078a000 b3:02 125209     /usr/lib/mono/aot-cache/arm/mscorlib.dll.so
743a1000-743b5000 rw-p 00000000 00:00 0
743b5000-747ff000 r--p 00000000 b3:02 125310     /usr/lib/mono/4.5/mscorlib.dll
747ff000-74fff000 rw-p 00000000 00:00 0
74fff000-75000000 ---p 00000000 00:00 0
75000000-75800000 rwxp 00000000 00:00 0
75800000-75c00000 rw-p 00000000 00:00 0
75c1a000-75cda000 rw-p 00000000 00:00 0
75cda000-75cff000 r--p 00000000 b3:02 258838     /home/pi/.local/lib/python3.7/site-packages/Python.Runtime.dll
75cff000-75d00000 ---p 00000000 00:00 0

=================================================================
        Basic Fault Adddress Reporting
=================================================================
Memory around native instruction pointer (0x7662a00c):0x76629ffc  00 00 00 00 e3 a0 00 00 e1 2f ff 1e e3 a0 00 01  ........./......
0x7662a00c  e1 2f ff 1e 00 00 00 00 00 00 00 00 00 00 00 00  ./..............
0x7662a01c  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
0x7662a02c  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................

=================================================================
        Native stacktrace:
=================================================================
         (No frames)


=================================================================
        Telemetry Dumper:
=================================================================
Pkilling 0x75dff460 from 0x76ef4ad0
Entering thread summarizer pause from 0x76ef4ad0
Finished thread summarizer pause from 0x76ef4ad0.

Waiting for dumping threads to resume

Debug info from gdb:


=================================================================
        External Debugger Dump:
=================================================================
[New LWP 9084]
[New LWP 9085]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
__waitpid (options=0, stat_loc=0x7e819848, pid=9090) at ../sysdeps/unix/sysv/linux/waitpid.c:30
30      ../sysdeps/unix/sysv/linux/waitpid.c: No such file or directory.
  Id   Target Id                                  Frame
* 1    Thread 0x76ef4ad0 (LWP 9083) "python3"     __waitpid (options=0, stat_loc=0x7e819848, pid=9090) at ../sysdeps/unix/sysv/linux/waitpid.c:30
  2    Thread 0x757ff460 (LWP 9084) "SGen worker" futex_wait_cancelable (private=0, expected=0, futex_word=0x76598748) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  3    Thread 0x75dff460 (LWP 9085) "Finalizer"   0x76e62088 in futex_abstimed_wait_cancelable (private=0, abstime=0x0, expected=1, futex_word=0x76590e10) at ../sysdeps/unix/sysv/linux/futex-internal.h:205

Thread 3 (Thread 0x75dff460 (LWP 9085)):
#0  0x76e62088 in futex_abstimed_wait_cancelable (private=0, abstime=0x0, expected=1, futex_word=0x76590e10) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
#1  do_futex_wait (sem=sem@entry=0x76590e10, abstime=0x0) at sem_waitcommon.c:115
#2  0x76e621f4 in __new_sem_wait_slow (sem=0x76590e10, abstime=0x0) at sem_waitcommon.c:282
#3  0x7642dd50 in ?? () from /usr/lib/libmonosgen-2.0.so.1
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

Thread 2 (Thread 0x757ff460 (LWP 9084)):
#0  futex_wait_cancelable (private=0, expected=0, futex_word=0x76598748) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
#1  __pthread_cond_wait_common (abstime=0x0, mutex=0x0, cond=0x76598720) at pthread_cond_wait.c:502
#2  __pthread_cond_wait (cond=0x76598720, mutex=0x0) at pthread_cond_wait.c:655
#3  0x76489434 in ?? () from /usr/lib/libmonosgen-2.0.so.1
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

Thread 1 (Thread 0x76ef4ad0 (LWP 9083)):
#0  __waitpid (options=0, stat_loc=0x7e819848, pid=9090) at ../sysdeps/unix/sysv/linux/waitpid.c:30
#1  __waitpid (pid=9090, stat_loc=0x7e819848, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:25
#2  0x762bc060 in ?? () from /usr/lib/libmonosgen-2.0.so.1
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
[Inferior 1 (process 9083) detached]

=================================================================
        Managed Stacktrace:
=================================================================
=================================================================

When I build a test program with Mono everything seems to be fine.
Anyone got it running under Raspberry Pi?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions