dotNET 7 core crashes with GC heap initialization

Open
#283 4 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
linux, ubuntu

Research direction

Reproduce the failure in the described Ubuntu 22.04 arm64 proot environment under Termux, starting with the dotnet --help, dotnet new console, and dotnet --info commands. Investigate the GC heap initialization failure and identify the relevant proot behavior; done means the affected .NET commands run without crashing.

Written by the indexing model from the issue text.

Description

Problem description
DotNET 7 SDK installed on Ubuntu 22.04 arm64 but most commands such as dotnet new dotnet --help shows GC heap initialization error without doing anything, just crashes

root@localhost:~# dotnet new console
GC heap initialization failed with error 0x8007000E
Failed to create CoreCLR, HRESULT: 0x8007000E
root@localhost:~# dotnet --help
GC heap initialization failed with error 0x8007000E
Failed to create CoreCLR, HRESULT: 0x8007000E
root@localhost:~# dotnet --info
GC heap initialization failed with error 0x8007000E
Failed to create CoreCLR, HRESULT: 0x8007000E

Host:
  Version:      7.0.10
  Architecture: arm64
  Commit:       a6dbb800a4

.NET SDKs installed:
  7.0.110 [/usr/lib/dotnet/sdk]

.NET runtimes installed:
  Microsoft.AspNetCore.App 7.0.10 [/usr/lib/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 7.0.10 [/usr/lib/dotnet/shared/Microsoft.NETCore.App]

Other architectures found:
  None

Environment variables:
  Not set

global.json file:
  Not found

Learn more:
  https://aka.ms/dotnet/info

Download .NET:
  https://aka.ms/dotnet/download
root@localhost:~#

Steps to reproduce
This happens on Ubuntu 22.04 arm64 proot installation

  1. Install proot-distro and Ubuntu proot-distro install ubuntu
  2. Update packages and install dotNET SDK apt install dotnet-sdk-7.0
  3. Run some dotNET commands such as dotnet --help dotnet new console dotnet run dotnet store yields GC initialization failure (some still does it's job like dotnet --info but with error about gc init failure)

Expected behavior
It should not crash with GC initialization failure

Additional information

Termux Variables:
TERMUX_API_VERSION=0.50.1
TERMUX_APK_RELEASE=F_DROID
TERMUX_APP_PACKAGE_MANAGER=apt
TERMUX_APP_PID=19765
TERMUX_IS_DEBUGGABLE_BUILD=0
TERMUX_MAIN_PACKAGE_FORMAT=debian
TERMUX_VERSION=0.118.0
Packages CPU architecture:
aarch64
Subscribed repositories:
# sources.list
deb https://packages-cf.termux.dev/apt/termux-main/ stable main
# x11-repo (sources.list.d/x11.list)
deb https://packages-cf.termux.dev/apt/termux-x11/ x11 main
Updatable packages:
command-not-found/stable 2.2.0-13 aarch64 [upgradable from: 2.2.0-12]
vulkan-headers/stable 1.3.261 all [upgradable from: 1.3.260]
vulkan-loader-generic/stable 1.3.261 aarch64 [upgradable from: 1.3.259]
zlib/stable 1.3 aarch64 [upgradable from: 1.2.13]
termux-tools version:
1.38.5
Android version:
11
Kernel build information:
Linux localhost 4.14.180-perf+ #2 SMP PREEMPT Sat Sep 3 23:17:03 CST 2022 aarch64 Android
Device manufacturer:
OPPO
Device model:
CPH1933
LD Variables:
LD_LIBRARY_PATH=
LD_PRELOAD=/data/data/com.termux/files/usr/lib/libtermux-exec.so
Installed termux plugins:
com.termux.api versionCode:51
com.termux.x11 versionCode:14

Not sure for older versions of dotnet if it exhibits the same behavior

Dominant language
C
Stars
1.1k
Forks
276
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from termux/proot

All issues in termux/proot

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.