dotnet / install-scripts

MIT License
128 stars 68 forks source link

`dotnet` segfaults after scripted install #459

Closed dbarowy closed 3 months ago

dbarowy commented 4 months ago

Description

I just ran the scripted install on a Raspberry Pi Zero running Debian 10. Unfortunately, dotnet segfaults when trying to run the binary.

$ .dotnet/dotnet 
Segmentation fault

Some system details:

$ file .dotnet/dotnet 
.dotnet/dotnet: ELF 32-bit LSB shared object, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-armhf.so.3, for GNU/Linux 3.2.0, BuildID[sha1]=6a504f2f11ceca0c992a01444868aeba82211931, not stripped

$ lsb_release -a
No LSB modules are available.
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 10 (buster)
Release:    10
Codename:   buster

$ uname -a
Linux nausus 5.10.60+ dotnet/runtime#1449 Wed Aug 25 14:59:20 BST 2021 armv6l GNU/Linux

I recognize that this machine is a little out of date, but all indications tell me that the machine/OS are still officially supported (for .NET 7.0).

Reproduction Steps

I installed the .NET SDK 7.0.406 like so:

$ ./dotnet-install.sh --version 7.0.406

Expected behavior

Minimally, dotnet should not segfault.

Actual behavior

Segfaults.

Regression?

No response

Known Workarounds

No response

Configuration

version: .NET SDK 7.0.406 OS: Debian Buster (Raspbian) Arch: ARM Hardware: Raspberry Pi Zero

Other information

No response

dbarowy commented 4 months ago

Follow-up: I am unable to install via the Microsoft deb (Unable to locate package dotnet-sdk-7.0) and manually installing the binary release also produces a segfault when running dotnet. It seems like this platform is no longer supported.

vcsjones commented 4 months ago

This is effectively a duplicate of https://github.com/dotnet/runtime/issues/2817 and https://github.com/dotnet/runtime/issues/71642 and https://github.com/dotnet/runtime/issues/7764#issuecomment-1043468998.

The Raspberry Pi Zero has an ARMv6 CPU. .NET requires ARMv7. Mono can work with ARMv6, however an official build is not provided. The latter of the those links has community discussion about support and building instructions.

dbarowy commented 4 months ago

Perhaps someone can update one of the installation instruction pages to make it clear that ARMv6 is not supported.

colejohnson66 commented 4 months ago

IMHO, dotnet-install should fail if the host platform is not supported. Succeeding only to be met with crytic errors when attempting to use a tool is a bad experience.

NikolaMilosavljevic commented 3 months ago

[Triage] There is a question if dotnet-install script can handle this more gracefully and check for supported platforms.

YuliiaKovalova commented 3 months ago

Hello,

The issue has been resolved in scope of https://github.com/dotnet/install-scripts/issues/444. The platforms ARMv6 and lower are not supported. Please let me know if you have any questions.